Files
cms-SiteForge/compose.yaml
T
浅念 5c7643fcf2 upgrade: adopt V8.12.0-dev.1 (V8.11 unified professional UI + V8.12 workflow usability)
- Overlay 26 changed files from SiteForge_Enterprise_V8_12 (UI layer only:
  professional-ui.js/css, workspace/factory-v2/operations/editor templates,
  +2 test files, compose/ci/scripts/docs)
- Re-apply v8_workflows type-mapping fix (类型/分类) lost in upgrade
- Pin compose project name to siteforge-v8-10 so existing data volumes
  (hesupipe site 483295c29ea0, 193 entries) keep attached
- Drop stray .s10_* state files; ignore .s10_*/.sf_*/.s87_* patterns
- Plan/spec revisions per plan-review round 1 (icons are new design,
  real test assertions, recorded deviations)

Tests: 226 passed / 1 env-only failure (test needs node binary in PATH,
absent in python:3.12-slim container; host node v24 --check all 9 JS OK)

Co-Authored-By: Claude Code <noreply@anthropic.com>
2026-10-22 17:02:45 +08:00

84 lines
3.1 KiB
YAML

name: siteforge-v8-10 # pinned: existing volumes with production data follow this project name
services:
siteforge:
build:
context: .
dockerfile: Dockerfile
args:
SITEFORGE_GIT_SHA: ${SITEFORGE_GIT_SHA:-unknown}
image: siteforge/web:8.12.0-dev.1
init: true
restart: unless-stopped
ports:
- "127.0.0.1:${SITEFORGE_PORT:-8787}:8787"
environment:
SITEFORGE_DATA_DIR: /data
SITEFORGE_MAX_PENDING_JOBS: ${SITEFORGE_MAX_PENDING_JOBS:-100}
SITEFORGE_MAX_PENDING_JOBS_PER_SITE: ${SITEFORGE_MAX_PENDING_JOBS_PER_SITE:-5}
SITEFORGE_OUTBOUND_PORTS: ${SITEFORGE_OUTBOUND_PORTS:-80,443}
SITEFORGE_MYSQL_ALLOWED_HOSTS: ${SITEFORGE_MYSQL_ALLOWED_HOSTS:-}
SITEFORGE_MYSQL_ALLOWED_TABLES: ${SITEFORGE_MYSQL_ALLOWED_TABLES:-}
SITEFORGE_ADMIN_PASSWORD: ${SITEFORGE_ADMIN_PASSWORD:?Set SITEFORGE_ADMIN_PASSWORD in .env}
SITEFORGE_SESSION_SECRET: ${SITEFORGE_SESSION_SECRET:?Set SITEFORGE_SESSION_SECRET in .env}
SITEFORGE_COOKIE_SECURE: "${SITEFORGE_COOKIE_SECURE:-false}"
SITEFORGE_PUBLISH_ROOT: /published
SITEFORGE_REQUIRE_RELEASE_APPROVAL: "true"
volumes:
- siteforge_data:/data
- siteforge_published:/published
read_only: true
tmpfs:
- /tmp:size=128m,mode=1777
security_opt:
- no-new-privileges:true
cap_drop:
- ALL
pids_limit: 128
healthcheck:
test: ["CMD", "python", "-c", "import urllib.request; urllib.request.urlopen('http://127.0.0.1:8787/api/health', timeout=3)"]
interval: 30s
timeout: 5s
retries: 3
start_period: 30s
worker:
image: siteforge/web:8.12.0-dev.1
depends_on:
siteforge: {condition: service_started}
init: true
restart: unless-stopped
command: ["python", "-m", "app.worker"]
environment:
SITEFORGE_DATA_DIR: /data
SITEFORGE_MAX_PENDING_JOBS: ${SITEFORGE_MAX_PENDING_JOBS:-100}
SITEFORGE_MAX_PENDING_JOBS_PER_SITE: ${SITEFORGE_MAX_PENDING_JOBS_PER_SITE:-5}
SITEFORGE_OUTBOUND_PORTS: ${SITEFORGE_OUTBOUND_PORTS:-80,443}
SITEFORGE_MYSQL_ALLOWED_HOSTS: ${SITEFORGE_MYSQL_ALLOWED_HOSTS:-}
SITEFORGE_MYSQL_ALLOWED_TABLES: ${SITEFORGE_MYSQL_ALLOWED_TABLES:-}
SITEFORGE_MYSQL_CA_FILE: ${SITEFORGE_MYSQL_CA_FILE:-}
# Development-only env secret references; use compose.mysql-secrets.yaml for production files.
SITEFORGE_MYSQL_READ_USER: ${SITEFORGE_MYSQL_READ_USER:-}
SITEFORGE_MYSQL_READ_PASSWORD: ${SITEFORGE_MYSQL_READ_PASSWORD:-}
SITEFORGE_JOB_POLL_SECONDS: "1.5"
SITEFORGE_BUILD_TIMEOUT_SECONDS: "${SITEFORGE_BUILD_TIMEOUT_SECONDS:-300}"
SITEFORGE_BUILD_MAX_ATTEMPTS: "${SITEFORGE_BUILD_MAX_ATTEMPTS:-3}"
volumes:
- siteforge_data:/data
read_only: true
tmpfs:
- /tmp:size=128m,mode=1777
security_opt:
- no-new-privileges:true
cap_drop:
- ALL
pids_limit: 128
healthcheck:
test: ["CMD", "python", "-m", "app.worker_health"]
interval: 20s
timeout: 5s
retries: 3
start_period: 30s
volumes:
siteforge_data:
siteforge_published: