immich-machine-learning: only add run time dependencies to PYTHONPATH

This commit is contained in:
Robert Schütz 2024-09-28 15:59:44 -07:00
parent 8637e879e4
commit 1e5c375325

View File

@ -27,7 +27,7 @@ let
};
};
in
python.pkgs.buildPythonApplication {
python.pkgs.buildPythonApplication rec {
pname = "immich-machine-learning";
inherit (immich) version;
src = "${immich.src}/machine-learning";
@ -83,7 +83,7 @@ python.pkgs.buildPythonApplication {
cp -r ann $out/${python.sitePackages}/
makeWrapper ${lib.getExe python.pkgs.gunicorn} "''${!outputBin}"/bin/machine-learning \
--prefix PYTHONPATH : "$out/${python.sitePackages}:$PYTHONPATH" \
--prefix PYTHONPATH : "$out/${python.sitePackages}:${python.pkgs.makePythonPath dependencies}" \
--set-default MACHINE_LEARNING_WORKERS 1 \
--set-default MACHINE_LEARNING_WORKER_TIMEOUT 120 \
--set-default MACHINE_LEARNING_CACHE_FOLDER /var/cache/immich \