Hi Guys,
I managed to patch together some code but now im a little stuck with getting through the rest of it, i want be able to use a script to start, stop, restart and update a cs server, under niether is what i have so far, to update the server i would normal have to locate the server directory and use the command "./steam -command update -game "Counter-Strike Source" -verify_all -dir /games/st0n3r/css_dust2/". any help would be great
#!/bin/sh
cd /games/st0n3r/css_dust2/
case "$1" in
start)
sudo screen -d -S cs ./srcds_run -game cstrike -port 30015 +ip 83.142.54.221 +maxplayers 33 +map de_dust2 +tv_port 30016 -autoupdate
;;
stop)
screen -r css_dust2 -X quit
echo Server Has Been Stopped!
;;
*)
echo "Usage: hlds {start|stop}"
exit 1
;;
esac
exit 0