UPS Service
If your server is battery-backed, this service handles the graceful shutdown of your DCS servers and your PC in case of a power failure.
Configuration
The configuration file for this service has to be placed into config\services\ups.yaml:
# config/services/ups.yaml
DEFAULT:
device: nutdev1 # UPS device name
host: 192.168.178.123 # UPS host (the host running the NUT server)
port: 3493 # Optional: NUT port (default: 3493)
username: xxxx # Optional: the user credentials to log in to the NUT server.
password: xxxx # Optional: the user credentials to log in to the NUT server.
thresholds:
warn: 90 # warn users
shutdown: 50 # shutdown DCS
halt: 20 # shutdown PC
To configure the DCS server monitoring, you can change these values in your nodes.yaml and scheduler.yaml:
nodes.yaml
# config/nodes.yaml
MyNode:
DCS.dcs_serverrelease:
max_hung_minutes: 5 # maximum heartbeats a server can miss (default: 3)
plugins/scheduler.yaml
# config/plugins/scheduler.yaml
DCS.dcs_serverrelease:
schedule:
00-24: YYYYYYY # the server (and its DCS_server.exe process) should run 24x7
Configuration reference
| Key | Type | Description | Example |
|---|---|---|---|
DEFAULT |
map | Applies to every instance. | |
DEFAULT
| Key | Type | Description | Example |
|---|---|---|---|
DEFAULT.device |
str | Name of the UPS device on the NUT server. (range: min 1) | nutdev1 |
DEFAULT.host |
str | IP address of the host that runs the NUT server. | 192.168.178.123 |
DEFAULT.port |
int | Port of the NUT server. | 3493 |
DEFAULT.username |
str | User to log in to the NUT server (optional). (range: min 1) | upsuser |
DEFAULT.password |
str | Password to log in to the NUT server (optional). (range: min 1) | secret |
DEFAULT.thresholds |
map | Remaining battery percentage that triggers each action. | warn: 90 |
DEFAULT.thresholds.warn |
int | Battery level (%) that warns the players. (range: min 1, max 100) | 90 |
DEFAULT.thresholds.shutdown |
int | Battery level (%) that shuts down the DCS servers. (range: min 1, max 100) | 50 |
DEFAULT.thresholds.halt |
int | Battery level (%) that shuts down the whole PC. (range: min 1, max 100) | 20 |
<(.+)>
| Key | Type | Description | Example |
|---|---|---|---|
<(.+)> |
any | (one of: element_schema, instance_schema) | |