Replace manual nginx + SSL certificates with Caddy for automatic Let's Encrypt certificate management. Remove direct HTTP port exposure, route web traffic through Caddy (80/443) via Docker internal network. SSH remains on port 2222.
23 lines
482 B
Plaintext
23 lines
482 B
Plaintext
# Gitea 版本
|
||
GITEA_VERSION=1.25.4
|
||
|
||
# 端口配置
|
||
HTTP_PORT=3000
|
||
SSH_PORT=2222
|
||
|
||
# 时区
|
||
TZ=Asia/Shanghai
|
||
|
||
# SSH 端口配置(告知 Gitea 对外 SSH 端口,用于 clone 地址显示)
|
||
GITEA__server__SSH_PORT=${SSH_PORT}
|
||
|
||
# Git LFS 配置
|
||
GITEA__lfs__START_SERVER=true
|
||
GITEA__lfs__PATH=/data/git/lfs
|
||
|
||
# 禁用公开注册(仅管理员可创建账号)
|
||
GITEA__service__DISABLE_REGISTRATION=true
|
||
|
||
# 域名配置(Caddy 反向代理 + 自动 HTTPS)
|
||
DOMAIN=git.example.com
|