Add immich
This commit is contained in:
parent
ac0543e68c
commit
355bd0593d
2 changed files with 89 additions and 0 deletions
|
|
@ -42,6 +42,78 @@
|
|||
|
||||
autoStart = true;
|
||||
};
|
||||
|
||||
# Immich photo and video backup system
|
||||
containers.immich = {
|
||||
image = "ghcr.io/imagegenius/immich:latest";
|
||||
|
||||
volumes = [
|
||||
"/home/yanlin/deploy/data/immich/config:/config"
|
||||
"/mnt/storage/appbulk/immich:/photos"
|
||||
"/mnt/storage/Media/DCIM:/libraries"
|
||||
];
|
||||
|
||||
environment = {
|
||||
PUID = "1000";
|
||||
PGID = "100";
|
||||
TZ = "Europe/Copenhagen";
|
||||
DB_HOSTNAME = "immich-db";
|
||||
DB_USERNAME = "postgres";
|
||||
DB_PASSWORD = "postgres";
|
||||
DB_DATABASE_NAME = "postgres";
|
||||
DB_PORT = "5432";
|
||||
REDIS_HOSTNAME = "immich-redis";
|
||||
REDIS_PORT = "6379";
|
||||
MACHINE_LEARNING_HOST = "0.0.0.0";
|
||||
MACHINE_LEARNING_PORT = "3003";
|
||||
MACHINE_LEARNING_WORKERS = "1";
|
||||
MACHINE_LEARNING_WORKER_TIMEOUT = "120";
|
||||
};
|
||||
|
||||
ports = [
|
||||
"5000:8080"
|
||||
];
|
||||
|
||||
extraOptions = [
|
||||
"--network=podman"
|
||||
"--device=/dev/dri:/dev/dri" # Hardware acceleration
|
||||
];
|
||||
|
||||
dependsOn = [ "immich-db" "immich-redis" ];
|
||||
autoStart = true;
|
||||
};
|
||||
|
||||
# PostgreSQL database for Immich with vector extension
|
||||
containers.immich-db = {
|
||||
image = "docker.io/tensorchord/pgvecto-rs:pg14-v0.2.0";
|
||||
|
||||
volumes = [
|
||||
"/home/yanlin/deploy/data/immich/db:/var/lib/postgresql/data"
|
||||
];
|
||||
|
||||
environment = {
|
||||
POSTGRES_PASSWORD = "postgres";
|
||||
POSTGRES_USER = "postgres";
|
||||
POSTGRES_DB = "postgres";
|
||||
};
|
||||
|
||||
extraOptions = [
|
||||
"--network=podman"
|
||||
];
|
||||
|
||||
autoStart = true;
|
||||
};
|
||||
|
||||
# Redis cache for Immich
|
||||
containers.immich-redis = {
|
||||
image = "docker.io/redis:7.2-alpine";
|
||||
|
||||
extraOptions = [
|
||||
"--network=podman"
|
||||
];
|
||||
|
||||
autoStart = true;
|
||||
};
|
||||
};
|
||||
};
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue