nix and makefile stuff
This commit is contained in:
parent
43448cd80b
commit
40d559a989
5 changed files with 78 additions and 1 deletions
13
.env-dist
Normal file
13
.env-dist
Normal file
|
|
@ -0,0 +1,13 @@
|
|||
POSTGRES_APP_HOST=localhost
|
||||
POSTGRES_APP_USER=app
|
||||
POSTGRES_APP_PASSWORD=app123
|
||||
POSTGRES_APP_DB=app_db
|
||||
POSTGRES_APP_PORT=5432
|
||||
|
||||
POSTGRES_DW_HOST=localhost
|
||||
POSTGRES_DW_USER=dw
|
||||
POSTGRES_DW_PASSWORD=dw123
|
||||
POSTGRES_DW_DB=dw_db
|
||||
POSTGRES_DW_PORT=5444
|
||||
|
||||
|
||||
1
.envrc
Normal file
1
.envrc
Normal file
|
|
@ -0,0 +1 @@
|
|||
dotenv
|
||||
1
.gitignore
vendored
Normal file
1
.gitignore
vendored
Normal file
|
|
@ -0,0 +1 @@
|
|||
.env
|
||||
61
flake.lock
generated
Normal file
61
flake.lock
generated
Normal file
|
|
@ -0,0 +1,61 @@
|
|||
{
|
||||
"nodes": {
|
||||
"flake-utils": {
|
||||
"inputs": {
|
||||
"systems": "systems"
|
||||
},
|
||||
"locked": {
|
||||
"lastModified": 1731533236,
|
||||
"narHash": "sha256-l0KFg5HjrsfsO/JpG+r7fRrqm12kzFHyUHqHCVpMMbI=",
|
||||
"owner": "numtide",
|
||||
"repo": "flake-utils",
|
||||
"rev": "11707dc2f618dd54ca8739b309ec4fc024de578b",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "numtide",
|
||||
"repo": "flake-utils",
|
||||
"type": "github"
|
||||
}
|
||||
},
|
||||
"nixpkgs": {
|
||||
"locked": {
|
||||
"lastModified": 1735563628,
|
||||
"narHash": "sha256-OnSAY7XDSx7CtDoqNh8jwVwh4xNL/2HaJxGjryLWzX8=",
|
||||
"owner": "NixOS",
|
||||
"repo": "nixpkgs",
|
||||
"rev": "b134951a4c9f3c995fd7be05f3243f8ecd65d798",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "NixOS",
|
||||
"ref": "nixos-24.05",
|
||||
"repo": "nixpkgs",
|
||||
"type": "github"
|
||||
}
|
||||
},
|
||||
"root": {
|
||||
"inputs": {
|
||||
"flake-utils": "flake-utils",
|
||||
"nixpkgs": "nixpkgs"
|
||||
}
|
||||
},
|
||||
"systems": {
|
||||
"locked": {
|
||||
"lastModified": 1681028828,
|
||||
"narHash": "sha256-Vy1rq5AaRuLzOxct8nz4T6wlgyUR7zLU309k9mBC768=",
|
||||
"owner": "nix-systems",
|
||||
"repo": "default",
|
||||
"rev": "da67096a3b9bf56a91d16901293e51ba5b49a27e",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "nix-systems",
|
||||
"repo": "default",
|
||||
"type": "github"
|
||||
}
|
||||
}
|
||||
},
|
||||
"root": "root",
|
||||
"version": 7
|
||||
}
|
||||
|
|
@ -21,7 +21,8 @@
|
|||
];
|
||||
|
||||
shellHook = ''
|
||||
export DATABASE_URL=postgres://app:app123@localhost:5432/app_db
|
||||
export DATABASE_URL="postgres://${POSTGRES_APP_USER}:${POSTGRES_APP_PASSWORD}@${POSTGRES_HOST}:${POSTGRES_APP_PORT}/${POSTGRES_APP_DB}"
|
||||
export DW_DATABASE_URL="postgres://${POSTGRES_DW_USER}:${POSTGRES_DW_PASSWORD}@${POSTGRES_HOST}:${POSTGRES_DW_PORT}/${POSTGRES_DW_DB}"
|
||||
echo "✅ Rust + PostgreSQL dev env ready"
|
||||
'';
|
||||
};
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue