Skip to content

Commit ee972da

Browse files
committed
[fix]: 解决隐私问题
1 parent 64b1e75 commit ee972da

File tree

3 files changed

+4
-7
lines changed

3 files changed

+4
-7
lines changed

.env

Lines changed: 0 additions & 4 deletions
This file was deleted.

.gitignore

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
11
env
22
__pycache__
33
articles
4-
app.log
4+
app.log
5+
.env

app/core/config.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6,10 +6,10 @@
66
class Settings:
77
PROJECT_NAME: str = "JieNote Backend" # 项目名称
88
VERSION: str = "1.0.0" # 项目版本
9-
SQLALCHEMY_DATABASE_URL = "mysql+asyncmy://root:[email protected]:3306/JieNote" # 替换为实际的用户名、密码和数据库名称
9+
SQLALCHEMY_DATABASE_URL = os.getenv("SQLALCHEMY_DATABASE_URL", "default") # 替换为实际的用户名、密码和数据库名称
1010
SECRET_KEY: str = os.getenv("SECRET_KEY", "default_secret_key") # JWT密钥
1111
ALGORITHM: str = "HS256" # JWT算法
12-
ACCESS_TOKEN_EXPIRE_MINUTES: int = 1440 # token过期时间
12+
ACCESS_TOKEN_EXPIRE_MINUTES: int = 5 # token过期时间
1313
REFRESH_TOKEN_EXPIRE_DAYS: int = 7 # 刷新token过期时间7天
1414
SMTP_SERVER: str = "smtp.163.com" # SMTP服务器
1515
SMTP_PORT: int = 465 # SMTP端口

0 commit comments

Comments
 (0)