Added auto download the newer version of teamspeak3

This commit is contained in:
2020-03-05 22:32:37 +01:00
committed by Marcin Wozniak
parent 69e5005586
commit 2d7fe5b512
3 changed files with 63 additions and 3 deletions

5
update
View File

@ -1,12 +1,11 @@
#!/bin/bash
LINK="http://files.teamspeak-services.com/releases/server/3.6.0/teamspeak3-server_linux_amd64-3.6.0.tar.bz2"
VERSION=$(curl http://files.teamspeak-services.com/releases/server/ | egrep -o '[0-9]+\.[0-9]+\.[0-9]+' | sort | uniq | sort --version-sort --field-separator=. | tail -n1)
LINK="http://files.teamspeak-services.com/releases/server/$VERSION/teamspeak3-server_linux_amd64-$VERSION.tar.bz2"
service_ts3="ts3server serveradmin"
ts3local="/opt/teamspeak/"
mkdir -p $ts3local
if (( $(ps -ef | grep -v grep | grep "$service_ts3" | wc -l) > 0))
then