- 新增 nginx 反代配置(HTTPS + 本机 8080,含 1Panel 建站替代说明) - 新增 docker-compose.yml(端口仅绑定 127.0.0.1,env_file 注入生产变量) - PULL_DEPLOY.md 重写为完整一次性安装指南:域名/证书/微信合法域名/ 生产环境变量模板/容器/脚本/timer/验证清单 - AUTO_DEPLOY_1PANEL.md 标记废弃(SSH 手工方式违反安全红线)
20 lines
726 B
YAML
20 lines
726 B
YAML
# lunar-server 容器编排(doc79 同机部署)
|
|
# 用法:保存到 /opt/lunar/docker-compose.yml,先创建 /opt/lunar/production/.env
|
|
# (包含全部生产环境变量,见 PULL_DEPLOY.md),然后:
|
|
# docker compose up -d
|
|
# 之后 CI 产物由 deploy-watch.sh 自动替换 /opt/lunar/production/current 并重启容器。
|
|
|
|
services:
|
|
lunar-server:
|
|
image: golang:1.22-bookworm
|
|
container_name: lunar-server
|
|
working_dir: /app
|
|
volumes:
|
|
- /opt/lunar/production/current:/app
|
|
ports:
|
|
- "127.0.0.1:8080:8080" # 只监听本机,对外由 nginx 反代 lunar.neatcn.com
|
|
env_file:
|
|
- /opt/lunar/production/.env
|
|
restart: unless-stopped
|
|
command: /app/bin/server
|