Skip to main content
Installation

Configuration reference

Every key in .env: required keys, login and accounts, Elasticsearch connection, model and reasoning, live alerts, scheduled reports and baseline, audit and retention, resource limits.

All configuration lives in .env in the installation directory and is read by docker compose at start. After editing .env, run docker compose -f docker-compose.prod.yml up -d to recreate the gateway container.

Keys that can be changed on the Settings and AI settings pages (Elasticsearch connection, whitelist, masking, audit, providers) are stored on the gateway state volume and take precedence over .env. For those keys, .env only seeds the first start.

Required

KeyDescription
ES_URLElasticsearch URL, for example https://es.corp.local:9200; comma-separated for multiple nodes
ES_USER, ES_PASSWORDElasticsearch account; leave empty when security is disabled. ES_API_KEY can be used instead
LLM_API_KEY, LLM_BASE_URL, LLM_MODELThe first LLM provider
CADDY_SITE_ADDRESSHostname analysts open; space-separated for several
RST_GATEWAY_SHARED_SECRETShared secret between Caddy and the gateway; generated by deploy.sh
RST_ADMIN_TOKENOperations API token (X-RST-Admin-Token header); generated
RST_ADMIN_PASSWORD_HASHHash of the first administrator's password; generated. When unset, the gateway refuses every non-local login
GATEWAY_IMAGE_TAGImage tag in use; written by deploy.sh, changed by rst-update.sh during online update

Login and accounts

KeyDefaultDescription
RST_ADMIN_USERNAMEadminFirst administrator account name
RST_SESSION_TTL_HOURS12Session lifetime
RST_USER_DB_URLWritten by deploy.shPostgres holding the multi-user account table; empty means single account
RST_USER_DB_PASSWORDGeneratedPassword of the bundled userdb container
RST_ALLOW_DEFAULT_PASSWORDEmptySet to 1 to allow LAN logins with the factory password; isolated test environments only
RST_CORS_ORIGINSEmptyCross-origin sources. The gateway serves its own front end; not needed in a standard installation

Elasticsearch

KeyDefaultDescription
RST_ES_VERIFY_CERTStrueVerify the Elasticsearch server certificate. Set to false or configure a CA for self-signed certificates
ES_API_KEYEmptyElasticsearch API key (the encoded value from the response). Takes precedence over ES_USER / ES_PASSWORD; Kibana calls also use it when no Kibana credentials are set. .env only; see Use an API key
RST_ES_CA_CERTEmptyIn-container path of a private CA, for example /certs/es-ca.pem; place the file under ./certs/ in the installation directory
RST_KIBANA_CA_CERTEmptySet when the Kibana certificate is issued by a different private CA, for example /certs/kibana-ca.pem. Empty reuses RST_ES_CA_CERT. The CA is trusted in addition to the public CAs, not instead of them
RST_ES_TIMEOUT_S30Per-request Elasticsearch timeout, seconds
RST_ES_MAX_RETRIES2Transparent retries on timeout or connection error
RST_INDEX_WHITELISTEmptyQueryable index patterns, for example logs-*,filebeat-*,winlogbeat-*. Recommended
KIBANA_URLEmptyKibana URL for deep links only; empty disables them
KIBANA_PUBLIC_URLEmptyKibana URL reachable from analyst browsers, when it differs from the one the gateway sees
RST_ELK_VERSION9.5.3 written on a new installImage version of the bundled Elasticsearch and Kibana only. Empty means 8.12.2. Do not change only this value on a host with bundled ES data; see Bundled Elasticsearch and Kibana
RST_CONVERSATION_BACKENDesMulti-turn conversation store. es writes .rst_copilot_conversations, survives restarts and is shared across replicas; memory is in-process only
RST_CONVERSATION_TTL_DAYS7Idle expiry of conversations, days
RST_DSL_CACHE_TTL_S600Cache of generated queries for identical questions, seconds; 0 disables
RST_FIELD_DICT_CACHE_TTL_S300Field-dictionary scan cache, seconds

Model and reasoning

KeyDefaultDescription
LLM_TIMEOUT_S180Per-call model timeout, seconds. Raise if investigation or triage times out
LLM_REASONINGautoReasoning effort for this provider: auto, off, low, high; see AI settings
RST_NL2DSL_REASONINGlowReasoning effort for the query-generation step of Ask AI: none, low, high, native
RST_LLM_FIRST_TOKEN_TIMEOUT_S45Hard limit for the first token during query generation, seconds; 0 disables
RST_EMBED_MODEL, RST_EMBED_BASE_URL, RST_EMBED_DIMEmptyEmbedding model for the knowledge base. Configure it on the AI settings page
RST_EMBED_COOLDOWN_S60Cool-down after an embedding endpoint failure, seconds
RST_MASKING_MODEPer licenceForce the masking mode: cloud, private, airgapped
RST_TIMEZONEUTCTimezone the model uses to resolve "today" and "yesterday"
RST_OUTPUT_LANGzhOutput language for background work with no user request: zh or en. Applies to alert-ingest summaries, scheduled reports, and notification delivery text. Requests follow the interface language
RST_RATELIMIT_GENERATE, RST_RATELIMIT_EXECUTE, RST_RATELIMIT_KIBANA_LINK30, 30, 120Per-IP rate limits per minute. Raise when a team shares one egress IP

Alerts

KeyDefaultDescription
RST_ALERT_INGEST_INDEXEmptyAlert index to poll, as a read alias such as .alerts-security.alerts-default. Empty disables polling
RST_ALERT_INGEST_INTERVAL_SECONDS10Poll interval, seconds
RST_ALERT_INGEST_LOOKBACK1hHow far back the first pull reaches, for example 7d. Set it when the index already holds alert history
RST_ALERT_WEBHOOK_SECRETEmptyShared secret for Kibana webhook push (X-RST-Alert-Token); push is enabled when set
RST_ALERT_INGEST_CONCURRENCY, RST_ALERT_INGEST_BUDGET_S4, 20One push carries up to 200 alerts, each costing one summary call; these bound concurrency and the total time budget

Scheduled reports and baseline

KeyDefaultDescription
RST_REPORT_SCHEDULEEmptyAny of daily,weekly,monthly; empty disables automatic reports
RST_REPORT_TZSame as RST_TIMEZONETimezone of report period boundaries
RST_REPORT_WEBHOOK_URL, RST_REPORT_WEBHOOK_HEADERSEmptyTarget each report is POSTed to
RST_REPORT_PERSIST, RST_REPORT_INDEX1, .rst_copilot_reportsArchive to Elasticsearch
RST_REPORT_CATCHUP_MAX7Maximum periods back-filled after downtime
RST_BASELINE_INTERVAL_SECONDSEmptyBaseline poll interval, seconds; effective at 300 or more. Empty means manual runs only
RST_BASELINE_MAX_AGE_HOURS48osquery data older than this is judged stale
RST_BASELINE_HOST_ROSTER_DAYS30Hosts silent for longer are no longer enumerated
RST_BASELINE_OSQUERY_INDEXlogs-osquery_manager.result-*Customer osquery result index the gateway reads
RST_BASELINE_RESULTS_INDEX, RST_BASELINE_RULES_INDEX, RST_BASELINE_RUNS_INDEXbaseline-results, baseline-rules, baseline-runsThe three indices the gateway writes

Audit and retention

KeyDefaultDescription
RST_AUDIT_ENABLEDtrueAudit events are written to .rst_copilot_audit
RST_AUDIT_WEBHOOK_ALLOWLISTEmptyHosts allowed as audit-forwarding webhook targets; empty refuses only loopback and link-local addresses
RST_ILM_BOOTSTRAP0Set to 1 to create the ILM policy and index template at start. Recommended when audit is enabled
RST_AUDIT_RETENTION_DAYS180Audit index retention, days; effective with ILM enabled
RST_METRICS_TOKENEmptyScrape token for /metrics

Resources

KeyDefaultDescription
RST_GATEWAY_CPUS, RST_GATEWAY_MEM2, 2gGateway container limits

SSO keys are listed under SSO.

On this page