working test deploy config

This commit is contained in:
2026-06-19 22:55:00 -07:00
parent c4cc268ea8
commit f133d11123
18 changed files with 268 additions and 19 deletions
+45
View File
@@ -0,0 +1,45 @@
services:
db:
image: docker.io/library/postgres:16-alpine
restart: unless-stopped
# NOTE: Change POSTGRES_PASSWORD in production. Consider using Docker secrets or
# a managed PostgreSQL service instead of local credentials.
environment:
POSTGRES_DB: kmountain
POSTGRES_USER: postgres
POSTGRES_PASSWORD: postgres
volumes:
- pgdata:/var/lib/postgresql/data
healthcheck:
test: ["CMD-SHELL", "pg_isready -U postgres"]
interval: 5s
timeout: 5s
retries: 5
# NOTE: Update KMTN_CORS_ORIGINS in production to your actual domain(s).
# Set KMTN_DATABASE_URL to your managed PostgreSQL connection if not using the local db service.
api:
image: truenas.local:35000/kmtnflower-api:latest
restart: unless-stopped
environment:
KMTN_DATABASE_URL: postgresql+asyncpg://postgres:postgres@db:5432/kmountain
KMTN_CORS_ORIGINS: '["http://localhost:4200", "http://localhost"]'
ports:
- "8000:8000"
depends_on:
db:
condition: service_healthy
frontend:
image: truenas.local:35000/kmtnflower:latest
restart: unless-stopped
environment:
API_UPSTREAM: http://api:8000
API_PUBLIC_URL: "http://truenas.local:8000"
ports:
- "4200:80"
depends_on:
- api
volumes:
pgdata: