Daemon settings
Read the state of a node, and change the settings the panel does not cover.
The installer writes a settings file on every node, and most nodes never need it touched. Start with the node page in the panel, and come back here for the rest.
What the node page shows
Open Admin > Nodes and click a node.
Connection status gives the status, the daemon version, the uptime and when the node was last seen. A node that has fallen over shows its last error here.
System information gives the hostname, the operating system, the architecture and the kernel. A Linux node adds its container runtime and Docker version, and a Windows node says it runs games directly. Both add the public and private addresses, and Linux adds the load average.
Those details arrive when the daemon connects, so an offline node that has never checked in shows a note instead.
Daemon status repeats the version, the uptime and the platform. Daemon updates below it tells you when a newer daemon is out, and marks the update required when it is. Update from there rather than from the node itself.
Where the settings file lives
| System | Path |
|---|---|
| Linux | /etc/badger-daemon/config.yaml |
| Windows | C:\BadgerDaemon\config.yaml |
After any change, restart the daemon.
systemctl restart badger-daemonRestart-Service BadgerDaemonWhat you can change from the panel
Most settings live in the file alone. The panel changes two of them over its connection to the daemon, which writes them into the file itself.
- The storage drives of a Windows node, from the Storage Drives card.
- The command signing setting, from the Command Signing (HMAC) card.
The panel also changes /etc/docker/daemon.json and the kernel settings of a Linux node, from the Docker Daemon Configuration and Host Tuning cards. Those two files are not part of the daemon configuration.
For every other setting, edit the file on the node and restart the daemon.
The file the installer writes, on Linux
node:
uuid: ""
name: "us-east-1"
panel:
url: "https://panel.example.com"
api_key: ""
registration_token: "YOUR_TOKEN"
insecure_skip_tls: false
timeout: "30s"
servers:
data_dir: "/var/lib/badger-daemon/servers"
container_runtime: "docker"
heartbeat:
interval: "30s"
timeout_seconds: 60
sftp:
enabled: true
port: 2022
host_key: "/etc/badger-daemon/sftp_host_key"
logging:
level: "info"
format: "json"
file: "/var/log/badger-daemon/daemon.log"
update:
enabled: true
check_interval: "1h"
auto_restart: trueThe daemon replaces registration_token with an encrypted api_key at the first start.
Panel connection
| Option | Description | Default |
|---|---|---|
panel.url | Address of your panel. | Required |
panel.api_key | Key for this node. The daemon writes it and encrypts it. | - |
panel.registration_token | One-time token. The daemon uses it once and then writes an api_key. | - |
panel.timeout | Request timeout. | 30s |
panel.insecure_skip_tls | Skip the TLS check. | false |
panel.allowed_origins | Extra addresses that can connect to the daemon. | - |
The file needs panel.url, and either panel.api_key or panel.registration_token.
WARNING
insecure_skip_tls turns off the TLS certificate check. To use it, you must also set the environment variable BADGER_ALLOW_INSECURE_TLS=true. Never use it in production.
The API key gives full control of the node. Keep the file private. If the key leaks, click Regenerate Token in the panel and run the install command again.
Node identity
| Option | Description | Default |
|---|---|---|
node.uuid | Set by the panel at registration. Do not edit it. | - |
node.name | Name of the node. | The name that you gave in the panel |
Server storage
| Option | Description | Default |
|---|---|---|
servers.data_dir | Root directory for the game server files. | /var/lib/badger-daemon/servers |
servers.container_runtime | Container runtime. | docker |
The daemon puts the files of each server in a directory named after the UUID of that server:
/var/lib/badger-daemon/servers/
└── a1b2c3d4-e5f6-7890-abcd-ef1234567890/
├── server.jar
├── server.properties
└── world/Use SSD storage for the best performance.
Heartbeat
| Option | Description | Default |
|---|---|---|
heartbeat.interval | How often the daemon reports to the panel. | 30s |
heartbeat.timeout_seconds | Timeout of one heartbeat. | 60 |
The panel writes a metrics sample on each heartbeat. A shorter interval gives more detail in the monitoring charts and more load on the panel.
SFTP
| Option | Description | Default |
|---|---|---|
sftp.enabled | Turn the built-in SFTP server on or off. | true |
sftp.port | SFTP port. | 2022 |
sftp.host_key | Path of the SFTP host key. | Written by the installer |
Users sign in with their panel account. Each user reaches the files of their own servers only.
| Item | Value |
|---|---|
| Host | The IP address or domain name of the node |
| Port | 2022, or the port that you set |
| Username | The panel email address of the user |
| Password | The panel password of the user |
Logging
| Option | Description | Default |
|---|---|---|
logging.level | debug, info, warn, or error. | info |
logging.format | json or text. | json |
logging.file | Path of the log file. Leave it empty to write to the console only. | Written by the installer |
Use the
debuglevel for a short time only. It produces a large amount of output.
Updates
| Option | Description | Default |
|---|---|---|
update.enabled | Turn the update function on. The panel needs it to push an update. | true |
update.check_interval | How often the daemon looks for an update. | 1h |
update.auto_update | Install an update without a request from the panel. Linux only. | false |
update.auto_restart | Restart the daemon after an update. | true |
System user, on Linux
| Option | Description | Default |
|---|---|---|
system.user.uid | User ID that owns the game server files. | 1000 |
system.user.gid | Group ID that owns the game server files. | 1000 |
These values must match the user inside the game server images. If you build your own images, change these values to match them.
Local API, on Linux
| Option | Description | Default |
|---|---|---|
api.enabled | Turn on a local HTTP API on the node. | false |
api.port | Port of the local API. | 8080 |
api.cert_file | TLS certificate for the local API. | - |
api.key_file | TLS key for the local API. | - |
Backup storage, on Linux
Add a storage section to send the backups of this node to object storage.
| Option | Description | Default |
|---|---|---|
storage.type | local, minio, or s3. | local |
storage.local_path | Directory for local backups. | /var/lib/badger-daemon/backups |
storage.endpoint | Address of the object storage. | - |
storage.access_key | Access key. | - |
storage.secret_key | Secret key. | - |
storage.bucket | Bucket name. | - |
storage.region | Region name. | - |
storage.use_ssl | Use HTTPS for the object storage. | false |
storage.presigned_expiry | Life of a download link, in seconds. | 3600 |
Server migration, on Linux
The installer does not write this section. Add it to let the node send or receive a game server, and read Server migration.
| Option | Description | Default |
|---|---|---|
migration.enabled | Let this node take part in migrations. | false |
migration.listen_port | Port for node-to-node transfers. | 8444 |
migration.temp_dir | Working directory for a transfer. | /var/lib/badger-daemon/migration |
migration.identity_dir | Directory of the transfer keys. | /var/lib/badger-daemon/migration/identity |
migration.max_concurrent | Transfers at the same time, in and out together. | 2 |
migration.timeout_hours | Time limit of one transfer. | 4 |
migration.trash_retention_hours | How long a node keeps the files of a server that moved away. | 72 |
Windows settings
A Windows node uses the same node, panel, servers, heartbeat, sftp, logging, and update sections. These differences apply:
servers.container_runtimeis alwaysnative. The daemon ignores any other value.servers.data_dirisC:\BadgerDaemon\data\servers.update.auto_updatedoes not exist.- There is no
system,api,storage, ormigrationsection. servers.allowed_driveslists the disks that the daemon can use.
servers:
data_dir: "C:\\BadgerDaemon\\data\\servers"
container_runtime: "native"
allowed_drives:
- path: "C:\\BadgerDaemon\\data\\servers"
max_disk: 0
label: "Primary Drive"
- path: "D:\\GameServers"
max_disk: 500000
label: "Game SSD"max_disk is in MB. A value of 0 means no limit.
Change the drives from the Storage drives card in the panel rather than here, and the panel writes the file for you. Read Node storage.
Command line options
| Option | Description |
|---|---|
--config | Path of the configuration file. |
--log-level | Override the log level: debug, info, warn, or error. |
--version | Print the version and stop. |
--generate-config | Print a sample configuration file. |
The Windows daemon also has --install and --uninstall for the Windows service.
Next steps
- Linux nodes to install one
- Windows nodes to install one
- Node storage to give a node more disk
- Node monitoring to watch it live
