57 lines
1.7 KiB
YAML
57 lines
1.7 KiB
YAML
services:
|
|
votc:
|
|
build: .
|
|
container_name: votc
|
|
restart: unless-stopped
|
|
environment:
|
|
- DATABASE_URL=postgresql://votc:votc_password@votc-db:5432/votc
|
|
- SMTP_HOST=mx.jeffemmett.com
|
|
- SMTP_PORT=587
|
|
- SMTP_USER=noreply@jeffemmett.com
|
|
- SMTP_PASS=${SMTP_PASS}
|
|
- EMAIL_FROM=Valley of the Commons <noreply@jeffemmett.com>
|
|
- ADMIN_API_KEY=${ADMIN_API_KEY}
|
|
- ADMIN_EMAILS=${ADMIN_EMAILS:-jeff@jeffemmett.com}
|
|
- NODE_ENV=production
|
|
- GOOGLE_SHEET_ID=1uZy21IjIwAES92ki6K33CtiTfEzGoUlxQ8jk3IzA0qI
|
|
- GOOGLE_SERVICE_ACCOUNT_FILE=/run/secrets/google-service-account.json
|
|
- MOLLIE_API_KEY=${MOLLIE_API_KEY}
|
|
- BASE_URL=https://valleyofthecommons.com
|
|
volumes:
|
|
- ./google-service-account.json:/run/secrets/google-service-account.json:ro
|
|
depends_on:
|
|
votc-db:
|
|
condition: service_healthy
|
|
labels:
|
|
- "traefik.enable=true"
|
|
- "traefik.http.routers.votc.rule=Host(`valleyofthecommons.com`) || Host(`www.valleyofthecommons.com`) || Host(`votc.jeffemmett.com`)"
|
|
- "traefik.http.services.votc.loadbalancer.server.port=3000"
|
|
networks:
|
|
- traefik-public
|
|
|
|
votc-db:
|
|
image: postgres:16-alpine
|
|
container_name: votc-db
|
|
restart: unless-stopped
|
|
environment:
|
|
- POSTGRES_USER=votc
|
|
- POSTGRES_PASSWORD=votc_password
|
|
- POSTGRES_DB=votc
|
|
volumes:
|
|
- votc-postgres-data:/var/lib/postgresql/data
|
|
- ./db/schema.sql:/docker-entrypoint-initdb.d/01-schema.sql:ro
|
|
healthcheck:
|
|
test: ["CMD-SHELL", "pg_isready -U votc"]
|
|
interval: 5s
|
|
timeout: 5s
|
|
retries: 5
|
|
networks:
|
|
- traefik-public
|
|
|
|
volumes:
|
|
votc-postgres-data:
|
|
|
|
networks:
|
|
traefik-public:
|
|
external: true
|