0
0
Fork 0
mirror of https://github.com/NixOS/nixpkgs.git synced 2025-07-13 21:50:33 +03:00

immich: 1.117.0 -> 1.118.1 (#348890)

This commit is contained in:
Robert Schütz 2024-10-16 12:31:58 -07:00 committed by GitHub
commit a9dee7c45b
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
5 changed files with 29 additions and 41 deletions

View file

@ -91,7 +91,7 @@ in
}; };
port = mkOption { port = mkOption {
type = types.port; type = types.port;
default = 3001; default = 2283;
description = "The port that immich will listen on."; description = "The port that immich will listen on.";
}; };
openFirewall = mkOption { openFirewall = mkOption {

View file

@ -26,24 +26,24 @@ import ../make-test-python.nix (
machine.wait_for_unit("immich-server.service") machine.wait_for_unit("immich-server.service")
machine.wait_for_open_port(3001) # Server machine.wait_for_open_port(2283) # Server
machine.wait_for_open_port(3003) # Machine learning machine.wait_for_open_port(3003) # Machine learning
machine.succeed("curl --fail http://localhost:3001/") machine.succeed("curl --fail http://localhost:2283/")
machine.succeed(""" machine.succeed("""
curl -H 'Content-Type: application/json' --data '{ "email": "test@example.com", "name": "Admin", "password": "admin" }' -X POST http://localhost:3001/api/auth/admin-sign-up curl -H 'Content-Type: application/json' --data '{ "email": "test@example.com", "name": "Admin", "password": "admin" }' -X POST http://localhost:2283/api/auth/admin-sign-up
""") """)
res = machine.succeed(""" res = machine.succeed("""
curl -H 'Content-Type: application/json' --data '{ "email": "test@example.com", "password": "admin" }' -X POST http://localhost:3001/api/auth/login curl -H 'Content-Type: application/json' --data '{ "email": "test@example.com", "password": "admin" }' -X POST http://localhost:2283/api/auth/login
""") """)
token = json.loads(res)['accessToken'] token = json.loads(res)['accessToken']
res = machine.succeed(""" res = machine.succeed("""
curl -H 'Content-Type: application/json' -H 'Cookie: immich_access_token=%s' --data '{ "name": "API Key", "permissions": ["all"] }' -X POST http://localhost:3001/api/api-keys curl -H 'Content-Type: application/json' -H 'Cookie: immich_access_token=%s' --data '{ "name": "API Key", "permissions": ["all"] }' -X POST http://localhost:2283/api/api-keys
""" % token) """ % token)
key = json.loads(res)['secret'] key = json.loads(res)['secret']
machine.succeed(f"immich login http://localhost:3001/api {key}") machine.succeed(f"immich login http://localhost:2283/api {key}")
res = machine.succeed("immich server-info") res = machine.succeed("immich server-info")
print(res) print(res)
''; '';

View file

@ -8,27 +8,6 @@
let let
python = python3.override { python = python3.override {
self = python; self = python;
packageOverrides = self: super: {
pydantic = super.pydantic_1;
versioningit = super.versioningit.overridePythonAttrs (_: {
doCheck = false;
});
albumentations = super.albumentations.overridePythonAttrs (old: rec {
version = "1.4.3";
src = fetchFromGitHub {
owner = "albumentations-team";
repo = "albumentations";
rev = version;
hash = "sha256-JIBwjYaUP4Sc1bVM/zlj45cz9OWpb/LOBsIqk1m+sQA=";
};
dependencies = old.dependencies ++ [
self.scikit-learn
];
});
};
}; };
in in
python.pkgs.buildPythonApplication rec { python.pkgs.buildPythonApplication rec {
@ -44,7 +23,10 @@ python.pkgs.buildPythonApplication rec {
substituteInPlace app/test_main.py --replace-fail ": cv2.Mat" "" substituteInPlace app/test_main.py --replace-fail ": cv2.Mat" ""
''; '';
pythonRelaxDeps = [ "setuptools" ]; pythonRelaxDeps = [
"pydantic-settings"
"setuptools"
];
pythonRemoveDeps = [ "opencv-python-headless" ]; pythonRemoveDeps = [ "opencv-python-headless" ];
build-system = with python.pkgs; [ build-system = with python.pkgs; [
@ -60,6 +42,8 @@ python.pkgs.buildPythonApplication rec {
pillow pillow
fastapi fastapi
uvicorn uvicorn
pydantic
pydantic-settings
aiocache aiocache
rich rich
ftfy ftfy
@ -69,7 +53,6 @@ python.pkgs.buildPythonApplication rec {
gunicorn gunicorn
huggingface-hub huggingface-hub
tokenizers tokenizers
pydantic
] ]
++ uvicorn.optional-dependencies.standard; ++ uvicorn.optional-dependencies.standard;

View file

@ -225,7 +225,12 @@ buildNpmPackage' {
description = "Self-hosted photo and video backup solution"; description = "Self-hosted photo and video backup solution";
homepage = "https://immich.app/"; homepage = "https://immich.app/";
license = lib.licenses.agpl3Only; license = lib.licenses.agpl3Only;
maintainers = with lib.maintainers; [ jvanbruegge ]; maintainers = with lib.maintainers; [
dotlambda
jvanbruegge
Scrumplex
titaniumtown
];
platforms = lib.platforms.linux; platforms = lib.platforms.linux;
mainProgram = "server"; mainProgram = "server";
}; };

View file

@ -1,22 +1,22 @@
{ {
"version": "1.117.0", "version": "1.118.1",
"hash": "sha256-v4TxKL+NaaAFxlJx/AG/5JxWnPK9uO6GjM4aoW53nzQ=", "hash": "sha256-rWBW0EwehuWnKk6qEte+dPd9l7FbLzwdkCSKMm22Orw=",
"components": { "components": {
"cli": { "cli": {
"npmDepsHash": "sha256-ARjrBHx4aOiNy2PbHWS7kP9Z8QiNyTeyImSxIsXwPnU=", "npmDepsHash": "sha256-0je82BtDH6cUzoMrmeIS0jLmWPbmkdIQJ/SnmbAMtbw=",
"version": "2.2.23" "version": "2.2.25"
}, },
"server": { "server": {
"npmDepsHash": "sha256-RjaTRqfZpDhI8lMVvsgICUn8g4NFnqcPptem/AwRr38=", "npmDepsHash": "sha256-Jxb47Y4x9A6s4zGODIp6rze7iQ/w8Gvt31NHSATLYCM=",
"version": "1.117.0" "version": "1.118.1"
}, },
"web": { "web": {
"npmDepsHash": "sha256-TZnpbLJbTNFwI2Kvng88z0T1jFf4Tj2xwR0X0wCLaD0=", "npmDepsHash": "sha256-BUgkdsC6raURkyy6eN31uCMKmBbL+fCbGabfHJgJn8g=",
"version": "1.117.0" "version": "1.118.1"
}, },
"open-api/typescript-sdk": { "open-api/typescript-sdk": {
"npmDepsHash": "sha256-G+iivJ0jibRCw/RChv5heVwY7c7oY/EG4bL+kpjoADQ=", "npmDepsHash": "sha256-Ga/aU5hojd3SgtoiM5QLsmzS5k7CRvh13a4lkC0BZA8=",
"version": "1.117.0" "version": "1.118.1"
} }
} }
} }