Skip to content

Configuration

Environment variables and configuration options for Ops Atlas.

Environment Variables

Required

VariableDescriptionExample
DATABASE_URLPostgreSQL connection stringpostgres://user:pass@host:5432/db
JWT_SECRETSecret for JWT tokens (min 64 chars)Random string

Optional

VariableDefaultDescription
PORT3000HTTP server port
REDIS_URLredis://localhost:6379Redis connection
LOG_LEVELinfoLogging level (debug, info, warn, error)
CORS_ORIGINS*Allowed CORS origins

Authentication

VariableDefaultDescription
AUTH_PROVIDERlocalAuth provider (local, ldap, oauth)
LDAP_URL-LDAP server URL
OAUTH_CLIENT_ID-OAuth client ID
OAUTH_CLIENT_SECRET-OAuth client secret

Integrations

VariableDefaultDescription
SLACK_WEBHOOK_URL-Slack incoming webhook
DISCORD_WEBHOOK_URL-Discord webhook
SMTP_HOST-Email SMTP server
SMTP_PORT587SMTP port

Configuration File

You can also use a config.yaml file:

yaml
server:
  port: 3000
  host: 0.0.0.0

database:
  url: postgres://localhost:5432/opsatlas
  pool_size: 10

redis:
  url: redis://localhost:6379

auth:
  jwt_secret: your-secret-here
  session_timeout: 24h

logging:
  level: info
  format: json

integrations:
  slack:
    webhook_url: https://hooks.slack.com/...
  discord:
    webhook_url: https://discord.com/api/webhooks/...

Security Best Practices

WARNING

Never commit secrets to version control!

  1. Use environment variables for secrets
  2. Rotate JWT secrets periodically
  3. Use strong, random passwords
  4. Enable HTTPS in production
  5. Restrict CORS origins in production

Released under the MIT License.