Configuration Reference
All NetRecon services are configured through a single .env file located at /opt/netrecon/.env. This page documents every available environment variable.
Core Settings
| Variable | Required | Default | Description |
|---|---|---|---|
NETRECON_DOMAIN | Yes | — | Your domain name (e.g., netrecon.yourcompany.com) |
NETRECON_EMAIL | Yes | — | Admin email for Let's Encrypt and notifications |
Database (PostgreSQL)
| Variable | Required | Default | Description |
|---|---|---|---|
POSTGRES_USER | Yes | — | PostgreSQL username |
POSTGRES_PASSWORD | Yes | — | PostgreSQL password |
POSTGRES_DB | Yes | netrecon | Database name |
DATABASE_URL | Auto | — | Constructed automatically from the above values |
порада
Use a strong, randomly generated password. Generate one with:
openssl rand -base64 24
Cache (Redis)
| Variable | Required | Default | Description |
|---|---|---|---|
REDIS_PASSWORD | Yes | — | Redis authentication password |
REDIS_URL | Auto | — | Constructed automatically |
Authentication
| Variable | Required | Default | Description |
|---|---|---|---|
JWT_SECRET | Yes | — | Secret key for signing JWT tokens (min 32 chars) |
JWT_EXPIRE_MINUTES | No | 1440 | Token expiration time (default: 24 hours) |
Generate a secure JWT secret:
openssl rand -hex 32
Agent Registry
| Variable | Required | Default | Description |
|---|---|---|---|
AGENT_REGISTRY_SECRET | Yes | — | Secret for agent enrollment |
AGENT_JWT_SECRET | Yes | — | JWT secret for agent authentication |
AGENT_TOKEN_EXPIRE_MINUTES | No | 1440 | Agent token expiration |
AGENT_HEARTBEAT_INTERVAL | No | 30 | Heartbeat interval in seconds |
AGENT_HEARTBEAT_TIMEOUT | No | 90 | Seconds before marking agent offline |