Rebrand dedicated server as straywild
This commit is contained in:
parent
481997b42c
commit
c1b228475d
14 changed files with 132 additions and 132 deletions
|
|
@ -12,15 +12,15 @@ fi
|
|||
|
||||
archive_path="$(readlink -f -- "$1")"
|
||||
checksum_input="$2"
|
||||
install_root="${NETFISHING_INSTALL_ROOT:-/opt/netfishing-server}"
|
||||
service_name="${NETFISHING_SERVICE_NAME:-netfishing-server.service}"
|
||||
install_root="${straywild_INSTALL_ROOT:-/opt/straywild-server}"
|
||||
service_name="${straywild_SERVICE_NAME:-straywild-server.service}"
|
||||
|
||||
if [[ ! -f "${archive_path}" ]]; then
|
||||
echo "Archive not found: $1" >&2
|
||||
exit 1
|
||||
fi
|
||||
if [[ "${install_root}" != /* || "${install_root}" == "/" ]]; then
|
||||
echo "NETFISHING_INSTALL_ROOT must be a specific absolute directory." >&2
|
||||
echo "straywild_INSTALL_ROOT must be a specific absolute directory." >&2
|
||||
exit 2
|
||||
fi
|
||||
|
||||
|
|
@ -42,7 +42,7 @@ if [[ "${actual_sha256}" != "${expected_sha256}" ]]; then
|
|||
exit 1
|
||||
fi
|
||||
|
||||
work_dir="$(mktemp -d /tmp/netfishing-server-install.XXXXXX)"
|
||||
work_dir="$(mktemp -d /tmp/straywild-server-install.XXXXXX)"
|
||||
release_stage=""
|
||||
cleanup() {
|
||||
if [[ -n "${release_stage}" && -d "${release_stage}" ]]; then
|
||||
|
|
@ -85,7 +85,7 @@ if [[ -n "$(find "${payload_dir}" -type l -print -quit)" ]]; then
|
|||
echo "Archive payload may not contain symbolic links." >&2
|
||||
exit 1
|
||||
fi
|
||||
for filename in NETfishingServer.x86_64 NETfishingServer.pck BUILD_INFO SHA256SUMS; do
|
||||
for filename in straywildServer.x86_64 straywildServer.pck BUILD_INFO SHA256SUMS; do
|
||||
if [[ ! -f "${payload_dir}/${filename}" ]]; then
|
||||
echo "Archive is missing ${filename}." >&2
|
||||
exit 1
|
||||
|
|
@ -169,8 +169,8 @@ if [[ -e "${release_dir}" ]]; then
|
|||
(cd -- "${release_dir}" && sha256sum -c SHA256SUMS)
|
||||
else
|
||||
release_stage="$(mktemp -d "${releases_dir}/.incoming.XXXXXX")"
|
||||
install -m 0555 "${payload_dir}/NETfishingServer.x86_64" "${release_stage}/"
|
||||
install -m 0444 "${payload_dir}/NETfishingServer.pck" "${release_stage}/"
|
||||
install -m 0555 "${payload_dir}/straywildServer.x86_64" "${release_stage}/"
|
||||
install -m 0444 "${payload_dir}/straywildServer.pck" "${release_stage}/"
|
||||
install -m 0444 "${payload_dir}/BUILD_INFO" "${release_stage}/"
|
||||
install -m 0444 "${payload_dir}/SHA256SUMS" "${release_stage}/"
|
||||
install -m 0444 "${payload_dir}/SOURCE-CODE.md" "${release_stage}/"
|
||||
|
|
@ -207,7 +207,7 @@ if command -v systemctl >/dev/null && systemctl cat "${service_name}" >/dev/null
|
|||
if systemctl is-active --quiet "${service_name}"; then
|
||||
service_active=true
|
||||
unit_text="$(systemctl cat "${service_name}")"
|
||||
if [[ "${unit_text}" != *"${install_root}/current/NETfishingServer.x86_64"* ]]; then
|
||||
if [[ "${unit_text}" != *"${install_root}/current/straywildServer.x86_64"* ]]; then
|
||||
echo "Active ${service_name} does not use the current-release symlink." >&2
|
||||
echo "Migrate the unit while stopped before using this updater." >&2
|
||||
exit 1
|
||||
|
|
@ -244,7 +244,7 @@ if [[ -n "${old_current}" && "${old_current}" != "${release_dir}" ]]; then
|
|||
replace_symlink "${old_current}" "${install_root}/previous"
|
||||
fi
|
||||
|
||||
echo "Installed NETfishing dedicated server ${game_version} (${game_commit})."
|
||||
echo "Installed straywild dedicated server ${game_version} (${game_commit})."
|
||||
if [[ -n "${packaging_commit}" ]]; then
|
||||
echo "Dedicated packaging commit: ${packaging_commit}."
|
||||
fi
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue