2024-01-04 11:22:21 +00:00
|
|
|
version: "3"
|
|
|
|
|
|
|
|
services:
|
2024-03-29 15:18:39 +00:00
|
|
|
db-migration:
|
|
|
|
depends_on:
|
|
|
|
db:
|
|
|
|
condition: service_healthy
|
|
|
|
image: infisical/infisical:latest-postgres
|
|
|
|
env_file: .env
|
|
|
|
command: npm run migration:latest
|
|
|
|
pull_policy: always
|
|
|
|
networks:
|
|
|
|
- infisical
|
|
|
|
|
2024-01-04 11:22:21 +00:00
|
|
|
backend:
|
|
|
|
restart: unless-stopped
|
|
|
|
depends_on:
|
2024-03-29 15:18:39 +00:00
|
|
|
db:
|
|
|
|
condition: service_healthy
|
|
|
|
redis:
|
|
|
|
condition: service_started
|
|
|
|
db-migration:
|
|
|
|
condition: service_completed_successfully
|
|
|
|
image: infisical/infisical:latest-postgres
|
|
|
|
pull_policy: always
|
2024-01-04 11:22:21 +00:00
|
|
|
env_file: .env
|
|
|
|
ports:
|
|
|
|
- 80:8080
|
|
|
|
environment:
|
|
|
|
- NODE_ENV=production
|
|
|
|
|
|
|
|
redis:
|
|
|
|
image: redis
|
|
|
|
env_file: .env
|
|
|
|
environment:
|
|
|
|
- ALLOW_EMPTY_PASSWORD=yes
|
|
|
|
ports:
|
|
|
|
- 6379:6379
|
|
|
|
volumes:
|
2024-03-29 15:18:39 +00:00
|
|
|
- /mnt/nvme/redis_data:/data
|
2024-01-04 11:22:21 +00:00
|
|
|
|
2024-03-29 15:18:39 +00:00
|
|
|
db:
|
|
|
|
image: postgres:14-alpine
|
2024-01-04 11:22:21 +00:00
|
|
|
restart: always
|
|
|
|
env_file: .env
|
|
|
|
volumes:
|
2024-03-29 15:18:39 +00:00
|
|
|
- /mnt/nvme/pg_data:/var/lib/postgresql/data
|
|
|
|
networks:
|
|
|
|
- infisical
|
|
|
|
healthcheck:
|
|
|
|
test: "pg_isready --username=${POSTGRES_USER} && psql --username=${POSTGRES_USER} --list"
|
|
|
|
interval: 5s
|
|
|
|
timeout: 10s
|
|
|
|
retries: 10
|