From d5ae86c2cc4431adb2b6cdff8d843e9b34ae9e86 Mon Sep 17 00:00:00 2001 From: Michal Vanko Date: Wed, 28 Feb 2024 23:17:58 +0100 Subject: [PATCH] immich quadlets --- immich/database.container | 12 +++++ immich/immich-machine-learning.container | 12 +++++ immich/immich-microservices.container | 18 +++++++ immich/immich-server.container | 19 +++++++ immich/podlet-migration.txt | 66 ++++++++++++++++++++++++ immich/redis.container | 10 ++++ 6 files changed, 137 insertions(+) create mode 100644 immich/database.container create mode 100644 immich/immich-machine-learning.container create mode 100644 immich/immich-microservices.container create mode 100644 immich/immich-server.container create mode 100644 immich/podlet-migration.txt create mode 100644 immich/redis.container diff --git a/immich/database.container b/immich/database.container new file mode 100644 index 0000000..a02d6c5 --- /dev/null +++ b/immich/database.container @@ -0,0 +1,12 @@ +# database.container +[Container] +ContainerName=immich_postgres +Environment=POSTGRES_PASSWORD=${DB_PASSWORD} POSTGRES_USER=${DB_USERNAME} POSTGRES_DB=${DB_DATABASE_NAME} +Image=tensorchord/pgvecto-rs:pg14-v0.2.0@sha256:90724186f0a3517cf6914295b5ab410db9ce23190a2d9d0b9dd6463e3fa298f0 +Volume=pgdata:/var/lib/postgresql/data + +[Service] +Restart=always + +[Install] +WantedBy=default.target diff --git a/immich/immich-machine-learning.container b/immich/immich-machine-learning.container new file mode 100644 index 0000000..fbe0f04 --- /dev/null +++ b/immich/immich-machine-learning.container @@ -0,0 +1,12 @@ +# immich-machine-learning.container +[Container] +ContainerName=immich_machine_learning +EnvironmentFile=.env +Image=ghcr.io/immich-app/immich-machine-learning:${IMMICH_VERSION:-release} +Volume=model-cache:/cache + +[Service] +Restart=always + +[Install] +WantedBy=default.target diff --git a/immich/immich-microservices.container b/immich/immich-microservices.container new file mode 100644 index 0000000..bed58a5 --- /dev/null +++ b/immich/immich-microservices.container @@ -0,0 +1,18 @@ +# immich-microservices.container +[Unit] +Requires=redis.service database.service + +[Container] +ContainerName=immich_microservices +EnvironmentFile=.env +Exec=start.sh microservices +Image=ghcr.io/immich-app/immich-server:${IMMICH_VERSION:-release} +AutoUpdate=registry +Volume=${UPLOAD_LOCATION}:/usr/src/app/upload +Volume=/etc/localtime:/etc/localtime:ro + +[Service] +Restart=always + +[Install] +WantedBy=default.target diff --git a/immich/immich-server.container b/immich/immich-server.container new file mode 100644 index 0000000..e0570f8 --- /dev/null +++ b/immich/immich-server.container @@ -0,0 +1,19 @@ +# immich-server.container +[Unit] +Requires=redis.service database.service + +[Container] +ContainerName=immich_server +EnvironmentFile=.env +Exec=start.sh immich +Image=ghcr.io/immich-app/immich-server:${IMMICH_VERSION:-release} +AutoUpdate=registry +PublishPort=2283:3001 +Volume=${UPLOAD_LOCATION}:/usr/src/app/upload +Volume=/etc/localtime:/etc/localtime:ro + +[Service] +Restart=always + +[Install] +WantedBy=default.target diff --git a/immich/podlet-migration.txt b/immich/podlet-migration.txt new file mode 100644 index 0000000..a1c9816 --- /dev/null +++ b/immich/podlet-migration.txt @@ -0,0 +1,66 @@ +# immich-server.container +[Unit] +Requires=redis.service database.service + +[Container] +ContainerName=immich_server +EnvironmentFile=.env +Exec=start.sh immich +Image=ghcr.io/immich-app/immich-server:${IMMICH_VERSION:-release} +PublishPort=2283:3001 +Volume=${UPLOAD_LOCATION}:/usr/src/app/upload +Volume=/etc/localtime:/etc/localtime:ro + +[Service] +Restart=always + +--- + +# immich-microservices.container +[Unit] +Requires=redis.service database.service + +[Container] +ContainerName=immich_microservices +EnvironmentFile=.env +Exec=start.sh microservices +Image=ghcr.io/immich-app/immich-server:${IMMICH_VERSION:-release} +Volume=${UPLOAD_LOCATION}:/usr/src/app/upload +Volume=/etc/localtime:/etc/localtime:ro + +[Service] +Restart=always + +--- + +# immich-machine-learning.container +[Container] +ContainerName=immich_machine_learning +EnvironmentFile=.env +Image=ghcr.io/immich-app/immich-machine-learning:${IMMICH_VERSION:-release} +Volume=model-cache:/cache + +[Service] +Restart=always + +--- + +# redis.container +[Container] +ContainerName=immich_redis +Image=redis:6.2-alpine@sha256:51d6c56749a4243096327e3fb964a48ed92254357108449cb6e23999c37773c5 + +[Service] +Restart=always + +--- + +# database.container +[Container] +ContainerName=immich_postgres +Environment=POSTGRES_PASSWORD=${DB_PASSWORD} POSTGRES_USER=${DB_USERNAME} POSTGRES_DB=${DB_DATABASE_NAME} +Image=tensorchord/pgvecto-rs:pg14-v0.2.0@sha256:90724186f0a3517cf6914295b5ab410db9ce23190a2d9d0b9dd6463e3fa298f0 +Volume=pgdata:/var/lib/postgresql/data + +[Service] +Restart=always diff --git a/immich/redis.container b/immich/redis.container new file mode 100644 index 0000000..b7919e0 --- /dev/null +++ b/immich/redis.container @@ -0,0 +1,10 @@ +# redis.container +[Container] +ContainerName=immich_redis +Image=redis:6.2-alpine@sha256:51d6c56749a4243096327e3fb964a48ed92254357108449cb6e23999c37773c5 + +[Service] +Restart=always + +[Install] +WantedBy=default.target