Environment Variables
Configure Astervis via environment variables
All configuration is stored in /opt/astervis/.env. Changes require service restart.
Database Settings
| Variable | Default | Description |
|---|---|---|
POSTGRES_USER | astervis | PostgreSQL username |
POSTGRES_PASSWORD | [generated] | PostgreSQL password |
POSTGRES_HOST | timescaledb | Database hostname |
POSTGRES_PORT | 5432 | Database port |
POSTGRES_DB | astervis | Database name |
Don't change database credentials after installation unless you also update the database users.
Redis Settings
| Variable | Default | Description |
|---|---|---|
REDIS_HOST | redis | Redis hostname |
REDIS_PORT | 6379 | Redis port |
Server Settings
| Variable | Default | Description |
|---|---|---|
SERVER_IP | [your IP/domain] | Server address for SSL and URLs |
BACKEND_PORT | 5555 | Backend API port |
PORT | 6464 | Frontend port |
Authentication
| Variable | Default | Description |
|---|---|---|
BETTER_AUTH_SECRET | [generated] | Session encryption key (32 chars) |
BETTER_AUTH_URL | https://[SERVER_IP]:8443 | Public URL for auth |
SESSION_EXPIRES_IN | 86400 | Session timeout (seconds) |
REFRESH_TOKEN_EXPIRES_IN | 432000 | Refresh token timeout (seconds) |
MySQL (PBX) Settings
| Variable | Default | Description |
|---|---|---|
MYSQL_HOST | host.docker.internal | PBX MySQL host |
MYSQL_PORT | 3306 | MySQL port |
MYSQL_USER | [auto-detected] | MySQL username |
MYSQL_PASSWORD | [auto-detected] | MySQL password |
MYSQL_DB | asteriskcdrdb | CDR database name |
MYSQL_USERS_DB | asterisk | Asterisk users database |
MYSQL_TIMEZONE | [server timezone] | PBX server timezone |
See MySQL Configuration for details.
Timezone
| Variable | Default | Description |
|---|---|---|
TIMEZONE | Asia/Tashkent | Application timezone |
NEXT_PUBLIC_TIMEZONE | Asia/Tashkent | Frontend display timezone |
MYSQL_TIMEZONE | Asia/Tashkent | PBX server timezone |
See Timezone Configuration for details.
License
| Variable | Description |
|---|---|
LICENSE_KEY | Your Astervis license key |
COMPANY_NAME | Company name (from license) |
Agent Communication
| Variable | Default | Description |
|---|---|---|
ASTERVIS_AGENT_API_KEY | [generated] | API key for agent |
ASTERVIS_AGENT_API_URL | http://host.docker.internal:9876 | Agent URL |
Performance Tuning
| Variable | Default | Description |
|---|---|---|
HTTP_TIMEOUT | 30000 | HTTP request timeout (ms) |
HTTP_MAX_RETRIES | 3 | Max HTTP retries |
NODE_OPTIONS | --max-old-space-size=3072 | Node.js heap size |