-
Notifications
You must be signed in to change notification settings - Fork 2.3k
Update Vintage Story egg for prerelease support #2181
Conversation
Please try setting the install script to this: #!/bin/bash
# Vintage Story Installation Script
#
# Server Files: /mnt/server
apt update
apt -y install wget curl jq
BRANCH="${FILES_BRANCH}"
# Fetching latest stable server release
if [ -z "${RELEASE_VERSION}" ] || [ "${RELEASE_VERSION}" == "latest" ]; then
case "${BRANCH}" in
"stable")
API_URL="http://api.vintagestory.at/stable.json"
;;
"unstable")
API_URL="http://api.vintagestory.at/unstable.json"
;;
"pre")
API_URL="http://api.vintagestory.at/pre.json"
;;
*)
echo "Invalid stage; fallback to stable"
API_URL="http://api.vintagestory.at/stable.json"
;;
esac
DOWNLOAD_URL=$(curl -SsL "$API_URL" | jq -r 'if ([.[]] | .[0].server.urls.cdn) != null then [.[]] | .[0].server.urls.cdn else [.[]] | .[0].server.urls.local end');
# Use specified server release
else
case "${BRANCH}" in
"stable")
DOWNLOAD_URL=https://cdn.vintagestory.at/gamefiles/stable/vs_server_${RELEASE_VERSION}.tar.gz
;;
"unstable")
DOWNLOAD_URL=https://account.vintagestory.at/files/unstable/vs_server_${RELEASE_VERSION}.tar.gz
;;
"pre")
DOWNLOAD_URL=https://cdn.vintagestory.at/gamefiles/pre/vs_server_${RELEASE_VERSION}.tar.gz
;;
*)
echo "Invalid stage; fallback to stable"
DOWNLOAD_URL=https://cdn.vintagestory.at/gamefiles/stable/vs_server_${RELEASE_VERSION}.tar.gz
;;
esac
fi
cd /mnt/server/ || exit
curl -o vs_server.tar.gz "${DOWNLOAD_URL}"
tar -xzf vs_server.tar.gz
rm vs_server.tar.gz
echo "-----------------------------------------"
echo "Installation completed..."
echo "-----------------------------------------" |
Works fine, although there are still logs than can be easily mitigated by keeping DEBIAN_NONINTERACTIVE flag for package installation part
|
End user can not see the install proces so that is fine. |
Removed DEBIAN_NONINTERACTIVE alltogether, hopefully now is all good ^^ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM! thank you
I just cleaned up some left over that is not more used as of panel v1 and update the install image to debian 11 |
Description
Update of Vintage Story egg to support unstable and pre release branches, mainly due to v1.18 prereleases being available (sadly, their API endpoints do not yet have that updated, as seen under respective URLs for API endpoints)
Change of README to reflect accessibility of unstable and pre file branches.
Checklist for all submissions