summaryrefslogtreecommitdiffstats
path: root/debian
diff options
context:
space:
mode:
Diffstat (limited to 'debian')
-rwxr-xr-xdebian/bcfg2-server.bcfg2-report-collector.init (renamed from debian/bcfg2-report-collector.init)9
-rwxr-xr-xdebian/bcfg2-server.init12
-rwxr-xr-xdebian/bcfg2.cron.daily2
-rwxr-xr-xdebian/bcfg2.cron.hourly2
-rwxr-xr-xdebian/bcfg2.init9
-rw-r--r--debian/control13
-rwxr-xr-xdebian/rules16
7 files changed, 38 insertions, 25 deletions
diff --git a/debian/bcfg2-report-collector.init b/debian/bcfg2-server.bcfg2-report-collector.init
index 2d182385a..df7b751cb 100755
--- a/debian/bcfg2-report-collector.init
+++ b/debian/bcfg2-server.bcfg2-report-collector.init
@@ -32,6 +32,7 @@ test -x $DAEMON || exit 5
# Internal variables
BINARY=$(basename $DAEMON)
+RETVAL=0
start () {
echo -n "Starting Configuration Report Collector: "
@@ -85,22 +86,26 @@ status () {
case "$1" in
start)
start
+ RETVAL=$?
;;
stop)
stop
+ RETVAL=$?
;;
status)
status
+ RETVAL=$?
;;
restart|reload|force-reload)
stop
sleep 5
start
+ RETVAL=$?
;;
*)
log_success_msg "Usage: $0 {start|stop|status|reload|restart|force-reload}"
- exit 1
+ RETVAL=1
;;
esac
-exit 0
+exit $RETVAL
diff --git a/debian/bcfg2-server.init b/debian/bcfg2-server.init
index 8de16b9b5..b1c3aba21 100755
--- a/debian/bcfg2-server.init
+++ b/debian/bcfg2-server.init
@@ -17,7 +17,8 @@
### END INIT INFO
# Include lsb functions
-. /lib/lsb/init-functions
+test -f "/lib/lsb/init-functions" && . /lib/lsb/init-functions # debian
+test -f "/etc/init.d/functions" && . /etc/init.d/functions # redhat
# Commonly used stuff
DAEMON=/usr/sbin/bcfg2-server
@@ -41,6 +42,7 @@ test -x $DAEMON || exit 5
# Internal variables
BINARY=$(basename $DAEMON)
+RETVAL=0
start () {
echo -n "Starting Configuration Management Server: "
@@ -91,22 +93,26 @@ status () {
case "$1" in
start)
start
+ RETVAL=$?
;;
stop)
stop
+ RETVAL=$?
;;
status)
status
+ RETVAL=$?
;;
restart|reload|force-reload)
stop
sleep 5
start
+ RETVAL=$?
;;
*)
log_success_msg "Usage: $0 {start|stop|status|reload|restart|force-reload}"
- exit 1
+ RETVAL=1
;;
esac
-exit 0
+exit $RETVAL
diff --git a/debian/bcfg2.cron.daily b/debian/bcfg2.cron.daily
index f2d1efb9f..b872887cb 100755
--- a/debian/bcfg2.cron.daily
+++ b/debian/bcfg2.cron.daily
@@ -10,4 +10,4 @@ else
echo "No bcfg2-cron command found"
exit 1
fi
-$BCFG2CRON --daily 2>&1 | logger -t bcfg2-cron -p daemon.info
+$BCFG2CRON --daily 2>&1 | logger -t bcfg2-cron -p daemon.info -i
diff --git a/debian/bcfg2.cron.hourly b/debian/bcfg2.cron.hourly
index 73aae7606..9f666e083 100755
--- a/debian/bcfg2.cron.hourly
+++ b/debian/bcfg2.cron.hourly
@@ -10,4 +10,4 @@ else
echo "No bcfg2-cron command found"
exit 1
fi
-$BCFG2CRON --hourly 2>&1 | logger -t bcfg2-cron -p daemon.info
+$BCFG2CRON --hourly 2>&1 | logger -t bcfg2-cron -p daemon.info -i
diff --git a/debian/bcfg2.init b/debian/bcfg2.init
index 4f83adbf6..b2e47b346 100755
--- a/debian/bcfg2.init
+++ b/debian/bcfg2.init
@@ -47,6 +47,7 @@ fi
# Internal variables
BINARY=$(basename $BCFG2)
+RETVAL=0
# Include lsb functions
. /lib/lsb/init-functions
@@ -70,17 +71,19 @@ start () {
case "$1" in
start)
start
+ RETVAL=$?
;;
stop|status)
- exit 0
+ RETVAL=0
;;
restart|force-reload)
start
+ RETVAL=$?
;;
*)
echo "Usage: $0 {start|stop|status|restart|force-reload}"
- exit 1
+ RETVAL=1
;;
esac
-exit 0
+exit $RETVAL
diff --git a/debian/control b/debian/control
index 6c7278e4e..7b27b27ed 100644
--- a/debian/control
+++ b/debian/control
@@ -4,25 +4,26 @@ Priority: optional
Maintainer: Arto Jantunen <viiru@debian.org>
Uploaders: Sami Haahtinen <ressu@debian.org>
Build-Depends: debhelper (>= 7.0.50~),
- python (>= 2.3.5-7),
+ python (>= 2.6),
python-setuptools,
python-sphinx (>= 1.0.7+dfsg) | python3-sphinx,
python-lxml,
python-daemon,
python-cherrypy,
+ python-gamin,
+ python-genshi,
python-pyinotify,
python-m2crypto,
python-doc,
+ python-mock,
python-mock-doc
Build-Depends-Indep: python-support (>= 0.5.3)
Standards-Version: 3.8.0.0
-XS-Python-Version: >= 2.3
Homepage: http://bcfg2.org/
Package: bcfg2
Architecture: all
-Depends: ${python:Depends}, ${misc:Depends}, debsums, python-apt, ucf, lsb-base (>= 3.1-9), python-m2crypto | python-ssl | python2.6 | python3.0 | python3.1 | python3.2
-XB-Python-Version: >= 2.3
+Depends: ${python:Depends}, ${misc:Depends}, debsums, python-apt, ucf, lsb-base (>= 3.1-9), python (>= 2.6)
Description: Configuration management client
Bcfg2 is a configuration management system that generates configuration sets
for clients bound by client profiles.
@@ -31,8 +32,7 @@ Description: Configuration management client
Package: bcfg2-server
Architecture: all
-Depends: ${python:Depends}, ${misc:Depends}, python-lxml (>= 0.9), libxml2-utils (>= 2.6.23), lsb-base (>= 3.1-9), ucf, bcfg2 (= ${binary:Version}), openssl, python-ssl | python2.6 | python3.0 | python3.1 | python3.2, python-pyinotify | python-gamin, python-daemon
-XB-Python-Version: >= 2.4
+Depends: ${python:Depends}, ${misc:Depends}, python-lxml (>= 0.9), libxml2-utils (>= 2.6.23), lsb-base (>= 3.1-9), ucf, bcfg2 (= ${binary:Version}), openssl, python (>= 2.6), python-pyinotify | python-gamin, python-daemon
Recommends: graphviz, patch
Suggests: python-cheetah, python-genshi (>= 0.4.4), python-profiler, python-sqlalchemy (>= 0.5.0), python-django, mail-transport-agent, bcfg2-doc (= ${binary:Version})
Description: Configuration management server
@@ -45,7 +45,6 @@ Package: bcfg2-web
Architecture: all
Depends: ${python:Depends}, ${misc:Depends}, bcfg2-server (= ${binary:Version}), python-django,
Suggests: python-mysqldb, python-psycopg2, python-sqlite, libapache2-mod-wsgi
-XB-Python-Version: >= 2.4
Description: Configuration management web interface
Bcfg2 is a configuration management system that generates configuration sets
for clients bound by client profiles.
diff --git a/debian/rules b/debian/rules
index fcbf6346c..eaf80a4d7 100755
--- a/debian/rules
+++ b/debian/rules
@@ -1,20 +1,20 @@
#!/usr/bin/make -f
-%:
- dh $@ --with python-support,sphinxdoc
+# Lucid does not have dh_python2, but we would like to be able to use
+# this rules file to build on lucid as well.
+WITH_PYTHON2 = $(shell test -f /usr/bin/dh_python2 && echo "--with python2")
+WITH_SPHINXDOC = $(shell test -f /usr/bin/dh_sphinxdoc && echo "--with sphinxdoc")
-override_dh_auto_install:
- # Make the build destination dir consistent between pre-7.3 and 7.3 and
- # later debhelper - see http://bcfg2.org/ticket/791
- dh_auto_install
- test -d debian/tmp/usr/local && mv debian/tmp/usr/local/* debian/tmp/usr || exit 0
- test -d debian/tmp/usr/local && rmdir debian/tmp/usr/local || exit 0
+%:
+ dh $@ ${WITH_PYTHON2} ${WITH_SPHINXDOC}
override_dh_installinit:
# Install bcfg2 initscript without starting it on postinst
dh_installinit --package=bcfg2 --no-start
# Install bcfg2-server initscript without starting it on postinst
dh_installinit --package=bcfg2-server --no-start
+ # Install bcfg2-report-collector initscript without starting it on postinst
+ dh_installinit --package=bcfg2-server --name=bcfg2-report-collector --no-start
override_dh_auto_build:
dh_auto_build