Use new mandaye configuration
This commit is contained in:
parent
113a39d82c
commit
34240a600f
2
control
2
control
|
@ -10,7 +10,7 @@ Package: mandaye-cam
|
|||
Architecture: all
|
||||
Depends: ${misc:Depends}, ${python:Depends}, memcached,
|
||||
python-memcache, python-raven, python-crypto, python-lasso,
|
||||
python-mandaye (>= 0.8)
|
||||
python-mandaye (>= 0.10)
|
||||
Recommends: python-raven, nginx
|
||||
Description: CAM is a Mandaye project, modular reverse proxy to authentic
|
||||
|
||||
|
|
1
dirs
1
dirs
|
@ -6,4 +6,5 @@ var/lib/mandaye-cam/data
|
|||
var/lib/mandaye-cam/sessions
|
||||
var/run/mandaye-cam
|
||||
var/log/mandaye-cam
|
||||
usr/lib/mandaye-cam
|
||||
usr/share/mandaye-cam
|
||||
|
|
4
init.d
4
init.d
|
@ -18,6 +18,7 @@ PID_DIR=/var/run/mandaye-cam
|
|||
PIDFILE=/var/run/mandaye-cam/$NAME.pid
|
||||
LOG_DIR=/var/log/mandaye-cam
|
||||
SCRIPTNAME=/etc/init.d/$NAME
|
||||
MANDAYE_CONFIG_FILES=/etc/$NAME/config.ini
|
||||
|
||||
USER=mandaye-cam
|
||||
GROUP=mandaye-cam
|
||||
|
@ -49,6 +50,9 @@ cam.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-cam/
|
||||
debian/mandaye_cam_manager /usr/bin/
|
||||
|
|
|
@ -0,0 +1,22 @@
|
|||
#!/bin/sh
|
||||
|
||||
NAME=mandaye-cam
|
||||
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} "$@"
|
2
postinst
2
postinst
|
@ -33,7 +33,7 @@ case "$1" in
|
|||
|
||||
if [ -z "$2" ]; then
|
||||
echo -n "Creating database.."
|
||||
su $USER -p -c "/usr/bin/cam_mandaye_manager --createdb"
|
||||
su $USER -p -c "/usr/bin/mandaye_cud_manager --createdb"
|
||||
echo "..done"
|
||||
fi
|
||||
;;
|
||||
|
|
6
rules
6
rules
|
@ -6,5 +6,7 @@ BUILD_DIR := 'debian/mandaye-cam'
|
|||
dh $@ --with python2
|
||||
|
||||
override_dh_install:
|
||||
dh_install
|
||||
cp -R cam/static $(BUILD_DIR)/usr/share/mandaye-cam
|
||||
dh_install
|
||||
mv $(BUILD_DIR)/usr/bin/server.py $(BUILD_DIR)/usr/lib/mandaye-cam/server.py
|
||||
mv $(BUILD_DIR)/usr/bin/manager.py $(BUILD_DIR)/usr/lib/mandaye-cam/manager.py
|
||||
cp -R cam/static $(BUILD_DIR)/usr/share/mandaye-cam
|
||||
|
|
Reference in New Issue