mirror of
https://github.com/eliasstepanik/ark-ac-server-tools.git
synced 2026-01-12 10:58:28 +00:00
install and netinstall can now update existing installation
This commit is contained in:
parent
753a86eecb
commit
fb2110eb24
@ -12,13 +12,24 @@ tar -zxvf master.tar.gz
|
||||
# Install ARK Server Tools
|
||||
cd ark-server-tools-master/tools
|
||||
chmod +x install.sh
|
||||
if [[ -n $(sh install.sh $1) ]]; then
|
||||
echo "Something where wrong :("
|
||||
else
|
||||
echo "ARK Server Tools were correctly installed in your system inside the home directory of $1!"
|
||||
fi
|
||||
sh install.sh $1
|
||||
|
||||
status = $?
|
||||
|
||||
# Remove the installation files
|
||||
rm -f master.tar.gz
|
||||
rm -rf /tmp/ark-server-tools-master
|
||||
|
||||
|
||||
if [ $status == 0 ]; then
|
||||
echo "ARK Server Tools were correctly installed in your system inside the home directory of $1!"
|
||||
fi
|
||||
|
||||
if [ $status == 1 ]; then
|
||||
echo "Something where wrong :("
|
||||
fi
|
||||
|
||||
if [ $status == 2 ]; then
|
||||
echo "WARNING: A previous version of ARK Server Tools was detected in your system, your old configuration was not overwritten. You may need to manually update it."
|
||||
echo "ARK Server Tools were correctly installed in your system inside the home directory of $1!"
|
||||
fi
|
||||
|
||||
@ -13,14 +13,20 @@ if [ ! -z $1 ]; then
|
||||
mkdir -p /var/log/arktools
|
||||
chown $1 /var/log/arktools
|
||||
|
||||
# Copy arkmanager.cfg inside linux configuation folder
|
||||
mkdir -p /etc/arkmanager
|
||||
mv arkmanager.cfg /etc/arkmanager/arkmanager.cfg
|
||||
chown $1 /etc/arkmanager/arkmanager.cfg
|
||||
# Copy arkmanager.cfg inside linux configuation folder if it doesn't already exists
|
||||
if [ -f /etc/arkmanager/arkmanager.cfg ]; then
|
||||
mkdir -p /etc/arkmanager
|
||||
cp -n arkmanager.cfg /etc/arkmanager/arkmanager.cfg
|
||||
chown $1 /etc/arkmanager/arkmanager.cfg
|
||||
else
|
||||
echo "A previous version of ARK Server Tools was detected in your system, your old configuration was not overwritten. You may need to manually update it.";
|
||||
exit 2
|
||||
fi
|
||||
|
||||
else
|
||||
echo "You must specify your system steam user who own steamcmd directory to install ARK Tools."
|
||||
echo "Usage: ./install.sh steam"
|
||||
exit 1
|
||||
fi
|
||||
|
||||
exit 0
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user