Repository navigation
Expand file tree
/
Copy path.env.hackathon.example
More file actions
110 lines (91 loc) · 3.56 KB
/
Copy path.env.hackathon.example
File metadata and controls
110 lines (91 loc) · 3.56 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
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
# =============================================================================
# Hackathon / Demo environment template
# =============================================================================
# For HACKATHON mode (DATA_MODE=mock):
# cp .env.hackathon.example .env
# npm install
# docker compose up -d postgres
# npm run dev:hackathon
#
# For FULL mode (DATA_MODE=live or unset), use .env.example instead:
# cp .env.example .env
# npm install
# npm run dev
#
# Only vars in the "--- Required (hackathon) ---" section are strictly needed
# for hackathon mode. The "--- Required (full mode) ---" section is only
# checked when DATA_MODE is NOT "mock".
# =============================================================================
# --- Required (hackathon mode) ---
# Runtime mode — "mock" enables lightweight preflight (no DATABASE_URL needed)
# Set DATA_MODE=mock for hackathon, or omit/unset it for full production mode.
DATA_MODE=mock
# Signs JWT tokens. Any non-empty string works in hackathon mode.
# For production, generate a strong one:
# openssl rand -base64 32
JWT_SECRET=hackathon-dev-jwt-secret-change-me
# --- Required (full mode only) ---
# These are only validated when DATA_MODE is NOT "mock". You can leave them
# unset in hackathon mode — the server boots without them.
# PostgreSQL connection string
# DATABASE_URL=postgresql://user:password@localhost:5432/xelma
# Socket demo mode — price/round realtime without Prisma chat (defaults on when DATA_MODE=mock)
# SOCKET_DEMO_MODE=true
# --- Optional (safe defaults shown) ---
# Server listen port (hackathon server defaults to 3001)
PORT=3001
# Server
# NODE_ENV=development
# CLIENT_URL=http://localhost:5173
# LOG_LEVEL=info
# API_ONLY=false
# Round / scheduler
# ROUNDS_MOCK_MODE=true
# ROUND_SCHEDULER_ENABLED=false
# ROUND_SCHEDULER_MODE=UP_DOWN
# Oracle / price polling
# ORACLE_POLLING_INTERVAL_MS=10000
# ORACLE_REQUEST_TIMEOUT_MS=5000
# ORACLE_MAX_RETRIES=3
# ORACLE_STALENESS_THRESHOLD_MS=60000
# CoinGecko price feeds (free tier, no API key required)
# COINGECKO_API_URL=https://api.coingecko.com/api/v3/simple/price?ids=stellar&vs_currencies=usd
# COINGECKO_MULTI_PRICE_URL=https://api.coingecko.com/api/v3/simple/price?ids=bitcoin,ethereum,stellar&vs_currencies=usd
# COINCAP_API_URL=https://api.coincap.io/v2/assets/stellar
# Soroban / Stellar — only needed for on-chain round operations.
# Prefer SOROBAN_* (canonical). Aliases also accepted:
# CONTRACT_ID → SOROBAN_CONTRACT_ID
# STELLAR_RPC_URL → SOROBAN_RPC_URL
# SOROBAN_CONTRACT_ID=
# SOROBAN_RPC_URL=https://soroban-testnet.stellar.org
# SOROBAN_NETWORK=testnet
# SOROBAN_ADMIN_SECRET=
# SOROBAN_ORACLE_SECRET=
# Optional aliases (older hackathon / Render templates):
# STELLAR_RPC_URL=https://soroban-testnet.stellar.org
# CONTRACT_ID=
# Keep fail-open for demos (default). Production should use true.
# SOROBAN_FAIL_CLOSED=false
# Database pool tuning (optional)
# DB_CONNECTION_LIMIT=10
# DB_POOL_TIMEOUT_SECONDS=10
# DB_CONNECT_TIMEOUT_SECONDS=10
# DB_STATEMENT_TIMEOUT_MS=0
# DB_PGBOUNCER=false
# Auth / JWT
# JWT_EXPIRY=7d
# Feature flags
# ENABLE_MULTIPLAYER_SOCIAL=true
# ENABLE_SIMULATION=false
# Retention (cleanup of old challenges, messages, audit logs)
# RETENTION_AUTH_CHALLENGES_TTL_DAYS=7
# RETENTION_CHAT_MESSAGES_TTL_DAYS=90
# RETENTION_AUDIT_LOGS_TTL_DAYS=90
# RETENTION_BATCH_SIZE=1000
# Outbox (guaranteed at-least-once notification/websocket delivery)
# OUTBOX_POLL_INTERVAL_SECONDS=5
# OUTBOX_BATCH_SIZE=50
# OUTBOX_MAX_ATTEMPTS=5
# OUTBOX_RETENTION_DAYS=7
# Xelma Bindings (if required by your setup)
# XELMA_API_KEY=