Compose-Examples/examples/immich/docker-compose.yml

82 wiersze
2.2 KiB
YAML

2023-12-16 04:12:16 +00:00
services:
2023-12-16 04:12:16 +00:00
immich-server:
2025-05-21 22:55:54 +00:00
image: ghcr.io/immich-app/immich-server:${IMMICH_VERSION:-release}
container_name: immich-server
2023-12-16 04:12:16 +00:00
volumes:
- ${UPLOAD_LOCATION}:/usr/src/app/upload
- /etc/localtime:/etc/localtime:ro
env_file:
- .env
environment:
- NODE_ENV=production
ports:
2024-10-15 15:47:30 +00:00
- 2283:2283
2023-12-16 04:12:16 +00:00
expose:
2024-10-15 15:47:30 +00:00
- 2283
2023-12-16 04:12:16 +00:00
depends_on:
- immich-redis
- immich-database
restart: unless-stopped
2025-01-12 14:53:52 +00:00
networks:
- proxy
- immich-internal
2023-12-16 04:12:16 +00:00
#labels:
2025-01-12 14:52:56 +00:00
# - traefik.enable=true
2023-12-16 04:12:16 +00:00
# - traefik.http.routers.immich.rule=Host(`immich.example.com`)
2024-10-15 15:47:30 +00:00
# - traefik.http.services.immich.loadbalancer.server.port=2283
2023-12-16 04:12:16 +00:00
# - traefik.docker.network=proxy
# # Part for local lan services only
# - traefik.http.routers.immich-swagger.rule=Host(`immich.example.com`) && PathPrefix(`/doc`)
# - traefik.http.routers.immich-swagger.middlewares=local-ipwhitelist@file
2023-12-16 04:12:16 +00:00
immich-machine-learning:
2025-05-21 23:04:37 +00:00
image: ghcr.io/immich-app/immich-machine-learning:${IMMICH_VERSION:-release}
2023-12-16 04:12:16 +00:00
container_name: immich-ml
volumes:
- ${UPLOAD_LOCATION}:/usr/src/app/upload
- model-cache:/cache
env_file:
- .env
environment:
- NODE_ENV=production
restart: unless-stopped
2025-01-12 14:53:52 +00:00
networks:
2025-01-13 09:15:10 +00:00
- proxy # machine learning requires internet connecting for model download
2025-01-12 14:53:52 +00:00
- immich-internal
2023-12-16 04:12:16 +00:00
immich-redis:
2025-05-21 22:55:54 +00:00
image: docker.io/valkey/valkey:8-bookworm@sha256:ff21bc0f8194dc9c105b769aeabf9585fea6a8ed649c0781caeac5cb3c247884
2023-12-16 04:12:16 +00:00
container_name: immich-redis
restart: unless-stopped
2025-04-23 23:01:05 +00:00
healthcheck:
test: redis-cli ping || exit 1
2025-01-12 14:53:52 +00:00
networks:
- immich-internal
2023-12-16 04:12:16 +00:00
immich-database:
2025-05-21 22:45:46 +00:00
image: ghcr.io/immich-app/postgres:14-vectorchord0.3.0-pgvectors0.2.0
2023-12-16 04:12:16 +00:00
container_name: immich-database
env_file:
- .env
environment:
POSTGRES_PASSWORD: ${DB_PASSWORD}
POSTGRES_USER: ${DB_USERNAME}
POSTGRES_DB: ${DB_DATABASE_NAME}
2025-05-21 22:47:27 +00:00
POSTGRES_INITDB_ARGS: '--data-checksums'
2023-12-16 04:12:16 +00:00
PG_DATA: /var/lib/postgresql/data
volumes:
- ${DB_DATABASE_LOCATION}:/var/lib/postgresql/data
restart: unless-stopped
2025-01-12 14:53:52 +00:00
networks:
- immich-internal
2023-12-16 04:12:16 +00:00
volumes:
model-cache:
2025-01-12 14:53:52 +00:00
networks:
proxy:
external: true
immich-internal:
2025-03-26 16:22:59 +00:00
internal: true