Browse Source

formatting and helpers to cat pid files (if available)

4.0
bitbashing 10 years ago
parent
commit
08d9a7dd65
4 changed files with 27 additions and 11 deletions
  1. +8
    -8
      system/sbin/kazoo-applications
  2. +9
    -1
      system/sbin/kazoo-haproxy
  3. +9
    -1
      system/sbin/kazoo-kamailio
  4. +1
    -1
      system/sbin/kazoo-rabbitmq

+ 8
- 8
system/sbin/kazoo-applications View File

@ -125,8 +125,8 @@ case "$1" in
start "start"
;;
foreground)
start "foreground"
;;
start "foreground"
;;
stop)
stop
;;
@ -140,14 +140,14 @@ case "$1" in
connect
;;
attach)
attach
;;
attach
;;
ping)
ping
;;
ping
;;
pid)
pid
;;
pid
;;
*)
echo "Usage: $0 (prpeare|start|foreground|stop|restart|status|connect|attach|ping|pid)"
RETVAL=1


+ 9
- 1
system/sbin/kazoo-haproxy View File

@ -140,6 +140,11 @@ check_config() {
fi
}
pid() {
cat ${PID_FILE}
RETVAL=$?
}
case "$1" in
prepare)
prepare
@ -167,8 +172,11 @@ case "$1" in
check)
check_config
;;
pid)
pid
;;
*)
echo $"Usage: $0 {prepare|start|foreground|stop|restart|status|reload|check}"
echo $"Usage: $0 {prepare|start|foreground|stop|restart|status|reload|check|pid}"
RETVAL=1
esac

+ 9
- 1
system/sbin/kazoo-kamailio View File

@ -91,6 +91,11 @@ check_config ()
fi
}
pid() {
cat ${PID_FILE}
RETVAL=$?
}
case "$1" in
prepare)
prepare
@ -115,8 +120,11 @@ case "$1" in
check)
check_config
;;
pid)
pid
;;
*)
echo $"Usage: $0 {prepare|start|foreground|stop|restart|status|check}"
echo $"Usage: $0 {prepare|start|foreground|stop|restart|status|check|pid}"
RETVAL=1
esac


+ 1
- 1
system/sbin/kazoo-rabbitmq View File

@ -41,7 +41,7 @@ start() {
set -- ${BIN_FILE} "$@"
if [ "$(whoami)" == "${USER}" ]; then
exec "$@"
else
else
exec sudo -u ${USER} "$@"
fi
RETVAL=$?


Loading…
Cancel
Save