-
Notifications
You must be signed in to change notification settings - Fork 4
/
Copy pathglobal.sh
executable file
·50 lines (39 loc) · 2.57 KB
/
global.sh
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
#!/bin/bash
#./build.sh
#scp -P22022 target/init6.jar i6serverhost@216.244.82.98:/home/i6serverhost/init6.jar.new
#scp -P22022 src/main/resources/akka.conf i6serverhost@sea.wserv.org:/home/i6serverhost/init6/akka.conf
#scp -P22022 target/init6.jar i6serverhost@205.234.159.242:/home/i6serverhost/init6.jar.new
#scp -P22022 src/main/resources/akka.conf i6serverhost@chi.wserv.org:/home/i6serverhost/init6/akka.conf
#scp -P22022 target/init6.jar i6serverhost@dal.wserv.org:/home/i6serverhost/init6.jar.new
#scp -P22022 src/main/resources/akka.conf i6serverhost@dal.wserv.org:/home/i6serverhost/init6/akka.conf
#scp -P22022 target/init6.jar i6serverhost@chat.wserv.org:/home/i6serverhost/init6.jar.new
#scp -P22022 src/main/resources/akka.conf i6serverhost@chat.wserv.org:/home/i6serverhost/init6/akka.conf
#scp -P22022 target/init6.jar i6serverhost@50.2.212.132:/home/i6serverhost/init6.jar.new
ssh -p22022 -f i6serverhost@216.244.82.98 "crontab -r"
ssh -p22022 -f i6serverhost@dal.wserv.org "crontab -r"
ssh -p22022 -f i6serverhost@chat.wserv.org "crontab -r"
ssh -p22022 -f i6serverhost@205.234.159.242 "crontab -r"
sleep 2
ssh -p22022 -f i6serverhost@216.244.82.98 "./k.sh"
ssh -p22022 -f i6serverhost@dal.wserv.org "./k.sh"
ssh -p22022 -f i6serverhost@chat.wserv.org "./k.sh"
ssh -p22022 -f i6serverhost@205.234.159.242 "./k.sh"
#ssh -p22022 -f i6serverhost@50.2.212.132 "./k.sh"
sleep 15
for i in $(seq 1 1 3|sort -R); do
if [ $i -eq 1 ]; then
ssh -p22022 -f i6serverhost@216.244.82.98 "cp init6.jar.new init6/init6.jar; cd init6; ./start.sh &> /dev/null"
elif [ $i -eq 2 ]; then
ssh -p22022 -f i6serverhost@205.234.159.242 "cp init6.jar.new init6/init6.jar; cd init6; ./start.sh &> /dev/null"
elif [ $i -eq 3 ]; then
ssh -p22022 -f i6serverhost@dal.wserv.org "cp init6.jar.new init6/init6.jar; cd init6; ./start.sh &> /dev/null"
fi
sleep 12
done
ssh -p22022 -f i6serverhost@chat.wserv.org "cp init6.jar.new init6/init6.jar; cd init6; ./start.sh &> /dev/null"
ssh -p22022 -f i6serverhost@216.244.82.98 "cp init6.jar.new init6-sandbox/init6.jar; cd init6-sandbox; ./start_sandbox.sh &> /dev/null"
sleep 10
ssh -p22022 -f i6serverhost@chat.wserv.org "echo \"*/5 * * * * /home/i6serverhost/check_server_cron.sh\"|crontab -"
#ssh -p22022 -f i6serverhost@205.234.159.242 "echo \"*/5 * * * * /home/i6serverhost/check_server_cron.sh\"|crontab -"
#ssh -p22022 -f i6serverhost@216.244.82.98 "echo \"*/5 * * * * /home/i6serverhost/check_server_cron.sh\"|crontab -"
#ssh -p22022 -f i6serverhost@dal.wserv.org "echo \"*/5 * * * * /home/i6serverhost/check_server_cron.sh\"|crontab -"