updates to version handleing

This commit is contained in:
2023-11-10 15:27:54 -08:00
parent c5081b455e
commit db531cd69d
7 changed files with 18 additions and 10 deletions

1
debian/Dockerfile vendored
View File

@@ -6,6 +6,7 @@ ARG INSTALL_SCRIPT=https://gitlab.fithwum.tech/fithwum/teamspeak-server/-/raw/ma
# Install dependencies and folder creation
RUN apt-get -y update && apt-get clean \
&& apt-get install -y ca-certificates curl jq \
&& rm -rf /var/lib/apt/lists/* \
&& mkdir -p /ts3server /ts3temp /ts3temp/inifiles /ts3temp/serverfiles \
&& chmod 777 -R /ts3server /ts3temp \

View File

@@ -6,9 +6,7 @@
TS_FILES=https://gitlab.fithwum.tech/fithwum/teamspeak-server/-/raw/main/files
echo " "
echo "Checking server version from Teamspeak."
wget --no-cache https://www.teamspeak.com/versions/server.json -O /ts3temp/server.json
TS_VERSION_CHECK=$(cat /ts3temp/server.json | grep version | head -1 | awk -F: '{print $4}' | sed 's/[",]//g' | sed "s/checksum//g")
TS_VERSION=${TS_VERSION_CHECK}
TS_VERSION=$(curl -s "https://www.teamspeak.com/versions/server.json" | jq --raw-output '.linux.x86.version')
CHANGELOG=/ts3server/CHANGELOG_${TS_VERSION}
echo "Latest server version from Teamspeak:$TS_VERSION"