b255a0f90e
Renames src/fabledassistant -> src/scribe and all imports, plus the default DB name and DB user/password (fabled -> scribe) in config + compose. 952 refs / 154 files. Reverses the old 'internal name stays fabledassistant' convention. Code-only: live databases are still physically named 'fabledassistant'. Deployed environments must set POSTGRES_DB / POSTGRES_USER (or rename the DB) since the defaults now resolve to 'scribe'. Repo (FabledScribe), git host (fabledsword), MCP (fabled-git) and the image name (fabledscribe) are intentionally unchanged. ruff check src/ clean locally; CI (typecheck + pytest) is the gate. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
56 lines
1.5 KiB
YAML
56 lines
1.5 KiB
YAML
services:
|
|
app:
|
|
image: git.fabledsword.com/bvandeusen/fabledscribe:latest
|
|
environment:
|
|
DATABASE_URL: "postgresql+asyncpg://scribe:${DB_PASSWORD}@db:5432/scribe"
|
|
SECRET_KEY: "${SECRET_KEY}"
|
|
LOG_LEVEL: "${LOG_LEVEL:-INFO}"
|
|
TRUST_PROXY_HEADERS: "true"
|
|
SECURE_COOKIES: "true"
|
|
networks:
|
|
- scribe_backend
|
|
healthcheck:
|
|
test: ["CMD", "python", "-c", "import urllib.request; urllib.request.urlopen('http://localhost:5000/api/health')"]
|
|
interval: 30s
|
|
timeout: 10s
|
|
retries: 3
|
|
start_period: 30s
|
|
deploy:
|
|
restart_policy:
|
|
condition: on-failure
|
|
max_attempts: 5
|
|
|
|
db:
|
|
image: postgres:16-alpine
|
|
stop_grace_period: 120s
|
|
volumes:
|
|
- pgdata:/var/lib/postgresql/data
|
|
environment:
|
|
POSTGRES_USER: scribe
|
|
POSTGRES_PASSWORD: "${DB_PASSWORD}"
|
|
POSTGRES_DB: scribe
|
|
networks:
|
|
- scribe_backend
|
|
# Lenient by design: a transient host exec/healthcheck stall (incident:
|
|
# runc setns failures -> "unhealthy" -> SIGKILL -> crash loop) must never
|
|
# escalate to killing the DB. Health here only gates app startup order.
|
|
healthcheck:
|
|
test: ["CMD-SHELL", "pg_isready -U scribe"]
|
|
interval: 30s
|
|
timeout: 10s
|
|
retries: 10
|
|
start_period: 180s
|
|
deploy:
|
|
restart_policy:
|
|
condition: on-failure
|
|
delay: 10s
|
|
max_attempts: 0
|
|
window: 120s
|
|
|
|
volumes:
|
|
pgdata:
|
|
|
|
networks:
|
|
scribe_backend:
|
|
driver: overlay
|