Files
frame-deploy/docker-compose.yml
bea 0952c1abc9 docs: document VITE_API_BASE_URL and VITE_BASE_URL runtime configuration
- Add VITE_BASE_URL to frame-cms environment in docker-compose.yml (default /)
- Add inline comments explaining both CMS env vars
- Expand README with a runtime environment variables table and
  a subpath deployment example (e.g. serving CMS at /admin)
2026-03-22 14:16:40 +01:00

47 lines
1.3 KiB
YAML

services:
postgres:
image: postgres:18-alpine
restart: unless-stopped
environment:
POSTGRES_USER: ${POSTGRES_USER:-postgres}
POSTGRES_PASSWORD: ${POSTGRES_PASSWORD:-postgres}
POSTGRES_DB: ${POSTGRES_DB:-appdb}
healthcheck:
test: ["CMD-SHELL", "pg_isready -U ${POSTGRES_USER:-postgres}"]
interval: 5s
timeout: 5s
retries: 5
volumes:
- ./data/postgres:/var/lib/postgresql/data
frame-backend:
image: docker.panic.haus/frame-backend:latest
restart: unless-stopped
depends_on:
postgres:
condition: service_healthy
env_file:
- backend.env
ports:
- "${BACKEND_PORT:-8080}:8080"
frame-cms:
image: docker.panic.haus/frame-cms:latest
restart: unless-stopped
depends_on:
- frame-backend
environment:
# URL of the backend API as seen by the browser.
# Override this when the API is not at the default path.
VITE_API_BASE_URL: ${VITE_API_BASE_URL:-http://localhost:8080}
# Base path where the CMS is served (e.g. /admin for frame.example.com/admin).
# Defaults to / (served at the root).
VITE_BASE_URL: ${VITE_BASE_URL:-/}
ports:
- "${CMS_PORT:-3000}:80"
healthcheck:
test: ["CMD", "wget", "-qO-", "http://localhost/"]
interval: 30s
timeout: 5s
retries: 3