First commit
This commit is contained in:
92
immich-compose.yml
Normal file
92
immich-compose.yml
Normal file
@@ -0,0 +1,92 @@
|
|||||||
|
# Immich - Self-Hosted Photo & Video Manager
|
||||||
|
# https://docs.immich.app
|
||||||
|
# Usage: docker compose up -d
|
||||||
|
|
||||||
|
name: immich
|
||||||
|
|
||||||
|
services:
|
||||||
|
immich-server:
|
||||||
|
container_name: immich_server
|
||||||
|
image: ghcr.io/immich-app/immich-server:${IMMICH_VERSION}
|
||||||
|
restart: unless-stopped
|
||||||
|
volumes:
|
||||||
|
- ${UPLOAD_LOCATION}:/usr/src/app/upload
|
||||||
|
- /etc/localtime:/etc/localtime:ro
|
||||||
|
# Optional: Mount an existing photo library as a read-only external library
|
||||||
|
# - ${EXTERNAL_LIBRARY_PATH}:/mnt/external:ro
|
||||||
|
env_file:
|
||||||
|
- .env
|
||||||
|
ports:
|
||||||
|
- "2283:2283"
|
||||||
|
depends_on:
|
||||||
|
postgres:
|
||||||
|
condition: service_healthy
|
||||||
|
redis:
|
||||||
|
condition: service_healthy
|
||||||
|
healthcheck:
|
||||||
|
test: ["CMD-SHELL", "curl -f http://localhost:2283/api/server/ping || exit 1"]
|
||||||
|
interval: 30s
|
||||||
|
timeout: 10s
|
||||||
|
retries: 5
|
||||||
|
start_period: 60s
|
||||||
|
networks:
|
||||||
|
- immich-net
|
||||||
|
|
||||||
|
immich-machine-learning:
|
||||||
|
container_name: immich_machine_learning
|
||||||
|
# For hardware-accelerated ML inference, see:
|
||||||
|
# https://docs.immich.app/features/ml-hardware-acceleration
|
||||||
|
image: ghcr.io/immich-app/immich-machine-learning:${IMMICH_VERSION}
|
||||||
|
restart: unless-stopped
|
||||||
|
volumes:
|
||||||
|
- ${MODEL_CACHE}:/cache
|
||||||
|
env_file:
|
||||||
|
- .env
|
||||||
|
healthcheck:
|
||||||
|
test: ["CMD-SHELL", "python3 -c \"import urllib.request; urllib.request.urlopen('http://localhost:3003/ping')\" || exit 1"]
|
||||||
|
interval: 30s
|
||||||
|
timeout: 10s
|
||||||
|
retries: 5
|
||||||
|
start_period: 60s
|
||||||
|
networks:
|
||||||
|
- immich-net
|
||||||
|
|
||||||
|
redis:
|
||||||
|
container_name: immich_redis
|
||||||
|
image: docker.io/valkey/valkey:9-alpine
|
||||||
|
restart: unless-stopped
|
||||||
|
healthcheck:
|
||||||
|
test: ["CMD-SHELL", "redis-cli ping || exit 1"]
|
||||||
|
interval: 10s
|
||||||
|
timeout: 5s
|
||||||
|
retries: 5
|
||||||
|
networks:
|
||||||
|
- immich-net
|
||||||
|
|
||||||
|
postgres:
|
||||||
|
container_name: immich_postgres
|
||||||
|
# Immich requires a custom Postgres image with pgvecto-rs / VectorChord for ML similarity search
|
||||||
|
image: ghcr.io/immich-app/postgres:14-vectorchord0.4.3-pgvectors0.2.0
|
||||||
|
restart: unless-stopped
|
||||||
|
environment:
|
||||||
|
POSTGRES_PASSWORD: ${DB_PASSWORD}
|
||||||
|
POSTGRES_USER: ${DB_USERNAME}
|
||||||
|
POSTGRES_DB: ${DB_DATABASE_NAME}
|
||||||
|
POSTGRES_INITDB_ARGS: "--data-checksums"
|
||||||
|
volumes:
|
||||||
|
# NOTE: Network shares (NFS/iSCSI) are NOT supported for the database volume.
|
||||||
|
# Use a local path only.
|
||||||
|
- ${DB_DATA_LOCATION}:/var/lib/postgresql/data
|
||||||
|
healthcheck:
|
||||||
|
test: ["CMD-SHELL", "pg_isready -U ${DB_USERNAME} -d ${DB_DATABASE_NAME}"]
|
||||||
|
interval: 10s
|
||||||
|
timeout: 5s
|
||||||
|
retries: 10
|
||||||
|
start_period: 30s
|
||||||
|
networks:
|
||||||
|
- immich-net
|
||||||
|
|
||||||
|
networks:
|
||||||
|
immich-net:
|
||||||
|
name: immich-net
|
||||||
|
driver: bridge
|
||||||
7
immich.env.example
Normal file
7
immich.env.example
Normal file
@@ -0,0 +1,7 @@
|
|||||||
|
IMMICH_VERSION=latest
|
||||||
|
UPLOAD_LOCATION=/mnt/HomeStorage02/
|
||||||
|
MODEL_CACHE=
|
||||||
|
DB_PASSWORD=
|
||||||
|
DB_USERNAME=
|
||||||
|
DB_DATABASE_NAME=
|
||||||
|
DB_DATABASE_NAM=
|
||||||
Reference in New Issue
Block a user