version: '3' services: db: image: postgres:15 environment: POSTGRES_USER: forumlify POSTGRES_PASSWORD: 123456 POSTGRES_DB: forumlify volumes: - ./schema.sql:/docker-entrypoint-initdb.d/schema.sql - db_data:/var/lib/postgresql/data ports: - "5432:5432" restart: unless-stopped app: # 从 GHCR 拉取镜像(每次 push Lite 自动重建),不再本地构建 image: ghcr.io/furrium/forumlify:lite ports: - "3000:3000" depends_on: - db environment: DATABASE_URL: postgresql://forumlify:123456@db:5432/forumlify PORT: 3000 ENABLE_CAPTCHA: "true" JWT_SECRET: "7sALTz9fZZvoIT2iLc1Uox4mo3bgvofzivIFq6HSPiU=" # 信任反向代理(Nginx / Docker 端口转发),修复限流警告 TRUST_PROXY: "true" volumes: - ./uploads:/app/uploads restart: unless-stopped volumes: db_data: