SRCDS Steam group


Multi Server Install / Update Script
#1
This is a little bash script I whipped up to help deploy servers a bit easier. It is pretty self explanatory. If any one has suggestions, criticisms or feedback please let me know. The list was compiled from running
Code:
./steam -command list
and only choosing those with (linux) listed. It's small, simple and effective.

hl2_servers.sh
Code:
#!/bin/bash
# TITLE: Vavle Source HL2 Servers Setup
# AUTHOR: pkeffect@gmail.com
# DATE: 01/15/2012
# UPDATED: 01/19/2012
# DESCRIPTION: Script to install/update the HLDS tool and Steam plus all games.
# INSTALL:
# - Put this file in the directory you want all of your servers installed in.
# - Rename file if need be by typing 'mv hl2_servers.sh.txt hl2_servers.sh'
# - Make file executable by typing 'chmod +x hl2_servers.sh'
# - To run type './hl2_servers.sh'
#
# ! If you have a 64-bit distribution, make sure you have ia32-libs !
#
# Upon successful installation/update you will be returned to the menu.
while :
do
clear
echo ""
echo " Valve/Source/Steam Tools"
echo ""
echo " [1] Download and set permissions for hldsupdatetool.bin"
echo " [2] Run hldsupdatetool.bin update"
echo " [3] Run Steam Update"
echo "________________________________________________________________"
echo ""
echo " Use any of the following to install or update your server."
echo "               ! Options ARE case sensitive !"
echo "________________________________________________________________"
echo ""
echo " [a] Counter-Strike:Source           [b] Half-Life 2 Deathmatch"
echo " [c] Age of Chivalry                 [d] Darkest Hour"
echo " [e] Defence Alliance 2              [f] D.I.P.R.I.P. Warm Up"
echo " [g] Day of Defeat:Source            [h] Dystopia"
echo " [i] Episode 1 Engine                [j] Eternal Silence"
echo " [k] Garry's Mod                     [l] Insurgency"
echo " [m] Killing Floor                   [n] Left 4 Dead - Full"
echo " [o] Left 4 Dead                     [p] Left 4 Dead 2 - Demo"
echo " [q] Left 4 Dead 2                   [r] Mare Nostrum"
echo " [s] Nuclear Dawn                    [t] Orange Box Engine"
echo " [u] Pirates, Vikings and Knights 2  [v] Red Orchestra"
echo " [w] Ship                            [x] Smashball"
echo " [y] Synergy                         [z] Team Fortress 2"
echo " [A] Zombie Panic!:Source"
echo ""
echo " [0] Exit/Stop"
echo "________________________________________________________________"
echo " "
echo -n "Make a selection [1,2,3, a - z, A or 0]: "
read yourch
case $yourch in
1) wget http://www.steampowered.com/download/hldsupdatetool.bin && chmod 755 hldsupdatetool.bin ;;
2) ./hldsupdatetool.bin <<< "yes" ;;
3) ./steam ;;
a) ./steam -command update -game cstrike -dir . ;;
b) ./steam -command update -game hl2mp -dir . ;;
c) ./steam -command update -game ageofchivalry -dir . ;;
d) ./steam -command update -game darkesthour -dir . ;;
e) ./steam -command update -game defencealliance2 -dir . ;;
f) ./steam -command update -game diprip -dir . ;;
g) ./steam -command update -game dods -dir . ;;
h) ./steam -command update -game dystopia -dir . ;;
i) ./steam -command update -game episode1 -dir . ;;
j) ./steam -command update -game esmod -dir . ;;
k) ./steam -command update -game garrysmod -dir . ;;
l) ./steam -command update -game insurgency -dir . ;;
m) ./steam -command update -game killingfloor -dir . ;;
n) ./steam -command update -game l4d_full -dir . ;;
o) ./steam -command update -game left4dead -dir . ;;
p) ./steam -command update -game left4dead2_demo -dir . ;;
q) ./steam -command update -game left4dead2 -dir . ;;
r) ./steam -command update -game marenostrum -dir . ;;
s) ./steam -command update -game nucleardawn -dir . ;;
t) ./steam -command update -game orangebox -dir . ;;
u) ./steam -command update -game pvkii -dir . ;;
v) ./steam -command update -game redorchestra -dir . ;;
w) ./steam -command update -game ship -dir . ;;
x) ./steam -command update -game smashball -dir . ;;
y) ./steam -command update -game synergy -dir . ;;
z) ./steam -command update -game tf -dir . ;;
A) ./steam -command update -game zps -dir . ;;
0) exit 0;;
*) echo " !!! Please make a valid selection !!!";
echo " Press Enter to continue. . ." ; read ;;
esac
done

Enjoy.

Update: Fixed code to execute chmod to run hldsupdatetool.bin correctly.
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)