Foxnouns.NET/docker-compose.yml

69 lines
1.6 KiB
YAML
Raw Normal View History

2024-09-14 18:07:49 +02:00
services:
backend:
image: backend
build:
context: .
dockerfile: ./Dockerfile.backend
environment:
2024-12-09 18:04:56 +01:00
- "Database:Url=Host=postgres;Database=postgres;Username=postgres;Password=postgres"
- "Database:EnablePooling=true"
2024-09-14 18:07:49 +02:00
- "Host=0.0.0.0"
- "Port=5000"
- "Logging:MetricsPort=5001"
2024-09-14 18:07:49 +02:00
restart: unless-stopped
ports:
- "5006:5000"
- "5007:5001"
2024-09-14 18:07:49 +02:00
volumes:
- ./docker/config.ini:/app/config.ini
frontend:
image: frontend
2024-12-09 18:04:56 +01:00
build:
context: ./
dockerfile: ./Foxnouns.Frontend/Dockerfile
2024-09-14 18:07:49 +02:00
restart: unless-stopped
2024-12-09 18:04:56 +01:00
env_file: ./docker/frontend.env
environment:
- "PRIVATE_API_HOST=http://rate:5003/api"
- "PRIVATE_INTERNAL_API_HOST=http://backend:5000/api"
2024-09-14 18:07:49 +02:00
rate:
image: rate
build: ./rate
environment:
- "PORT=5003"
restart: unless-stopped
volumes:
- ./docker/proxy-config.json:/app/proxy-config.json
postgres:
image: docker.io/postgres:16
command: [ "postgres",
"-c", "max-connections=1000",
"-c", "timezone=Etc/UTC",
"-c", "max_wal_size=1GB",
"-c", "min_wal_size=80MB",
"-c", "shared_buffers=128MB" ]
environment:
- "POSTGRES_PASSWORD=postgres"
restart: unless-stopped
volumes:
- postgres_data:/var/lib/postgresql/data
caddy:
image: docker.io/caddy:2
restart: unless-stopped
ports:
- "5004:80"
2024-12-09 18:04:56 +01:00
- "5005:81"
2024-09-14 18:07:49 +02:00
volumes:
- ./docker/Caddyfile:/etc/caddy/Caddyfile
- caddy_data:/data
- caddy_config:/config
volumes:
caddy_data:
caddy_config:
postgres_data: