FeatureSignals

Configuration Reference

All configuration is done via environment variables.

API Server

VariableDefaultDescription
PORT8080HTTP server port
DATABASE_URLpostgres://fs:fsdev@localhost:5432/featuresignalsPostgreSQL connection string
JWT_SECRET(development default)JWT signing secret — must be changed in production
TOKEN_TTL_MINUTES60Access token lifetime
REFRESH_TTL_HOURS168Refresh token lifetime (7 days)
LOG_LEVELinfodebug, info, warn, error
CORS_ORIGINhttp://localhost:3000Comma-separated allowed CORS origins
DASHBOARD_URLhttp://localhost:3000Flag Engine public URL

Flag Engine

VariableDefaultDescription
NEXT_PUBLIC_API_URLhttp://localhost:8080API server URL (used by browser)

Caution: NEXT_PUBLIC_API_URL must be accessible from the user's browser. In production, use the public API URL.

Example

bash
export DATABASE_URL="postgres://fs:strongpass@db.example.com:5432/featuresignals?sslmode=require"
export JWT_SECRET="$(openssl rand -hex 32)"
export CORS_ORIGIN="https://app.example.com,https://docs.example.com"
export PORT=8080
export LOG_LEVEL=info

Next Steps