-
-
Notifications
You must be signed in to change notification settings - Fork 45
Expand file tree
/
Copy pathenv.example
More file actions
59 lines (48 loc) · 1.93 KB
/
env.example
File metadata and controls
59 lines (48 loc) · 1.93 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
# eSIM工具环境配置
# 服务器配置
NODE_ENV=development
PORT=3000
# API配置
GIFFGAFF_API_BASE=https://id.giffgaff.com
GIFFGAFF_PUBLIC_API_BASE=https://publicapi.giffgaff.com
SIMYO_API_BASE=https://appapi.simyo.nl
# 日志配置
LOG_LEVEL=info
# CORS配置
# 通用允许来源(本地 server.js 使用);Netlify Functions 使用 ALLOWED_ORIGIN 环境变量
CORS_ORIGIN=*
ALLOWED_ORIGIN=https://esim.cosr.eu.org
# 验证码配置(turnstile | recaptcha | off)
CAPTCHA_PROVIDER=turnstile
# Cloudflare Turnstile 配置
TURNSTILE_SITE_KEY=
TURNSTILE_SECRET_KEY=
# 设为 false 可在紧急情况下跳过 BFF Turnstile 校验(默认 true)
TURNSTILE_ENFORCE=true
# Google reCAPTCHA v2 配置(CAPTCHA_PROVIDER=recaptcha 时必填)
RECAPTCHA_SITE_KEY=
RECAPTCHA_SECRET_KEY=
# 受保护函数访问密钥(要求调用方在 Header x-esim-key 或 body.authKey / ?authKey 携带匹配值)
# ⚠️ 必填:Server 与 Functions/BFF 共享的访问密钥
# 🔐 生成强随机密钥: openssl rand -hex 32
# ❌ 禁止使用默认值或简单密码
ACCESS_KEY=
# 可选:自定义API超时时间(毫秒)
API_TIMEOUT=30000
# Sentry 错误监控配置
# 🔗 前往 https://sentry.io 创建项目获取 DSN
SENTRY_DSN=
# 环境标识(production, staging, development)
SENTRY_ENVIRONMENT=production
# 版本标识(可选,留空则自动使用 Netlify COMMIT_REF 或 package.json 版本)
# 格式示例:esim-tools@1.0.0 或 esim-tools@abc1234
# Netlify 部署时会自动读取 COMMIT_REF 生成短哈希版本,无需手动配置
SENTRY_RELEASE=
# Sentry Source Maps 上传配置(可选,用于生产环境错误堆栈映射)
# 🔗 获取 Auth Token: https://sentry.io/settings/auth-tokens/
# 需要权限: project:releases, org:read
SENTRY_AUTH_TOKEN=
# 组织 slug(从 Sentry 项目 URL 获取: https://sentry.io/organizations/[ORG_SLUG]/...)
SENTRY_ORG=
# 项目 slug(从 Sentry 项目设置获取)
SENTRY_PROJECT=