chore: prepare deps and make to deploy meltano
This commit is contained in:
parent
bc02946bd5
commit
c85ffdfbcd
4 changed files with 38 additions and 8 deletions
34
flake.nix
34
flake.nix
|
|
@ -10,18 +10,40 @@
|
|||
flake-utils.lib.eachDefaultSystem (system:
|
||||
let
|
||||
pkgs = import nixpkgs { inherit system; };
|
||||
|
||||
python-with-deps = pkgs.python3.withPackages (ps: with ps; [
|
||||
pip
|
||||
setuptools
|
||||
wheel
|
||||
psycopg2
|
||||
]);
|
||||
|
||||
venvDir = ".venv";
|
||||
|
||||
in {
|
||||
devShells.default = pkgs.mkShell {
|
||||
buildInputs = with pkgs; [
|
||||
rustup
|
||||
pkg-config
|
||||
openssl
|
||||
postgresql
|
||||
sqlx-cli
|
||||
packages = [
|
||||
pkgs.rustup
|
||||
pkgs.cargo
|
||||
pkgs.docker
|
||||
pkgs.postgresql
|
||||
python-with-deps
|
||||
];
|
||||
|
||||
shellHook = ''
|
||||
echo "✅ Rust + PostgreSQL dev env ready"
|
||||
|
||||
if [ ! -d ${venvDir} ]; then
|
||||
echo "🐍 Creating Python virtualenv..."
|
||||
python3 -m venv ${venvDir}
|
||||
fi
|
||||
|
||||
source ${venvDir}/bin/activate
|
||||
|
||||
pip install --upgrade pip
|
||||
pip install -r requirements.txt
|
||||
|
||||
echo "Python env ready"
|
||||
'';
|
||||
};
|
||||
});
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue