mirror of
https://github.com/margrop/wrong-notebook.git
synced 2026-12-02 07:59:31 +08:00
- Add comments and new variables to .env.example - Configure NextAuth trustHost for dynamic URL - Update Gemini model to 2.5-flash
31 lines
1.1 KiB
Plaintext
31 lines
1.1 KiB
Plaintext
# 数据库连接地址
|
||
# 本地开发通常使用 SQLite,路径相对于 prisma/schema.prisma
|
||
DATABASE_URL="file:./dev.db"
|
||
|
||
# NextAuth 会话加密密钥
|
||
# 生产环境必须修改!可以使用 `openssl rand -base64 32` 生成
|
||
NEXTAUTH_SECRET="supersecret-dev-secret"
|
||
|
||
# 应用的基础 URL
|
||
# 本地开发通常是 http://localhost:3000
|
||
# 生产环境如果使用 Docker 且 IP 不固定,建议注释掉此项并启用 AUTH_TRUST_HOST
|
||
# NEXTAUTH_URL="http://localhost:3000"
|
||
|
||
# 信任 Host 请求头
|
||
# 设置为 true 时,NextAuth 会根据请求头自动推断 URL,适合 Docker/PaaS 环境
|
||
AUTH_TRUST_HOST=true
|
||
|
||
# AI 服务提供商配置
|
||
# 可选值: "gemini" (默认) 或 "openai"
|
||
AI_PROVIDER="gemini"
|
||
|
||
# OpenAI 配置 (当 AI_PROVIDER="openai" 时需要)
|
||
OPENAI_API_KEY=""
|
||
OPENAI_BASE_URL="" # 可选,用于兼容的 API 服务
|
||
OPENAI_MODEL="gpt-4o" # 可选,默认为 gpt-4o
|
||
|
||
# Google Gemini 配置 (当 AI_PROVIDER="gemini" 时需要)
|
||
GOOGLE_API_KEY=""
|
||
GEMINI_BASE_URL="" # 可选,用于自定义 API 地址
|
||
GEMINI_MODEL="gemini-2.5-flash" # 可选,默认为 gemini-2.5-flash
|