version: "3.8" name: immich services: immich-server: container_name: immich_server image: ghcr.io/immich-app/immich-server:${IMMICH_VERSION:-release} volumes: - ${UPLOAD_LOCATION}:/data - /etc/localtime:/etc/localtime:ro env_file: - stack.env ports: - '3011:2283' depends_on: - redis - database restart: always healthcheck: disable: false networks: - private_secured_network immich-microservices: container_name: immich_microservices image: ghcr.io/immich-app/immich-server:${IMMICH_VERSION:-release} command: "start.sh microservices" volumes: - ${UPLOAD_LOCATION}:/data - /etc/localtime:/etc/localtime:ro env_file: - stack.env depends_on: - redis - database restart: always networks: - private_secured_network immich-machine-learning: container_name: immich_machine_learning image: ghcr.io/immich-app/immich-machine-learning:${IMMICH_VERSION:-release} volumes: - /opt/immich/model-cache:/cache env_file: - stack.env restart: always healthcheck: disable: false networks: - private_secured_network redis: container_name: immich_redis image: docker.io/valkey/valkey:8-bookworm@sha256:facc1d2c3462975c34e10fccb167bfa92b0e0dbd992fc282c29a61c3243afb11 healthcheck: test: redis-cli ping || exit 1 restart: always env_file: - stack.env networks: - private_secured_network database: container_name: immich_postgres image: ghcr.io/immich-app/postgres:14-vectorchord0.4.3-pgvectors0.2.0@sha256:32324a2f41df5de9efe1af166b7008c3f55646f8d0e00d9550c16c9822366b4a environment: POSTGRES_PASSWORD: ${DB_PASSWORD} POSTGRES_USER: ${DB_USERNAME} POSTGRES_DB: ${DB_DATABASE_NAME} POSTGRES_INITDB_ARGS: '--data-checksums' volumes: - ${DB_DATA_LOCATION}:/var/lib/postgresql/data shm_size: 128mb restart: always env_file: - stack.env networks: - private_secured_network volumes: model-cache: driver: local driver_opts: type: none o: bind device: /opt/immich/model-cache networks: private_secured_network: external: true