Files
lunar-mini/.gitea/deploy/docker-compose.yml
T
gouki fc7a30ad9d refactor(deploy): 部署方案改为 1Panel 原生集成
- 移除系统 nginx 配置(1Panel 用内置 OpenResty,系统 nginx 不适用)
- 站点反代改用 1Panel 网站-反向代理;容器改用 1Panel Compose 编排
- 定时触发由 systemd timer 改为 1Panel 计划任务(日志面板可视)
- 脚本上传改用 1Panel 文件管理器,PULL_DEPLOY.md 全步骤 1Panel 化
- deploy.sh/deploy-watch.sh 核心逻辑不变(原子切换+健康检查+回滚)
2026-08-09 10:37:06 +00:00

21 lines
882 B
YAML
Raw Blame History

This file contains ambiguous Unicode characters
This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
# lunar-server 容器编排(doc79 同机部署,通过 1Panel Compose 编排创建)
# 用法:1Panel → 容器 → Compose → 创建编排,粘贴本文件内容后部署。
# 前置:先在 /opt/lunar/production/.env 写入全部生产环境变量(模板见 PULL_DEPLOY.md)。
# 之后 CI 产物由 1Panel 计划任务触发的 deploy-watch.sh 自动替换
# /opt/lunar/production/current 并重启容器(container_name 必须保持 lunar-server
# deploy.sh 按此名称重启)。
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