Make portail-citoyen-manage use init.d to call the manager script

This commit is contained in:
Benjamin Dauvergne 2014-09-18 15:16:43 +02:00
parent 10576a8545
commit 9fc7ab9e0e
1 changed files with 1 additions and 16 deletions

View File

@ -1,18 +1,3 @@
#!/bin/sh
if [ "$(whoami)" != "portail-citoyen" ]; then
if which sudo; then
if sudo -v -u portail-citoyen; then
sudo -u portail-citoyen portail-citoyen-manage "$@"
exit $?
fi
echo "You must run this script with portail-citoyen user"
exit 1
fi
fi
if [ -f /etc/portail-citoyen/portail-citoyen2.conf ]; then
. /etc/portail-citoyen/portail-citoyen2.conf
fi
/usr/lib/portail-citoyen/manage.py "$@"
/etc/init.d/portail-citoyen2 manage "$@"