diff --git a/Dockerfile b/Dockerfile index 29bd4d7..90835e8 100644 --- a/Dockerfile +++ b/Dockerfile @@ -101,9 +101,9 @@ ENV TZ="UTC" \ DISCORD_PRE_START_MESSAGE="Server has been started!" \ DISCORD_PRE_START_MESSAGE_ENABLED=true \ DISCORD_PRE_START_MESSAGE_URL="" \ - DISCORD_SERVER_INFO_MESSAGE_ENABLED=true \ - DISCORD_SERVER_INFO_MESSAGE_WITH_IP=false \ - DISCORD_SERVER_INFO_MESSAGE_WITH_DOMAIN="" \ + DISCORD_PRE_START_MESSAGE_WITH_GAME_SETTINGS=true \ + DISCORD_PRE_START_MESSAGE_WITH_SERVER_IP=false \ + DISCORD_PRE_START_MESSAGE_WITH_DOMAIN="" \ DISCORD_PRE_SHUTDOWN_MESSAGE="Server is shutting down..." \ DISCORD_PRE_SHUTDOWN_MESSAGE_ENABLED=true \ DISCORD_PRE_SHUTDOWN_MESSAGE_URL="" \ diff --git a/docs/en/README.md b/docs/en/README.md index f9527e8..ff04bbc 100644 --- a/docs/en/README.md +++ b/docs/en/README.md @@ -235,86 +235,87 @@ or by changing the permissions for all other: `chmod o=rwx data/` You can use the following values to change the settings of the server on boot. It is highly recommended you set the following environment values before starting the server: -| Variable | Info | Default Value | Allowed Values | Added in Version | -|---------------------------------------------|--------------------------------------------------------------------------------------------------------------------------------------------------|----------------------------------------------------------------------------------------------------|-------------------------------------------------------------------------------------------------------------------|------------------| -| TZ | Timezone used for Cron and Game server. (Not applicable to Log) | UTC | See [TZ Identifiers](https://en.wikipedia.org/wiki/List_of_tz_database_time_zones#Time_Zone_abbreviations) | 0.1.0 | -| PUID\* | The uid of the user the server should run as. | 1000 | !0 | 0.1.0 | -| PGID\* | The gid of the user the server should run as. | 1000 | !0 | 0.1.0 | -| PORT\* | Game port that the server will expose. | 7777 | 1024-65535 | 0.1.0 | -| QUERY_PORT | Query port used to communicate with Steam servers. | 27016 | 1024-65535 | 0.1.0 | -| UPDATE_ON_BOOT\*\* | Update the server when the docker container starts. | true | true/false | 0.1.0 | -| BACKUP_ENABLED | Enables automatic backups. | true | true/false | 0.1.1 | -| BACKUP_CRON_EXPRESSION | Setting affects frequency of automatic backups. | 0 0 \* \* \* | Needs a Cron-Expression - See [Configuring Automatic Backups with Cron](#configuring-automatic-backups-with-cron) | 0.1.1 | -| DELETE_OLD_BACKUPS | Delete backups after a certain number of days. | false | true/false | 0.1.1 | -| OLD_BACKUP_DAYS | How many days to keep backups. | 30 | any positive integer | 0.1.1 | -| AUTO_UPDATE_ENABLED | Enables automatic updates. | false | true/false | 0.1.4 | -| AUTO_UPDATE_CRON_EXPRESSION | Setting affects frequency of automatic updates. | 0 \* \* \* \* | Needs a Cron-Expression - See [Configuring Automatic Updates with Cron](#configuring-automatic-updates-with-cron) | 0.1.4 | -| AUTO_UPDATE_WARN_MINUTES | How long to wait to saved and update the server, after the player were informed. (This will be ignored, if no Players are connected) | 15 | !0 | 0.1.4 | -| AUTO_UPDATE_WARN_MESSAGE | Messages to broadcast on countdown for automatic updates. | Server will update in `remaining_time` minutes. | "string" | 0.1.10 | -| AUTO_UPDATE_WARN_REMAINING_TIMES | Informing when the remaining time during countdown is included. | 1 5 10 | !0 and " "(Space) | 0.1.10 | -| AUTO_REBOOT_ENABLED | Enables automatic reboots. | false | true/false | 0.1.10 | -| AUTO_REBOOT_CRON_EXPRESSION | Setting affects frequency of automatic reboots. | 0 0 \* \* \* | Needs a Cron-Expression - See [Configuring Automatic Reboots with Cron](#configuring-automatic-reboots-with-cron) | 0.1.10 | -| AUTO_REBOOT_WARN_MINUTES | How long to wait to saved and reboot the server, after the player were informed. (This will be ignored, if no Players are connected) | 15 | !0 | 0.1.10 | -| AUTO_REBOOT_WARN_MESSAGE | Messages to broadcast on countdown for automatic reboots. | Server will reboot in `remaining_time` minutes. | "string" | 0.1.10 | -| AUTO_REBOOT_WARN_REMAINING_TIMES | Informing when the remaining time during countdown is included. | 1 5 10 | !0 and " "(Space) | 0.1.10 | -| AUTO_REBOOT_EVEN_IF_PLAYERS_ONLINE | Reboot the Server even if there are players online. | false | true/false | 0.1.10 | -| BROADCAST_COUNTDOWN_SUSPEND_MESSAGE | Discord message when countdown suspended due to no players. | Suspends countdown because there are no players. | "string" | 0.1.10 | -| BROADCAST_COUNTDOWN_SUSPEND_MESSAGE_ENABLED | If the Discord message is enabled for this message. | true | true/false | 0.1.2 | -| TARGET_COMMIT_ID | Install and run the game server at the specified version. | _(empty)_ | See [Locking Specific Game Version](#locking-specific-game-version)(#target-commit-id) | 0.1.3 | -| DISCORD_WEBHOOK_URL | Discord webhook url found after creating a webhook on a discord server. | _(empty)_ | `https://discord.com/api/webhooks/` | 0.1.0 | -| DISCORD_SUPPRESS_NOTIFICATIONS | Enables/Disables `@silent` messages for the server messages. | false | true/false | 0.1.0 | -| DISCORD_CONNECT_TIMEOUT | Discord command initial connection timeout. | 30 | !0 | 0.1.0 | -| DISCORD_MAX_TIMEOUT | Discord total hook timeout. | 30 | !0 | 0.1.0 | -| DISCORD_PRE_INSTALL_MESSAGE | Discord message sent when server begins installing. | Server is installing... | "string" | 0.1.0 | -| DISCORD_PRE_INSTALL_MESSAGE_ENABLED | If the Discord message is enabled for this message. | true | true/false | 0.1.0 | -| DISCORD_PRE_INSTALL_MESSAGE_URL | Discord Webhook URL for this message. (if left empty will use DISCORD_WEBHOOK_URL) | _(empty)_ | `https://discord.com/api/webhooks/` | 0.1.0 | -| DISCORD_POST_INSTALL_MESSAGE | Discord message sent when server completes installing. | Server install complete! | "string" | 0.1.2 | -| DISCORD_POST_INSTALL_MESSAGE_ENABLED | If the Discord message is enabled for this message. | true | true/false | 0.1.2 | -| DISCORD_POST_INSTALL_MESSAGE_URL | Discord Webhook URL for this message. (if left empty will use DISCORD_WEBHOOK_URL) | _(empty)_ | `https://discord.com/api/webhooks/` | 0.1.2 | -| DISCORD_PRE_UPDATE_BOOT_MESSAGE | Discord message sent when server begins updating. | Server is updating... | "string" | 0.1.0 | -| DISCORD_PRE_UPDATE_BOOT_MESSAGE_ENABLED | If the Discord message is enabled for this message. | true | true/false | 0.1.0 | -| DISCORD_PRE_UPDATE_BOOT_MESSAGE_URL | Discord Webhook URL for this message. (if left empty will use DISCORD_WEBHOOK_URL) | _(empty)_ | `https://discord.com/api/webhooks/` | 0.1.0 | -| DISCORD_POST_UPDATE_BOOT_MESSAGE | Discord message sent when server completes updating. | Server update complete! | "string" | 0.1.2 | -| DISCORD_POST_UPDATE_BOOT_MESSAGE_ENABLED | If the Discord message is enabled for this message. | true | true/false | 0.1.2 | -| DISCORD_POST_UPDATE_BOOT_MESSAGE_URL | Discord Webhook URL for this message. (if left empty will use DISCORD_WEBHOOK_URL) | _(empty)_ | `https://discord.com/api/webhooks/` | 0.1.2 | -| DISCORD_PRE_START_MESSAGE | Discord message sent when server begins to start. | Server has been started! | "string" | 0.1.0 | -| DISCORD_PRE_START_MESSAGE_ENABLED | If the Discord message is enabled for this message. | true | true/false | 0.1.0 | -| DISCORD_PRE_START_MESSAGE_URL | Discord Webhook URL for this message. (if left empty will use DISCORD_WEBHOOK_URL) | _(empty)_ | `https://discord.com/api/webhooks/` | 0.1.0 | -| DISCORD_SERVER_INFO_MESSAGE_ENABLED | Send the server settings with DISCORD_PRE_START_MESSAGE. | true | true/false | 0.1.1 | -| DISCORD_SERVER_INFO_MESSAGE_WITH_IP | Send the server IP and Port with server info. | false | true/false | 0.1.0 | -| DISCORD_PRE_SHUTDOWN_MESSAGE | Discord message sent when server begins to shutdown. | Server is shutting down... | "string" | 0.1.0 | -| DISCORD_PRE_SHUTDOWN_MESSAGE_ENABLED | If the Discord message is enabled for this message. | true | true/false | 0.1.0 | -| DISCORD_PRE_SHUTDOWN_MESSAGE_URL | Discord Webhook URL for this message. (if left empty will use DISCORD_WEBHOOK_URL) | _(empty)_ | `https://discord.com/api/webhooks/` | 0.1.0 | -| DISCORD_POST_SHUTDOWN_MESSAGE | Discord message sent when server begins to shutdown. | Server is stopped! | "string" | 0.1.0 | -| DISCORD_POST_SHUTDOWN_MESSAGE_ENABLED | If the Discord message is enabled for this message. | true | true/false | 0.1.0 | -| DISCORD_POST_SHUTDOWN_MESSAGE_URL | Discord Webhook URL for this message. (if left empty will use DISCORD_WEBHOOK_URL) | _(empty)_ | `https://discord.com/api/webhooks/` | 0.1.0 | -| DISCORD_PLAYER_JOIN_MESSAGE | Discord message sent when player joins the server. | `player_name` has joined! | "string" | 0.1.9 | -| DISCORD_PLAYER_JOIN_MESSAGE_ENABLED | If the Discord message is enabled for this message. | true | true/false | 0.1.9 | -| DISCORD_PLAYER_JOIN_MESSAGE_URL | Discord Webhook URL for this message. (if left empty will use DISCORD_WEBHOOK_URL) | _(empty)_ | `https://discord.com/api/webhooks/` | 0.1.9 | -| DISCORD_PLAYER_LEAVE_MESSAGE | Discord message sent when player leaves the server. | `player_name` has left. | "string" | 0.1.9 | -| DISCORD_PLAYER_LEAVE_MESSAGE_ENABLED | If the Discord message is enabled for this message. | true | true/false | 0.1.9 | -| DISCORD_PLAYER_LEAVE_MESSAGE_URL | Discord Webhook URL for this message. (if left empty will use DISCORD_WEBHOOK_URL) | _(empty)_ | `https://discord.com/api/webhooks/` | 0.1.9 | -| DISCORD_PRE_BACKUP_MESSAGE | Discord message when starting to create a backup. | Creating backup... | "string" | 0.1.1 | -| DISCORD_PRE_BACKUP_MESSAGE_ENABLED | If the Discord message is enabled for this message. | true | true/false | 0.1.1 | -| DISCORD_PRE_BACKUP_MESSAGE_URL | Discord Webhook URL for this message. (if left empty will use DISCORD_WEBHOOK_URL) | _(empty)_ | `https://discord.com/api/webhooks/` | 0.1.1 | -| DISCORD_POST_BACKUP_MESSAGE | Discord message when a backup has been made. | Backup created at `file_path` | "string" | 0.1.1 | -| DISCORD_POST_BACKUP_MESSAGE_ENABLED | If the Discord message is enabled for this message. | true | true/false | 0.1.1 | -| DISCORD_POST_BACKUP_MESSAGE_URL | Discord Webhook URL for this message. (if left empty will use DISCORD_WEBHOOK_URL) | _(empty)_ | `https://discord.com/api/webhooks/` | 0.1.1 | -| DISCORD_PRE_BACKUP_DELETE_MESSAGE | Discord message when starting to remove older backups. | Removing backups older than `old_backup_days` days | "string" | 0.1.1 | -| DISCORD_PRE_BACKUP_DELETE_MESSAGE_ENABLED | If the Discord message is enabled for this message. | true | true/false | 0.1.1 | -| DISCORD_PRE_BACKUP_DELETE_MESSAGE_URL | Discord Webhook URL for this message. (if left empty will use DISCORD_WEBHOOK_URL) | _(empty)_ | `https://discord.com/api/webhooks/` | 0.1.1 | -| DISCORD_POST_BACKUP_DELETE_MESSAGE | Discord message when successfully removed older backups. | Removed backups older than `old_backup_days` days | "string" | 0.1.1 | -| DISCORD_POST_BACKUP_DELETE_MESSAGE_ENABLED | If the Discord message is enabled for this message. | true | true/false | 0.1.1 | -| DISCORD_POST_BACKUP_DELETE_MESSAGE_URL | Discord Webhook URL for this message. (if left empty will use DISCORD_WEBHOOK_URL) | _(empty)_ | `https://discord.com/api/webhooks/` | 0.1.1 | -| DISCORD_ERR_BACKUP_DELETE_MESSAGE | Discord message when there has been an error removing older backups. | Unable to delete old backups, OLD_BACKUP_DAYS is not an integer. OLD_BACKUP_DAYS=`old_backup_days` | "string" | 0.1.1 | -| DISCORD_ERR_BACKUP_DELETE_MESSAGE_ENABLED | If the Discord message is enabled for this message. | true | true/false | 0.1.1 | -| DISCORD_ERR_BACKUP_DELETE_MESSAGE_URL | Discord Webhook URL for this message. (if left empty will use DISCORD_WEBHOOK_URL) | _(empty)_ | `https://discord.com/api/webhooks/` | 0.1.1 | -| DISCORD_BROADCAST_MESSAGE_ENABLE\*\* | If the Discord message is enabled for broadcast content. | true | true/false | 0.1.6 | -| DISCORD_BROADCAST_MESSAGE_URL\* | Discord Webhook URL for this message. (if left empty will use DISCORD_WEBHOOK_URL) | _(empty)_ | `https://discord.com/api/webhooks/` | 0.1.6 | -| DISABLE_GENERATE_SETTINGS | Whether to automatically generate the Game.ini | false | true/false | 0.1.1 | -| ENABLE_PLAYER_LOGGING | Enables Logging and announcing when players join and leave. | true | true/false | 0.1.9 | -| PLAYER_LOGGING_POLL_PERIOD | Polling period (in seconds) to check for players who have joined or left | 5 | !0 | 0.1.9 | -| ARM_COMPATIBILITY_MODE | Switches the compatibility layer from Box86 to QEMU when executing steamcmd for server updates. This setting is only applicable for ARM64 hosts. | false | true/false | 0.1.0 | +| Variable | Info | Default Value | Allowed Values | Added in Version | +|----------------------------------------------|--------------------------------------------------------------------------------------------------------------------------------------------------|----------------------------------------------------------------------------------------------------|-------------------------------------------------------------------------------------------------------------------|------------------| +| TZ | Timezone used for Cron and Game server. (Not applicable to Log) | UTC | See [TZ Identifiers](https://en.wikipedia.org/wiki/List_of_tz_database_time_zones#Time_Zone_abbreviations) | 0.1.0 | +| PUID\* | The uid of the user the server should run as. | 1000 | !0 | 0.1.0 | +| PGID\* | The gid of the user the server should run as. | 1000 | !0 | 0.1.0 | +| PORT\* | Game port that the server will expose. | 7777 | 1024-65535 | 0.1.0 | +| QUERY_PORT | Query port used to communicate with Steam servers. | 27016 | 1024-65535 | 0.1.0 | +| UPDATE_ON_BOOT\*\* | Update the server when the docker container starts. | true | true/false | 0.1.0 | +| BACKUP_ENABLED | Enables automatic backups. | true | true/false | 0.1.1 | +| BACKUP_CRON_EXPRESSION | Setting affects frequency of automatic backups. | 0 0 \* \* \* | Needs a Cron-Expression - See [Configuring Automatic Backups with Cron](#configuring-automatic-backups-with-cron) | 0.1.1 | +| DELETE_OLD_BACKUPS | Delete backups after a certain number of days. | false | true/false | 0.1.1 | +| OLD_BACKUP_DAYS | How many days to keep backups. | 30 | any positive integer | 0.1.1 | +| AUTO_UPDATE_ENABLED | Enables automatic updates. | false | true/false | 0.1.4 | +| AUTO_UPDATE_CRON_EXPRESSION | Setting affects frequency of automatic updates. | 0 \* \* \* \* | Needs a Cron-Expression - See [Configuring Automatic Updates with Cron](#configuring-automatic-updates-with-cron) | 0.1.4 | +| AUTO_UPDATE_WARN_MINUTES | How long to wait to saved and update the server, after the player were informed. (This will be ignored, if no Players are connected) | 15 | !0 | 0.1.4 | +| AUTO_UPDATE_WARN_MESSAGE | Messages to broadcast on countdown for automatic updates. | Server will update in `remaining_time` minutes. | "string" | 0.1.10 | +| AUTO_UPDATE_WARN_REMAINING_TIMES | Informing when the remaining time during countdown is included. | 1 5 10 | !0 and " "(Space) | 0.1.10 | +| AUTO_REBOOT_ENABLED | Enables automatic reboots. | false | true/false | 0.1.10 | +| AUTO_REBOOT_CRON_EXPRESSION | Setting affects frequency of automatic reboots. | 0 0 \* \* \* | Needs a Cron-Expression - See [Configuring Automatic Reboots with Cron](#configuring-automatic-reboots-with-cron) | 0.1.10 | +| AUTO_REBOOT_WARN_MINUTES | How long to wait to saved and reboot the server, after the player were informed. (This will be ignored, if no Players are connected) | 15 | !0 | 0.1.10 | +| AUTO_REBOOT_WARN_MESSAGE | Messages to broadcast on countdown for automatic reboots. | Server will reboot in `remaining_time` minutes. | "string" | 0.1.10 | +| AUTO_REBOOT_WARN_REMAINING_TIMES | Informing when the remaining time during countdown is included. | 1 5 10 | !0 and " "(Space) | 0.1.10 | +| AUTO_REBOOT_EVEN_IF_PLAYERS_ONLINE | Reboot the Server even if there are players online. | false | true/false | 0.1.10 | +| BROADCAST_COUNTDOWN_SUSPEND_MESSAGE | Discord message when countdown suspended due to no players. | Suspends countdown because there are no players. | "string" | 0.1.10 | +| BROADCAST_COUNTDOWN_SUSPEND_MESSAGE_ENABLED | If the Discord message is enabled for this message. | true | true/false | 0.1.2 | +| TARGET_COMMIT_ID | Install and run the game server at the specified version. | _(empty)_ | See [Locking Specific Game Version](#locking-specific-game-version)(#target-commit-id) | 0.1.3 | +| DISCORD_WEBHOOK_URL | Discord webhook url found after creating a webhook on a discord server. | _(empty)_ | `https://discord.com/api/webhooks/` | 0.1.0 | +| DISCORD_SUPPRESS_NOTIFICATIONS | Enables/Disables `@silent` messages for the server messages. | false | true/false | 0.1.0 | +| DISCORD_CONNECT_TIMEOUT | Discord command initial connection timeout. | 30 | !0 | 0.1.0 | +| DISCORD_MAX_TIMEOUT | Discord total hook timeout. | 30 | !0 | 0.1.0 | +| DISCORD_PRE_INSTALL_MESSAGE | Discord message sent when server begins installing. | Server is installing... | "string" | 0.1.0 | +| DISCORD_PRE_INSTALL_MESSAGE_ENABLED | If the Discord message is enabled for this message. | true | true/false | 0.1.0 | +| DISCORD_PRE_INSTALL_MESSAGE_URL | Discord Webhook URL for this message. (if left empty will use DISCORD_WEBHOOK_URL) | _(empty)_ | `https://discord.com/api/webhooks/` | 0.1.0 | +| DISCORD_POST_INSTALL_MESSAGE | Discord message sent when server completes installing. | Server install complete! | "string" | 0.1.2 | +| DISCORD_POST_INSTALL_MESSAGE_ENABLED | If the Discord message is enabled for this message. | true | true/false | 0.1.2 | +| DISCORD_POST_INSTALL_MESSAGE_URL | Discord Webhook URL for this message. (if left empty will use DISCORD_WEBHOOK_URL) | _(empty)_ | `https://discord.com/api/webhooks/` | 0.1.2 | +| DISCORD_PRE_UPDATE_BOOT_MESSAGE | Discord message sent when server begins updating. | Server is updating... | "string" | 0.1.0 | +| DISCORD_PRE_UPDATE_BOOT_MESSAGE_ENABLED | If the Discord message is enabled for this message. | true | true/false | 0.1.0 | +| DISCORD_PRE_UPDATE_BOOT_MESSAGE_URL | Discord Webhook URL for this message. (if left empty will use DISCORD_WEBHOOK_URL) | _(empty)_ | `https://discord.com/api/webhooks/` | 0.1.0 | +| DISCORD_POST_UPDATE_BOOT_MESSAGE | Discord message sent when server completes updating. | Server update complete! | "string" | 0.1.2 | +| DISCORD_POST_UPDATE_BOOT_MESSAGE_ENABLED | If the Discord message is enabled for this message. | true | true/false | 0.1.2 | +| DISCORD_POST_UPDATE_BOOT_MESSAGE_URL | Discord Webhook URL for this message. (if left empty will use DISCORD_WEBHOOK_URL) | _(empty)_ | `https://discord.com/api/webhooks/` | 0.1.2 | +| DISCORD_PRE_START_MESSAGE | Discord message sent when server begins to start. | Server has been started! | "string" | 0.1.0 | +| DISCORD_PRE_START_MESSAGE_ENABLED | If the Discord message is enabled for this message. | true | true/false | 0.1.0 | +| DISCORD_PRE_START_MESSAGE_URL | Discord Webhook URL for this message. (if left empty will use DISCORD_WEBHOOK_URL) | _(empty)_ | `https://discord.com/api/webhooks/` | 0.1.0 | +| DISCORD_PRE_START_MESSAGE_WITH_GAME_SETTINGS | Send the server settings with DISCORD_PRE_START_MESSAGE. | true | true/false | 0.1.1 | +| DISCORD_PRE_START_MESSAGE_WITH_SERVER_IP | Send the server IP and Port with DISCORD_PRE_START_MESSAGE. | false | true/false | 0.1.0 | +| DISCORD_PRE_START_MESSAGE_WITH_DOMAIN | Send the Domain and Port with DISCORD_PRE_START_MESSAGE. (DISCORD_SERVER_INFO_MESSAGE_WITH_IP value ignored when set) | _(empty)_ | `example.com`, `http://example.com`, `https://example.com` | 0.1.11 | +| DISCORD_PRE_SHUTDOWN_MESSAGE | Discord message sent when server begins to shutdown. | Server is shutting down... | "string" | 0.1.0 | +| DISCORD_PRE_SHUTDOWN_MESSAGE_ENABLED | If the Discord message is enabled for this message. | true | true/false | 0.1.0 | +| DISCORD_PRE_SHUTDOWN_MESSAGE_URL | Discord Webhook URL for this message. (if left empty will use DISCORD_WEBHOOK_URL) | _(empty)_ | `https://discord.com/api/webhooks/` | 0.1.0 | +| DISCORD_POST_SHUTDOWN_MESSAGE | Discord message sent when server begins to shutdown. | Server is stopped! | "string" | 0.1.0 | +| DISCORD_POST_SHUTDOWN_MESSAGE_ENABLED | If the Discord message is enabled for this message. | true | true/false | 0.1.0 | +| DISCORD_POST_SHUTDOWN_MESSAGE_URL | Discord Webhook URL for this message. (if left empty will use DISCORD_WEBHOOK_URL) | _(empty)_ | `https://discord.com/api/webhooks/` | 0.1.0 | +| DISCORD_PLAYER_JOIN_MESSAGE | Discord message sent when player joins the server. | `player_name` has joined! | "string" | 0.1.9 | +| DISCORD_PLAYER_JOIN_MESSAGE_ENABLED | If the Discord message is enabled for this message. | true | true/false | 0.1.9 | +| DISCORD_PLAYER_JOIN_MESSAGE_URL | Discord Webhook URL for this message. (if left empty will use DISCORD_WEBHOOK_URL) | _(empty)_ | `https://discord.com/api/webhooks/` | 0.1.9 | +| DISCORD_PLAYER_LEAVE_MESSAGE | Discord message sent when player leaves the server. | `player_name` has left. | "string" | 0.1.9 | +| DISCORD_PLAYER_LEAVE_MESSAGE_ENABLED | If the Discord message is enabled for this message. | true | true/false | 0.1.9 | +| DISCORD_PLAYER_LEAVE_MESSAGE_URL | Discord Webhook URL for this message. (if left empty will use DISCORD_WEBHOOK_URL) | _(empty)_ | `https://discord.com/api/webhooks/` | 0.1.9 | +| DISCORD_PRE_BACKUP_MESSAGE | Discord message when starting to create a backup. | Creating backup... | "string" | 0.1.1 | +| DISCORD_PRE_BACKUP_MESSAGE_ENABLED | If the Discord message is enabled for this message. | true | true/false | 0.1.1 | +| DISCORD_PRE_BACKUP_MESSAGE_URL | Discord Webhook URL for this message. (if left empty will use DISCORD_WEBHOOK_URL) | _(empty)_ | `https://discord.com/api/webhooks/` | 0.1.1 | +| DISCORD_POST_BACKUP_MESSAGE | Discord message when a backup has been made. | Backup created at `file_path` | "string" | 0.1.1 | +| DISCORD_POST_BACKUP_MESSAGE_ENABLED | If the Discord message is enabled for this message. | true | true/false | 0.1.1 | +| DISCORD_POST_BACKUP_MESSAGE_URL | Discord Webhook URL for this message. (if left empty will use DISCORD_WEBHOOK_URL) | _(empty)_ | `https://discord.com/api/webhooks/` | 0.1.1 | +| DISCORD_PRE_BACKUP_DELETE_MESSAGE | Discord message when starting to remove older backups. | Removing backups older than `old_backup_days` days | "string" | 0.1.1 | +| DISCORD_PRE_BACKUP_DELETE_MESSAGE_ENABLED | If the Discord message is enabled for this message. | true | true/false | 0.1.1 | +| DISCORD_PRE_BACKUP_DELETE_MESSAGE_URL | Discord Webhook URL for this message. (if left empty will use DISCORD_WEBHOOK_URL) | _(empty)_ | `https://discord.com/api/webhooks/` | 0.1.1 | +| DISCORD_POST_BACKUP_DELETE_MESSAGE | Discord message when successfully removed older backups. | Removed backups older than `old_backup_days` days | "string" | 0.1.1 | +| DISCORD_POST_BACKUP_DELETE_MESSAGE_ENABLED | If the Discord message is enabled for this message. | true | true/false | 0.1.1 | +| DISCORD_POST_BACKUP_DELETE_MESSAGE_URL | Discord Webhook URL for this message. (if left empty will use DISCORD_WEBHOOK_URL) | _(empty)_ | `https://discord.com/api/webhooks/` | 0.1.1 | +| DISCORD_ERR_BACKUP_DELETE_MESSAGE | Discord message when there has been an error removing older backups. | Unable to delete old backups, OLD_BACKUP_DAYS is not an integer. OLD_BACKUP_DAYS=`old_backup_days` | "string" | 0.1.1 | +| DISCORD_ERR_BACKUP_DELETE_MESSAGE_ENABLED | If the Discord message is enabled for this message. | true | true/false | 0.1.1 | +| DISCORD_ERR_BACKUP_DELETE_MESSAGE_URL | Discord Webhook URL for this message. (if left empty will use DISCORD_WEBHOOK_URL) | _(empty)_ | `https://discord.com/api/webhooks/` | 0.1.1 | +| DISCORD_BROADCAST_MESSAGE_ENABLE\*\* | If the Discord message is enabled for broadcast content. | true | true/false | 0.1.6 | +| DISCORD_BROADCAST_MESSAGE_URL\* | Discord Webhook URL for this message. (if left empty will use DISCORD_WEBHOOK_URL) | _(empty)_ | `https://discord.com/api/webhooks/` | 0.1.6 | +| DISABLE_GENERATE_SETTINGS | Whether to automatically generate the Game.ini | false | true/false | 0.1.1 | +| ENABLE_PLAYER_LOGGING | Enables Logging and announcing when players join and leave. | true | true/false | 0.1.9 | +| PLAYER_LOGGING_POLL_PERIOD | Polling period (in seconds) to check for players who have joined or left | 5 | !0 | 0.1.9 | +| ARM_COMPATIBILITY_MODE | Switches the compatibility layer from Box86 to QEMU when executing steamcmd for server updates. This setting is only applicable for ARM64 hosts. | false | true/false | 0.1.0 | \* highly recommended to set @@ -325,10 +326,12 @@ It is highly recommended you set the following environment values before startin
Click to display -| Variable | Available Versions | Reason | Changed to | -|------------------------------------|--------------------|--------|-------------------------------------| -| DISCORD_SERVER_INFO_MESSAGE_ENABLE | 0.1.0 | Typo | DISCORD_SERVER_INFO_MESSAGE_ENABLED | -| BROADCAST_COUNTDOWN_MTIMES | 0.1.6 ~ 0.1.9 | Fixed | BROADCAST_COUNTDOWN_REMAINING_TIMES | +| Variable | Available Versions | Reason | Changed to | +|-------------------------------------|--------------------|--------|----------------------------------------------| +| DISCORD_SERVER_INFO_MESSAGE_ENABLE | 0.1.0 | Typo | DISCORD_PRE_START_MESSAGE_WITH_GAME_SETTINGS | +| DISCORD_SERVER_INFO_MESSAGE_ENABLED | 0.1.1 ~ 0.1.10 | Fixed | DISCORD_PRE_START_MESSAGE_WITH_GAME_SETTINGS | +| DISCORD_SERVER_INFO_MESSAGE_WITH_IP | 0.1.0 ~ 0.1.10 | Fixed | DISCORD_PRE_START_MESSAGE_WITH_SERVER_IP | +| BROADCAST_COUNTDOWN_MTIMES | 0.1.6 ~ 0.1.9 | Fixed | BROADCAST_COUNTDOWN_REMAINING_TIMES |
diff --git a/docs/kr/README.md b/docs/kr/README.md index 122a460..a3303ea 100644 --- a/docs/kr/README.md +++ b/docs/kr/README.md @@ -280,8 +280,9 @@ docker rmi $(docker images | grep -E ^"(ghcr.io\/)?kimzuni/longvinter-docker-ser | DISCORD_PRE_START_MESSAGE | 서버 시작 시 전송되는 디스코드 메시지 | Server has been started! | "string" | 0.1.0 | | DISCORD_PRE_START_MESSAGE_ENABLED | 이 값이 `true`인 경우에만 해당 메시지 전송 | true | true/false | 0.1.0 | | DISCORD_PRE_START_MESSAGE_URL | 해당 메시지를 보낼 디스코드 웹훅 URL (이 값을 비워둘 경우 DISCORD_WEBHOOK_URL 사용) | _(empty)_ | `https://discord.com/api/webhooks/` | 0.1.0 | -| DISCORD_SERVER_INFO_MESSAGE_ENABLED | 서버 시작 메시지 전송 시 서버 설정 내용을 같이 전송 | true | true/false | 0.1.1 | -| DISCORD_SERVER_INFO_MESSAGE_WITH_IP | 서버 설정 내용 전송 시 서버 IP 및 포트 번호를 같이 전송 ("IP로 접속하기"로 연결할 때 필요) | false | true/false | 0.1.0 | +| DISCORD_PRE_START_MESSAGE_WITH_SERVER_INFO | 서버 시작 메시지 전송 시 서버 설정 내용을 같이 전송 | true | true/false | 0.1.1 | +| DISCORD_PRE_START_MESSAGE_WITH_SERVER_IP | 서버 시작 메시지 전송 시 서버 IP 및 포트 번호를 같이 전송 | false | true/false | 0.1.0 | +| DISCORD_PRE_START_MESSAGE_WITH_DOMAIN | 서버 시작 메시지 전송 시 도메인 및 포트 번호를 같이 전송 (DISCORD_PRE_START_MESSAGE_WITH_IP 값이 무시됨) | _(empty)_ | `example.com`, `http://example.com`, `https://example.com` | 0.1.11 | | DISCORD_PRE_SHUTDOWN_MESSAGE | 서버 종료 전 전송되는 디스코드 메시지 | Server is shutting down... | "string" | 0.1.0 | | DISCORD_PRE_SHUTDOWN_MESSAGE_ENABLED | 이 값이 `true`인 경우에만 해당 메시지 전송 | true | true/false | 0.1.0 | | DISCORD_PRE_SHUTDOWN_MESSAGE_URL | 해당 메시지를 보낼 디스코드 웹훅 URL (이 값을 비워둘 경우 DISCORD_WEBHOOK_URL 사용) | _(empty)_ | `https://discord.com/api/webhooks/` | 0.1.0 | @@ -325,10 +326,12 @@ docker rmi $(docker images | grep -E ^"(ghcr.io\/)?kimzuni/longvinter-docker-ser
목록 보기 -| 변수명 | 사용 가능한 버전 | 사유 | 대체된 변수명 | -|------------------------------------|---------------|------|-------------------------------------| -| DISCORD_SERVER_INFO_MESSAGE_ENABLE | 0.1.0 | 오타 | DISCORD_SERVER_INFO_MESSAGE_ENABLED | -| BROADCAST_COUNTDOWN_MTIMES | 0.1.6 ~ 0.1.9 | 수정 | BROADCAST_COUNTDOWN_REMAINING_TIMES | +| 변수명 | 사용 가능한 버전 | 사유 | 대체된 변수명 | +|-------------------------------------|----------------|-----|----------------------------------------------| +| DISCORD_SERVER_INFO_MESSAGE_ENABLE | 0.1.0 | 오타 | DISCORD_PRE_START_MESSAGE_WITH_GAME_SETTINGS | +| DISCORD_SERVER_INFO_MESSAGE_ENABLED | 0.1.1 ~ 0.1.10 | 수정 | DISCORD_PRE_START_MESSAGE_WITH_GAME_SETTINGS | +| DISCORD_SERVER_INFO_MESSAGE_WITH_IP | 0.1.0 ~ 0.1.10 | 수정 | DISCORD_PRE_START_MESSAGE_WITH_SERVER_IP | +| BROADCAST_COUNTDOWN_MTIMES | 0.1.6 ~ 0.1.9 | 수정 | BROADCAST_COUNTDOWN_REMAINING_TIMES |
diff --git a/scripts/discord.sh b/scripts/discord.sh index ad93290..ef60739 100644 --- a/scripts/discord.sh +++ b/scripts/discord.sh @@ -64,7 +64,7 @@ else COLOR=$DISCORD_BLUE fi -if [ "${TITLE,,}" == "start" ] && [ "$DISCORD_SERVER_INFO_MESSAGE_ENABLED" = true ]; then +if [ "${TITLE,,}" == "start" ]; then MESSAGE=$(echo -e "$MESSAGE\n"; Server_Info | sed -E "s/([^:]+):(.+)/**\1**:\2/g") fi diff --git a/scripts/helper_functions.sh b/scripts/helper_functions.sh index bde43f9..9e88df1 100644 --- a/scripts/helper_functions.sh +++ b/scripts/helper_functions.sh @@ -285,27 +285,39 @@ date_to_timestamp() { } Server_Info() { + local IP INFO local HTTP URL="$CFG_COMMUNITY_WEBSITE" + if ! [[ "$URL" =~ ^https?:// ]] && [ -n "$URL" ]; then HTTP="http://" fi - echo "Server Name: $CFG_SERVER_NAME" - if [ -z "$DISCORD_SERVER_INFO_MESSAGE_WITH_DOMAIN" ]; then - echo "Server Domain: ${DISCORD_SERVER_INFO_MESSAGE_WITH_DOMAIN#http*://}" - echo "Server Port: $PORT" - elif [ "$DISCORD_SERVER_INFO_MESSAGE_WITH_IP" = true ]; then - echo "Server IP: $(curl -sfSL icanhazip.com)" - echo "Server Port: $PORT" + if [ -n "$DISCORD_PRE_START_MESSAGE_WITH_DOMAIN" ]; then + IP="${DISCORD_PRE_START_MESSAGE_WITH_DOMAIN#http*://}" + elif [ "$DISCORD_PRE_START_MESSAGE_WITH_SERVER_IP" = true ]; then + IP="$(curl -sfSL ipv4.icanhazip.com)" + fi + if [ -n "$IP" ]; then + INFO="Server IP: $IP"$'\n'"Server Port: $PORT"$'\n' fi - echo "Server Password: $CFG_PASSWORD" - echo - echo "Message of the Day: $CFG_SERVER_MOTD" - echo "Community URL: $HTTP${URL:-None}" - echo "Max Player: $CFG_MAX_PLAYERS" - echo "PVP: $CFG_ENABLE_PVP" - echo "Tent Decay: $CFG_TENT_DECAY" - echo "Max Tent: $CFG_MAX_TENTS" - echo "Coop Play: $CFG_COOP_PLAY" - echo "Coop Spawn: $CFG_COOP_SPAWN" + + if [ "$DISCORD_PRE_START_MESSAGE_WITH_GAME_SETTINGS" = true ]; then + INFO=$( +cat << END +Server Name: $CFG_SERVER_NAME +${INFO}Server Password: $CFG_PASSWORD + +Message of the Day: $CFG_SERVER_MOTD +Community URL: $HTTP${URL:-None} +Max Player: $CFG_MAX_PLAYERS +PVP: $CFG_ENABLE_PVP +Tent Decay: $CFG_TENT_DECAY +Max Tent: $CFG_MAX_TENTS +Coop Play: $CFG_COOP_PLAY +Coop Spawn: $CFG_COOP_SPAWN +END + ) + fi + + echo "$INFO" }