utilisateur glasnost dans le paquet debian: glasnost-daemon
This commit is contained in:
parent
813ea62477
commit
ae97d92934
|
@ -5,6 +5,7 @@ PATH=/usr/local/sbin:/usr/local/bin:/sbin:/bin:/usr/sbin:/usr/bin
|
|||
DESC="glasnost"
|
||||
NAME="glasnost"
|
||||
DIR=/usr/lib/glasnost/
|
||||
GLASNOST_USER=glasnost-daemon
|
||||
|
||||
#set -e
|
||||
|
||||
|
@ -13,14 +14,14 @@ case "$1" in
|
|||
echo -n "Starting $DESC: "
|
||||
for SERV in Dispatcher VirtualHostsServer Gateway
|
||||
do
|
||||
start-stop-daemon --chuid glasnost \
|
||||
start-stop-daemon --chuid $GLASNOST_USER \
|
||||
--start --exec $DIR/servers/$SERV/$SERV.py
|
||||
echo -n '.'
|
||||
sleep 5
|
||||
done
|
||||
for SERV in `ls $DIR/servers/ | egrep -v 'Dispatcher|Gateway|VirtualHosts'`
|
||||
do
|
||||
start-stop-daemon --chuid glasnost \
|
||||
start-stop-daemon --chuid $GLASNOST_USER \
|
||||
--start --exec $DIR/servers/$SERV/$SERV.py
|
||||
echo -n '.'
|
||||
done
|
||||
|
@ -29,7 +30,7 @@ case "$1" in
|
|||
;;
|
||||
stop)
|
||||
echo -n "Stopping $DESC: "
|
||||
start-stop-daemon --stop --user glasnost || true
|
||||
start-stop-daemon --stop --user $GLASNOST_USER || true
|
||||
echo "done."
|
||||
;;
|
||||
restart|force-reload)
|
||||
|
@ -39,20 +40,20 @@ case "$1" in
|
|||
# just the same as "restart".
|
||||
#
|
||||
echo -n "Restarting $DESC (this takes time): "
|
||||
start-stop-daemon --stop --user glasnost || true
|
||||
start-stop-daemon --stop --user $GLASNOST_USER || true
|
||||
|
||||
sleep 20
|
||||
|
||||
for SERV in Dispatcher VirtualHostsServer Gateway
|
||||
do
|
||||
start-stop-daemon --chuid glasnost \
|
||||
start-stop-daemon --chuid $GLASNOST_USER \
|
||||
--start --exec $DIR/servers/$SERV/$SERV.py
|
||||
echo -n '.'
|
||||
sleep 5
|
||||
done
|
||||
for SERV in `ls $DIR/servers/ | egrep -v 'Dispatcher|Gateway|VirtualHosts'`
|
||||
do
|
||||
start-stop-daemon --chuid glasnost \
|
||||
start-stop-daemon --chuid $GLASNOST_USER \
|
||||
--start --exec $DIR/servers/$SERV/$SERV.py
|
||||
echo -n '.'
|
||||
done
|
||||
|
|
|
@ -23,7 +23,7 @@ case "$1" in
|
|||
;;
|
||||
esac
|
||||
|
||||
GLASNOST_USER=glasnost
|
||||
GLASNOST_USER=glasnost-daemon
|
||||
|
||||
if [ -x /usr/sbin/adduser ]; then
|
||||
id $GLASNOST_USER > /dev/null 2>&1 ||
|
||||
|
|
Reference in New Issue