Program/.env.example
2025-01-02 22:33:45 +08:00

53 lines
1.5 KiB
Plaintext
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.

#--------------------
# 基础配置
# 请复制此文件并重命名为.env然后根据实际情况修改配置
#--------------------
# 项目名称
PROJECT_NAME=ExamService
# API版本号
VERSION=1.0.0
# API前缀路径
API_V1_STR=/api/v1
#--------------------
# 数据库配置
#--------------------
# MySQL数据库用户名
MYSQL_USER=your_username
# MySQL数据库密码
MYSQL_PASSWORD=your_secure_password
# MySQL数据库主机地址 (默认: localhost)
MYSQL_HOST=localhost
# MySQL数据库端口 (默认: 3306)
MYSQL_PORT=3306
# MySQL数据库名称
MYSQL_DATABASE=your_database_name
# 是否启用SQL语句打印 (True/False)
SQLALCHEMY_ECHO=True
#--------------------
# 安全配置
#--------------------
# JWT密钥 (重要: 生产环境必须修改为强密钥)
SECRET_KEY=please_change_this_to_complex_random_secret
# JWT加密算法 (可选: HS256, HS384, HS512)
ALGORITHM=HS256
# 访问令牌过期时间(分钟)
ACCESS_TOKEN_EXPIRE_MINUTES=30
#--------------------
# 微信配置
#--------------------
# 微信小程序 AppID (从微信开发者平台获取)
WECHAT_APPID=your_appid_here
# 微信小程序 AppSecret (从微信开发者平台获取,请妥善保管)
WECHAT_APPSECRET=your_appsecret_here
#--------------------
# 安全提示
#--------------------
# 1. 生产环境中请使用强密码和密钥
# 2. 不要将包含敏感信息的.env文件提交到版本控制系统
# 3. 建议定期更新密钥和密码
# 4. 确保文件权限设置正确,只允许必要的用户访问