Skip to main content
This page provides a comprehensive reference for all environment variables that can be used to configure TeamSpeak 6 Server. Environment variables are particularly useful for containerized deployments and automated setups.

Overview

Environment variables provide an alternative to command-line flags for configuring the TeamSpeak 6 Server. They are especially useful in:
  • Docker and container deployments
  • Automated deployment scripts
  • CI/CD pipelines
  • Keeping sensitive data (like passwords) out of command histories
If both a command-line flag and an environment variable are set, the command-line flag takes precedence.

General Configuration

TSSERVER_LICENSE_ACCEPTED
string
Confirms you have read and accepted the server license agreement.Accepted values: 1, accept, trueCLI equivalent: --accept-license
TSSERVER_CONFIG_FILE
string
default:"tsserver.yaml"
Specifies the configuration file to load.CLI equivalent: --config-file
TSSERVER_LICENSE_PATH
string
default:"."
Directory path where the server will look for the licensekey.dat file.CLI equivalent: --license-path

Server Configuration

TSSERVER_DEFAULT_PORT
integer
default:"9987"
Permanently sets the default UDP voice port for the first virtual server created.Range: 1 - 65535CLI equivalent: --default-voice-port
TSSERVER_VOICE_IP
string
default:"0.0.0.0,::"
IP address(es) for the server to bind the voice port to. Multiple IPs can be separated by commas.CLI equivalent: --voice-ipExample:
TSSERVER_VOICE_IP="0.0.0.0,::,192.168.1.100"
TSSERVER_MACHINE_ID
string
A string to distinguish this instance from other instances using the same database.CLI equivalent: --machine-id
Useful in clustered or multi-instance deployments to identify which server instance is handling requests.
TSSERVER_VOICE_UDP_THREADS
integer
default:"5"
Number of threads to use for voice processing.Range: 1 - 16CLI equivalent: --threads-voice-udp
TSSERVER_NO_DEFAULT_SERVER
boolean
If set, no default server is created even if no server exists in the database.Accepted values: 1, trueCLI equivalent: --no-default-virtual-server

Logging

TSSERVER_LOG_PATH
string
default:"logs"
Path to the directory where log files are stored.CLI equivalent: --log-path
TSSERVER_APPEND_LOGS
boolean
Write one ever-growing log file per virtual server instead of creating new log files.Accepted values: 1, trueCLI equivalent: --log-append

File Transfer

TSSERVER_FILE_TRANSFER_PORT
integer
default:"30033"
The TCP port used for file transfers.Range: 1 - 65535CLI equivalent: --filetransfer-port
Docker Note: When running inside a Docker container, ensure that the internal container port matches the external host port. File transfers rely on clients connecting directly to this port.
TSSERVER_FILE_TRANSFER_IP
string
default:"0.0.0.0,::"
The address(es) on which to listen for file transfer connections.CLI equivalent: --filetransfer-ip

Database Configuration

TSSERVER_DATABASE_PLUGIN
string
default:"sqlite3"
Specifies the database plugin to use.Accepted values: sqlite3, mariadbCLI equivalent: --db-plugin
TSSERVER_DATABASE_SQL_PATH
string
default:"sql"
Path to folder containing SQL queries used by the server.CLI equivalent: --db-sql-path
TSSERVER_DATABASE_SQL_CREATE_PATH
string
default:"create_sqlite"
Subdirectory in SQL path to use for DB creation scripts.Examples: create_sqlite, create_mariadbCLI equivalent: --db-sql-create-path
TSSERVER_DATABASE_CLIENT_KEEP_DAYS
integer
default:"30"
Number of days to keep clients in the database before cleanup.CLI equivalent: --db-client-keep-days
TSSERVER_DATABASE_SKIP_INTEGRITY_CHECK
boolean
SQLite only: skip DB integrity check at startup.Accepted values: 1, trueCLI equivalent: --db-skip-integrity-check
TSSERVER_DATABASE_LOG_QUERIES
boolean
Enable logging of SQL queries.Accepted values: 1, trueCLI equivalent: --db-log-queries
TSSERVER_SKIP_PERMISSION_UPDATE
boolean
Do not apply permission changes during server updates.Accepted values: 1, trueCLI equivalent: --no-permission-update
TSSERVER_DATABASE_HOST
string
default:"127.0.0.1"
Database hostname or IP address.CLI equivalent: --db-host
TSSERVER_DATABASE_PORT
integer
default:"5432"
Database port.Range: 1 - 65535CLI equivalent: --db-port
Default port varies by database: MariaDB/MySQL (3306)
TSSERVER_DATABASE_SOCKET
string
Socket file to use for database connection (alternative to host/port).CLI equivalent: --db-socket
TSSERVER_DATABASE_TIMEOUT
integer
default:"10"
Timeout in seconds when connecting to the database.Range: 1 - 432000CLI equivalent: --db-timeout
TSSERVER_DATABASE_NAME
string
default:"teamspeak"
Name of the database to use.CLI equivalent: --db-name
TSSERVER_DATABASE_USERNAME
string
The username to use for database authentication.CLI equivalent: --db-username
TSSERVER_DATABASE_PASSWORD
string
The password to use for database authentication.CLI equivalent: --db-password
Using environment variables for passwords is more secure than command-line arguments, as they won’t appear in process lists.
TSSERVER_DATABASE_CONNECTIONS
integer
default:"10"
Number of connections to establish to the database.Range: 2 - 100CLI equivalent: --db-connections

Query Interface

TSSERVER_QUERY_POOL_SIZE
integer
default:"2"
How many threads to use for query command processing.Range: 2 - 32CLI equivalent: --query-pool-size
TSSERVER_QUERY_LOG_TIMING
integer
default:"3600"
Interval in seconds after which to log query statistics.Range: 10 - 31556952CLI equivalent: --query-log-timing
TSSERVER_QUERY_ALLOW_LIST
string
default:"query_ip_allowlist.txt"
File path listing IPs exempt from query flood protection.CLI equivalent: --query-ip-allow-list
TSSERVER_QUERY_DENY_LIST
string
default:"query_ip_denylist.txt"
File path listing IPs blocked from the query interface.CLI equivalent: --query-ip-block-list
TSSERVER_QUERY_ADMIN_PASSWORD
string
Override the query password for the built-in serveradmin account.CLI equivalent: --query-admin-password
This password should be kept secure. Consider using secrets management in production environments.
TSSERVER_QUERY_LOG_COMMANDS
boolean
Log every command received on the query interface.Accepted values: 1, trueCLI equivalent: --query-log-commands
TSSERVER_QUERY_SKIP_BRUTE_FORCE_CHECK
boolean
Skip brute force checking on query interface connections.Accepted values: 1, trueCLI equivalent: --query-skip-brute-force-check
TSSERVER_QUERY_BUFFER_MB
integer
default:"20"
How much memory (in MB) to allocate for query connection buffering.Range: 20 - 100CLI equivalent: --query-buffer-mb
TSSERVER_QUERY_DOCUMENTATION_PATH
string
default:"serverquerydocs"
Path to the query documentation files.CLI equivalent: --query-documentation-path
TSSERVER_QUERY_TIMEOUT
integer
default:"300"
Timeout in seconds before query connections expire due to inactivity.CLI equivalent: --query-timeout
TSSERVER_QUERY_SSH_ENABLED
boolean
Enable the SSH query interface.Accepted values: 1, trueCLI equivalent: --query-ssh-enable
TSSERVER_QUERY_SSH_PORT
integer
default:"10022"
Port on which to listen for SSH query connections.Range: 1 - 65535CLI equivalent: --query-ssh-port
TSSERVER_QUERY_SSH_IP
string
default:"0.0.0.0,::"
Address(es) to listen on for SSH query connections.CLI equivalent: --query-ssh-ip
TSSERVER_QUERY_SSH_RSA_KEY
string
default:"ssh_host_rsa_key"
Path to the SSH RSA host key file.CLI equivalent: --query-ssh-rsa-key
TSSERVER_QUERY_HTTP_ENABLED
boolean
Enable the HTTP query interface.Accepted values: 1, trueCLI equivalent: --query-http-enable
TSSERVER_QUERY_HTTP_PORT
integer
default:"10080"
Port on which to listen for Web Query connections.Range: 1 - 65535CLI equivalent: --query-http-port
TSSERVER_QUERY_HTTP_IP
string
default:"0.0.0.0,::"
Address(es) to listen on for Web Query connections.CLI equivalent: --query-http-ip
TSSERVER_QUERY_HTTPS_ENABLED
boolean
Enable the HTTPS query interface.Accepted values: 1, trueCLI equivalent: --query-https-enable
TSSERVER_QUERY_HTTPS_PORT
integer
default:"10443"
Port on which to listen for secure Web Query connections.Range: 1 - 65535CLI equivalent: --query-https-port
TSSERVER_QUERY_HTTPS_IP
string
default:"0.0.0.0,::"
Address(es) to listen on for secure Web Query connections.CLI equivalent: --query-https-ip
TSSERVER_QUERY_HTTPS_CERT
string
Path to certificate file for HTTPS Web Query.CLI equivalent: --query-https-certificate
TSSERVER_QUERY_HTTPS_PRIVATE_KEY
string
Path to private key file used with the certificate.CLI equivalent: --query-https-private-key

Advanced Configuration

TSSERVER_HTTP_PROXY
string
Proxy server used for external connections.CLI equivalent: --http-proxyExample:
TSSERVER_HTTP_PROXY="http://proxy.example.com:8080"
TSSERVER_CRASHDUMP_PATH
string
default:"crashdumps"
Path where crash dumps should be written.CLI equivalent: --crashdump-path
TSSERVER_DAEMON
boolean
Run the server in the background (daemon mode).Accepted values: 1, trueCLI equivalent: --daemon
TSSERVER_PID_FILE
string
File to write the process ID to when running in daemon mode.CLI equivalent: --pid-file
TSSERVER_HINTS_ENABLED
boolean
Enable permission hints.Accepted values: 1, trueCLI equivalent: --hints-enabled
Permission hints can impact performance on large servers with complex permission structures.
TSSERVER_MAXMIND_DB_PATH
string
Path to the MaxMind GeoIP database.CLI equivalent: --maxmind-db-path
TSSERVER_ADMINISTRATIVE_DOMAIN
string
Administrative domain for internal or regulatory identification.CLI equivalent: --administrative-domain

Docker Example

Here’s a complete example of using environment variables in a Docker deployment:
version: '3.8'

services:
  teamspeak:
    image: teamspeak:latest
    container_name: teamspeak-server
    ports:
      - "9987:9987/udp"  # Voice
      - "30033:30033/tcp" # File Transfer
      - "10022:10022/tcp" # SSH Query
      - "10080:10080/tcp" # HTTP Query
    environment:
      - TSSERVER_LICENSE_ACCEPTED=accept
      - TSSERVER_DEFAULT_PORT=9987
      - TSSERVER_FILE_TRANSFER_PORT=30033
      - TSSERVER_DATABASE_PLUGIN=mariadb
      - TSSERVER_DATABASE_HOST=db
      - TSSERVER_DATABASE_PORT=3306
      - TSSERVER_DATABASE_NAME=teamspeak
      - TSSERVER_DATABASE_USERNAME=tsserver
      - TSSERVER_DATABASE_PASSWORD=secure_password
      - TSSERVER_QUERY_SSH_ENABLED=1
      - TSSERVER_QUERY_SSH_PORT=10022
      - TSSERVER_QUERY_HTTP_ENABLED=1
      - TSSERVER_QUERY_HTTP_PORT=10080
    volumes:
      - ./data:/var/ts6server
    depends_on:
      - db

  db:
    image: mariadb:latest
    environment:
      - MYSQL_ROOT_PASSWORD=root_password
      - MYSQL_DATABASE=teamspeak
      - MYSQL_USER=tsserver
      - MYSQL_PASSWORD=secure_password
    volumes:
      - ./db-data:/var/lib/mysql

See Also

CLI Options

Complete list of command-line options

YAML Configuration

YAML configuration file schema

Build docs developers (and LLMs) love