update debian for the new settings system
This commit is contained in:
parent
614aa1ed5c
commit
c308fbe46b
4
init.d
4
init.d
|
@ -18,6 +18,7 @@ PID_DIR=/var/run/mandaye-cud
|
|||
PIDFILE=/var/run/mandaye-cud/$NAME.pid
|
||||
LOG_DIR=/var/log/mandaye-cud
|
||||
SCRIPTNAME=/etc/init.d/$NAME
|
||||
MANDAYE_CONFIG_FILES=/etc/$NAME/config.ini
|
||||
|
||||
USER=mandaye-cud
|
||||
GROUP=mandaye-cud
|
||||
|
@ -49,6 +50,9 @@ mandaye_cud.wsgi:application"
|
|||
# Depend on lsb-base (>= 3.0-6) to ensure that this file is present.
|
||||
. /lib/lsb/init-functions
|
||||
|
||||
# environment for wsgi & settings
|
||||
export MANDAYE_CONFIG_FILES
|
||||
|
||||
#
|
||||
# Function that starts the daemon/service
|
||||
#
|
||||
|
|
1
install
1
install
|
@ -1 +1,2 @@
|
|||
debian/config.ini /etc/mandaye-cud/
|
||||
debian/mandaye_cud_manager /usr/bin/
|
||||
|
|
|
@ -0,0 +1,22 @@
|
|||
#!/bin/sh
|
||||
|
||||
NAME=mandaye-cud
|
||||
MANAGER="/usr/lib/$NAME/manager.py --config=/etc/$NAME/config.ini"
|
||||
|
||||
# check user
|
||||
if test x$1 = x"--forceuser"
|
||||
then
|
||||
shift
|
||||
elif test $(id -un) != "$NAME"
|
||||
then
|
||||
echo "error: must use $0 with user ${NAME}"
|
||||
exit 1
|
||||
fi
|
||||
|
||||
if test $# -eq 0
|
||||
then
|
||||
python ${MANAGER} --help
|
||||
exit 1
|
||||
fi
|
||||
|
||||
python ${MANAGER} "$@"
|
Reference in New Issue