forked from AppScale/gts
-
Notifications
You must be signed in to change notification settings - Fork 0
/
appscale_rhel
executable file
·54 lines (50 loc) · 950 Bytes
/
appscale_rhel
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
51
52
53
54
#!/bin/bash
#
# appscale: Starts and stops appscale programs
#
# chkconfig: 345 56 50
#
# description: Starts and stops programs for appscale
#
#
# processname: appscale
PATH="/usr/local/sbin:/usr/local/bin:/sbin:/bin:/usr/sbin:/usr/bin"
prog="appscale"
RETVAL=0
start() {
echo -n $"Starting $prog: "
echo "Starting God"
god -c /root/appscale/AppLoadBalancer/config/global.god
echo "0" > /proc/sys/net/ipv4/icmp_echo_ignore_broadcasts
#ruby /root/appscale/AppController/changeRootPwd.rb
}
stop() {
echo -n $"Stopping $prog: "
echo "Stopping God"
pkill -9 god
}
restart() {
stop
start
}
# See how we were called.
case "$1" in
start)
start
;;
stop)
stop
;;
status)
echo "no status to report"
;;
restart|reload)
restart
;;
condrestart)
;;
*)
echo $"Usage: $0 {start|stop|status|restart|reload|condrestart}"
exit 1
esac
exit $?