Configuration Reference
All configurable options via convars and environment variables.
Server Convars
Set in server.cfg:
Development
| Convar | Default | Description |
|---|---|---|
dev_mode | "false" | Enable development mode filtering |
dev_features | "" | Comma-separated module names to load (empty = all) |
set dev_mode "true"
set dev_features "init,characters,spawning"
Database
| Convar | Default | Description |
|---|---|---|
mongodb_uri | — | MongoDB connection string |
mongodb_database | "true_life" | Database name |
set mongodb_uri "mongodb://user:pass@localhost:27017"
set mongodb_database "true_life"
Telemetry
| Convar | Default | Description |
|---|---|---|
otel_enabled | "false" | Enable OpenTelemetry export |
otel_endpoint | "http://localhost:4318" | OTEL Collector endpoint |
otel_service_name | "true_life" | Service name for traces |
set otel_enabled "true"
set otel_endpoint "http://localhost:4318"
set otel_service_name "true_life"
Metrics
| Convar | Default | Description |
|---|---|---|
metrics_port | "9100" | Prometheus metrics HTTP port |
set metrics_port "9100"
Environment Variables
Set in .env or shell environment:
Docker Services
| Variable | Description |
|---|---|
MONGO_INITDB_ROOT_USERNAME | MongoDB root username |
MONGO_INITDB_ROOT_PASSWORD | MongoDB root password |
GRAFANA_ADMIN_USER | Grafana admin username |
GRAFANA_ADMIN_PASSWORD | Grafana admin password |
# .env
MONGO_INITDB_ROOT_USERNAME=admin
MONGO_INITDB_ROOT_PASSWORD=changeme
GRAFANA_ADMIN_USER=admin
GRAFANA_ADMIN_PASSWORD=admin
Service Ports
Default ports for all services:
| Service | Port | Description |
|---|---|---|
| MongoDB | 27017 | Database |
| UI Dev Server | 3000 | Vite HMR |
| Grafana | 3001 | Dashboards |
| Live Map | 3002 | Player map |
| Documentation | 3003 | Docusaurus |
| Prometheus | 9090 | Metrics queries |
| Metrics Endpoint | 9100 | FiveM metrics scrape |
| OTEL Collector | 4318 | OTLP HTTP receiver |
| Tempo | 3200 | Trace queries |
| Loki | 3100 | Log queries |
FiveM Resource Configuration
fxmanifest.lua
fx_version 'cerulean'
game 'gta5'
name 'true_life'
description 'True Life FiveM Framework'
version '1.0.0'
server_script 'dist/server.js'
client_script 'dist/client.js'
ui_page 'dist/ui/index.html'
files {
'dist/ui/**/*'
}
Complete server.cfg Example
# True Life Configuration
# Development
set dev_mode "false"
set dev_features ""
# Database
set mongodb_uri "mongodb://admin:password@localhost:27017"
set mongodb_database "true_life"
# Telemetry
set otel_enabled "true"
set otel_endpoint "http://localhost:4318"
set otel_service_name "true_life"
# Metrics
set metrics_port "9100"
# Start resource
ensure true_life