Files
jiu/deploy/production.env.template
wangjia a49a962161 devops: 边缘层加固——nginx limit_conn/UA 拦截/防盗链/下载限速 + jiu_redis 容器(todo #1/#2/#3)
nginx:店铺列表专属 2r/s zone、公开路径 limit_conn、抓取库/空 UA 403(OG 页
不拦空 UA 防误杀社交爬虫)、/images 防盗链(none 放行微信 webview)、
/downloads 限并发+限速。compose 新增 jiu_redis(64mb noeviction 无持久化,
仅回环);env 模板加 REDIS_ADDR。

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
2026-07-05 10:42:23 +08:00

18 lines
769 B
Bash
Raw Permalink 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.
SERVER_MODE=release
# ali 主站:nginx(443) 反代 127.0.0.1:80812026-07-02 割接后口径)
SERVER_PORT=8081
SERVER_CORS_ORIGIN=https://jiu.51yanmei.com
DATABASE_DSN=root:CHANGE_ME_DB_PASS@tcp(127.0.0.1:3306)/jiu_db?charset=utf8mb4&parseTime=True&loc=Local
JWT_SECRET=CHANGE_ME_RANDOM_32CHARS
JWT_ACCESS_EXPIRE_MIN=60
JWT_REFRESH_EXPIRE_H=168
STORAGE_UPLOAD_DIR=/opt/jiu/images
STORAGE_BASE_URL=https://jiu.51yanmei.com/images
STORAGE_PUBLIC_URL=https://jiu.51yanmei.com
STORAGE_WEB_DIR=/opt/jiu/web
DB_PASSWORD=CHANGE_ME_DB_PASS
# pay 回调/下单 HMAC 共享密钥(与 pay 侧一致,Bitwarden 渲染)
PAY_SECRET=CHANGE_ME_PAY_SECRET
# 限流/登录锁状态外置(jiu_redis 容器,仅回环;留空=进程内存模式)
REDIS_ADDR=127.0.0.1:6379