Summary
Create a production safety profile that forces fail-closed Soroban, required secrets, disabled stub bets, and refuses to boot if money-path invariants are violated.
Why this matters
Demo-friendly defaults are dangerous if accidentally used in production campaign deployments.
Where to work
src/config/ + preflight
src/index.ts startup
.env.example
- Render production env docs
What to implement
- Define
SAFETY_PROFILE=production|demo.
- Production: BET_STUB_MODE forbidden, SOROBAN_FAIL_CLOSED=true, secrets required.
- Preflight fails fast with actionable errors.
- Startup logs active profile.
- Tests for preflight accept/reject matrix.
Acceptance criteria
Done when
Production money paths cannot silently run in demo-safe mode.
Metadata
| Field |
Value |
| Difficulty |
advanced |
| Complexity |
high |
| Good first contribution? |
no |
Summary
Create a production safety profile that forces fail-closed Soroban, required secrets, disabled stub bets, and refuses to boot if money-path invariants are violated.
Why this matters
Demo-friendly defaults are dangerous if accidentally used in production campaign deployments.
Where to work
src/config/+ preflightsrc/index.tsstartup.env.exampleWhat to implement
SAFETY_PROFILE=production|demo.Acceptance criteria
Done when
Production money paths cannot silently run in demo-safe mode.
Metadata