diff options
author | Botond Hende <nettingman@gmail.com> | 2024-11-19 22:24:22 +0100 |
---|---|---|
committer | Botond Hende <nettingman@gmail.com> | 2024-11-19 22:24:22 +0100 |
commit | 0e0bc0275bd7c5967cef6b2e65252e67f6b9ddbd (patch) | |
tree | 0a7ab01979013d3329800f976d5803434807967b | |
parent | 40bc20606e5f2bf960b04586dcf922488fc1f943 (diff) |
do not delete server data on update
-rwxr-xr-x | update_and_start.sh | 4 |
1 files changed, 1 insertions, 3 deletions
diff --git a/update_and_start.sh b/update_and_start.sh index 8e72105..4cba621 100755 --- a/update_and_start.sh +++ b/update_and_start.sh @@ -11,8 +11,6 @@ TEMP_CONFIG_PATH=/tmp/server_config.toml LATEST_VER=$(curl https://wizards.cdn.spacestation14.com/fork/wizards | sed -nE 's/(\s*)<dd><span class="versionNumber">(.*)<\/span><\/dd>/\2/p' | head -1) if [ \! -f "$BUILD_JSON_PATH" ] || ! grep -q "$LATEST_VER" "$BUILD_JSON_PATH"; then - rm -r "$SERVER_PATH"/* - # backup server config if [ -f "$CONFIG_PATH" ]; then cp "$CONFIG_PATH" "$TEMP_CONFIG_PATH" @@ -24,7 +22,7 @@ if [ \! -f "$BUILD_JSON_PATH" ] || ! grep -q "$LATEST_VER" "$BUILD_JSON_PATH"; t # x64 version #wget "https://wizards.cdn.spacestation14.com/fork/wizards/version/$LATEST_VER/file/SS14.Server_linux-x64.zip" -O "$TEMP_ZIP_PATH" - unzip "$TEMP_ZIP_PATH" -d "$SERVER_PATH" + unzip -o "$TEMP_ZIP_PATH" -d "$SERVER_PATH" rm "$TEMP_ZIP_PATH" chmod +x "$SERVER" |