makakam

imm_compose

Sep 18th, 2024
33
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 2.67 KB | None | 0 0
  1. #
  2. # WARNING: Make sure to use the docker-compose.yml of the current release:
  3. #
  4. # https://github.com/immich-app/immich/releases/latest/download/docker-compose.yml
  5. #
  6. # The compose file on main may not be compatible with the latest release.
  7. #
  8.  
  9. name: immich
  10.  
  11. services:
  12. immich-server:
  13. container_name: immich_server
  14. image: ghcr.io/immich-app/immich-server:${IMMICH_VERSION:-release}
  15. #command: ['start.sh', 'immich']
  16. volumes:
  17. - ${UPLOAD_LOCATION}:/usr/src/app/upload
  18. - /etc/localtime:/etc/localtime:ro
  19. env_file:
  20. - stack.env
  21. ports:
  22. - 2283:3001
  23. depends_on:
  24. - redis
  25. - database
  26. restart: always
  27.  
  28.  
  29.  
  30. immich-machine-learning:
  31. container_name: immich_machine_learning
  32. # For hardware acceleration, add one of -[armnn, cuda, openvino] to the image tag.
  33. # Example tag: ${IMMICH_VERSION:-release}-cuda
  34. image: ghcr.io/immich-app/immich-machine-learning:${IMMICH_VERSION:-release}
  35. # extends: # uncomment this section for hardware acceleration - see https://immich.app/docs/features/ml-hardware-acceleration
  36. # file: hwaccel.ml.yml
  37. # service: cpu # set to one of [armnn, cuda, openvino, openvino-wsl] for accelerated inference - use the `-wsl` version for WSL2 where applicable
  38. volumes:
  39. - model-cache:/cache
  40. env_file:
  41. - stack.env
  42. restart: always
  43.  
  44. redis:
  45. container_name: immich_redis
  46. image: docker.io/redis:6.2-alpine@sha256:d6c2911ac51b289db208767581a5d154544f2b2fe4914ea5056443f62dc6e900
  47. healthcheck:
  48. test: redis-cli ping || exit 1
  49. restart: always
  50.  
  51. database:
  52. container_name: immich_postgres
  53. image: docker.io/tensorchord/pgvecto-rs:pg14-v0.2.0@sha256:90724186f0a3517cf6914295b5ab410db9ce23190a2d9d0b9dd6463e3fa298f0
  54. environment:
  55. POSTGRES_PASSWORD: ${DB_PASSWORD}
  56. POSTGRES_USER: ${DB_USERNAME}
  57. POSTGRES_DB: ${DB_DATABASE_NAME}
  58. POSTGRES_INITDB_ARGS: '--data-checksums'
  59. volumes:
  60. - ${DB_DATA_LOCATION}:/var/media/CR/immich/data
  61. healthcheck:
  62. test: pg_isready --dbname='${DB_DATABASE_NAME}' || exit 1; Chksum="$$(psql --dbname='${DB_DATABASE_NAME}' --username='${DB_USERNAME}' --tuples-only --no-align --command='SELECT SUM(checksum_failures) FROM pg_stat_database')"; echo "checksum failure count is $$Chksum"; [ "$$Chksum" = '0' ] || exit 1
  63. interval: 5m
  64. start_interval: 30s
  65. start_period: 5m
  66. command: ["postgres", "-c" ,"shared_preload_libraries=vectors.so", "-c", 'search_path="$$user", public, vectors', "-c", "logging_collector=on", "-c", "max_wal_size=2GB", "-c", "shared_buffers=512MB", "-c", "wal_compression=on"]
  67. restart: always
  68.  
  69. volumes:
  70. model-cache:
Advertisement
Add Comment
Please, Sign In to add comment