[Pkg-ceph-commits] [ceph] 02/08: d/rules,*.{postinst,prerm}: Drop install and management of upstart configuration files; this package version onwards will only ever target >= Xenial, which is a systemd baseline.

James Downing Page jamespage at moszumanska.debian.org
Thu Jul 14 09:52:14 UTC 2016


This is an automated email from the git hooks/post-receive script.

jamespage pushed a commit to branch ubuntu-yakkety
in repository ceph.

commit 71ac7c1c0ccfd0815d6fdc88c2b35758b018274a
Author: James Page <james.page at ubuntu.com>
Date:   Fri Jul 8 10:14:10 2016 +0100

    d/rules,*.{postinst,prerm}: Drop install and management of upstart configuration files; this package version onwards will only ever target >= Xenial, which is a systemd baseline.
---
 debian/ceph-base.postinst |  8 --------
 debian/ceph-base.prerm    |  8 --------
 debian/ceph-mds.postinst  |  8 --------
 debian/ceph-mds.prerm     |  8 --------
 debian/ceph-mon.postinst  |  2 +-
 debian/ceph-mon.prerm     |  1 -
 debian/ceph-osd.postinst  |  2 +-
 debian/ceph-osd.prerm     |  1 -
 debian/changelog          |  3 +++
 debian/radosgw.postinst   | 14 --------------
 debian/radosgw.prerm      |  8 --------
 debian/rules              | 42 ++++++++++--------------------------------
 12 files changed, 15 insertions(+), 90 deletions(-)

diff --git a/debian/ceph-base.postinst b/debian/ceph-base.postinst
index b280af9..23712a8 100644
--- a/debian/ceph-base.postinst
+++ b/debian/ceph-base.postinst
@@ -31,14 +31,6 @@ set -e
 case "$1" in
 	configure)
 		rm -f /etc/init/ceph.conf
-		if [ -x /sbin/start ]; then
-			invoke-rc.d ceph-all start || {
-				RESULT=$?
-				if [ $RESULT != 100 ]; then
-					exit $RESULT
-				fi
-			}
-		fi
 		for DIR in `ls -1 /var/lib/ceph` ; do
 		    if ! dpkg-statoverride --list /var/lib/ceph/$DIR >/dev/null; then
 			if [ -d /run/systemd/system ] && [ $DIR = 'mon' ]; then
diff --git a/debian/ceph-base.prerm b/debian/ceph-base.prerm
index be7f715..e76715e 100644
--- a/debian/ceph-base.prerm
+++ b/debian/ceph-base.prerm
@@ -5,14 +5,6 @@ set -e
 
 case "$1" in
 	remove)
-		if [ -x /sbin/stop ]; then
-			invoke-rc.d ceph-all stop || {
-				RESULT=$?
-				if [ $RESULT != 100 ]; then
-					exit $RESULT
-				fi
-			}
-		fi
 		invoke-rc.d ceph stop || {
 			RESULT=$?
 			if [ $RESULT != 100 ]; then
diff --git a/debian/ceph-mds.postinst b/debian/ceph-mds.postinst
index d1c586c..f6c9f4e 100644
--- a/debian/ceph-mds.postinst
+++ b/debian/ceph-mds.postinst
@@ -24,14 +24,6 @@ set -e
 
 case "$1" in
 	configure)
-		if [ -x /sbin/start ]; then
-			invoke-rc.d ceph-mds-all start || {
-				RESULT=$?
-				if [ $RESULT != 100 ]; then
-					exit $RESULT
-				fi
-			}
-		fi
 		if ! dpkg-statoverride --list /var/lib/ceph/mds >/dev/null; then
 			chown $SERVER_USER:$SERVER_GROUP /var/lib/ceph/mds
 		fi
diff --git a/debian/ceph-mds.prerm b/debian/ceph-mds.prerm
index e952a3f..7a491aa 100644
--- a/debian/ceph-mds.prerm
+++ b/debian/ceph-mds.prerm
@@ -5,14 +5,6 @@ set -e
 
 case "$1" in
 	remove)
-		if [ -x /sbin/stop ]; then
-			invoke-rc.d ceph-mds-all stop || {
-				RESULT=$?
-				if [ $RESULT != 100 ]; then
-					exit $RESULT
-				fi
-			}
-		fi
 		invoke-rc.d ceph stop mds || {
 			RESULT=$?
 			if [ $RESULT != 100 ]; then
diff --git a/debian/ceph-mon.postinst b/debian/ceph-mon.postinst
index b33f34b..4638a1a 100644
--- a/debian/ceph-mon.postinst
+++ b/debian/ceph-mon.postinst
@@ -23,7 +23,7 @@ set -e
 
 case "$1" in
     configure)
-	[ -x /sbin/start ] && start ceph-mon-all || :
+	:
     ;;
     abort-upgrade|abort-remove|abort-deconfigure)
 	:
diff --git a/debian/ceph-mon.prerm b/debian/ceph-mon.prerm
index 5f64058..a31fc3c 100644
--- a/debian/ceph-mon.prerm
+++ b/debian/ceph-mon.prerm
@@ -5,7 +5,6 @@ set -e
 
 case "$1" in
     remove)
-	[ -x /sbin/stop ] && stop ceph-mon-all || true
 	invoke-rc.d ceph stop mon || {
 	    RESULT=$?
 	    if [ $RESULT != 100 ]; then
diff --git a/debian/ceph-osd.postinst b/debian/ceph-osd.postinst
index b642dfe..d4ad405 100644
--- a/debian/ceph-osd.postinst
+++ b/debian/ceph-osd.postinst
@@ -23,7 +23,7 @@ set -e
 
 case "$1" in
     configure)
-	[ -x /sbin/start ] && start ceph-osd-all || :
+	:
     ;;
     abort-upgrade|abort-remove|abort-deconfigure)
 	:
diff --git a/debian/ceph-osd.prerm b/debian/ceph-osd.prerm
index 40f07b6..93c4596 100644
--- a/debian/ceph-osd.prerm
+++ b/debian/ceph-osd.prerm
@@ -5,7 +5,6 @@ set -e
 
 case "$1" in
     remove)
-	[ -x /sbin/stop ] && stop ceph-osd-all || true
 	invoke-rc.d ceph stop osd || {
 	    RESULT=$?
 	    if [ $RESULT != 100 ]; then
diff --git a/debian/changelog b/debian/changelog
index ac34166..8d6144c 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -5,6 +5,9 @@ ceph (10.2.2-0ubuntu2) UNRELEASED; urgency=medium
   * d/*: Split ceph-osd and ceph-mon into separate binary packages and add
     new ceph-base binary package inline with upstream packaging changes
     (LP: #1596063).
+  * d/rules,*.{postinst,prerm}: Drop install and management of upstart
+    configuration files; this package version onwards will only ever
+    target >= Xenial, which is a systemd baseline.
 
  -- James Page <james.page at ubuntu.com>  Thu, 30 Jun 2016 10:52:37 +0100
 
diff --git a/debian/radosgw.postinst b/debian/radosgw.postinst
index b886c05..fb352e4 100644
--- a/debian/radosgw.postinst
+++ b/debian/radosgw.postinst
@@ -30,14 +30,6 @@ set -e
 
 case "$1" in
     configure)
-	if [ -x /sbin/start ]; then
-	        invoke-rc.d radosgw-all start || {
-	            RESULT=$?
-	            if [ $RESULT != 100 ]; then
-	                exit $RESULT
-        	    fi
-	        }
-	fi
 	if ! dpkg-statoverride --list /var/lib/ceph/radosgw >/dev/null; then
 	    chown $SERVER_USER:$SERVER_GROUP /var/lib/ceph/radosgw
 	fi
@@ -52,12 +44,6 @@ case "$1" in
     ;;
 esac
 
-if dpkg-maintscript-helper supports mv_conffile 2>/dev/null; then
-    dpkg-maintscript-helper mv_conffile \
-        /etc/init/radosgw.conf /etc/init/radosgw-instance.conf \
-        0.72.1-3~ radosgw -- "$@"
-fi
-
 # dh_installdeb will replace this with shell code automatically
 # generated by other debhelper scripts.
 
diff --git a/debian/radosgw.prerm b/debian/radosgw.prerm
index baae241..0288ab7 100644
--- a/debian/radosgw.prerm
+++ b/debian/radosgw.prerm
@@ -5,14 +5,6 @@ set -e
 
 case "$1" in
     remove)
-	if [ -x /sbin/stop ]; then
-		invoke-rc.d radosgw-all stop || {
-	            RESULT=$?
-	            if [ $RESULT != 100 ]; then
-        	        exit $RESULT
-	            fi
-	        }
-	fi
 	invoke-rc.d radosgw stop || {
 	    RESULT=$?
 	    if [ $RESULT != 100 ]; then
diff --git a/debian/rules b/debian/rules
index 3f1c2f1..293a877 100755
--- a/debian/rules
+++ b/debian/rules
@@ -87,28 +87,6 @@ override_dh_auto_install:
 override_dh_installinit:
 	dh_installinit --no-start
 	dh_installinit -pceph-common --no-start --name=rbdmap
-	# Install upstart configurations using dh_installinit
-	for conf in `ls -1 src/upstart/ceph*.conf | grep -v mds`; do \
-        name=`basename $$conf | cut -d . -f 1`; \
-        cp -v $$conf debian/ceph.$$name.upstart; \
-        dh_installinit -pceph --no-start --name=$$name; \
-    done
-	for conf in `ls -1 src/upstart/ceph-mds*.conf`; do \
-        name=`basename $$conf | cut -d . -f 1`; \
-        cp -v $$conf debian/ceph-mds.$$name.upstart; \
-        dh_installinit -pceph-mds --no-start --name=$$name; \
-    done
-	for conf in `ls -1 src/upstart/radosgw*.conf`; do \
-        name=`basename $$conf | cut -d . -f 1`; \
-        [ $$name = "radosgw" ] && name="radosgw-instance";\
-        cp -v $$conf debian/radosgw.$$name.upstart; \
-        dh_installinit -pradosgw --no-start --name=$$name; \
-    done
-	for conf in `ls -1 src/upstart/ceph-rbd-mirror*.conf`; do \
-		name=`basename $$conf | cut -d . -f 1`; \
-		cp -v $$conf debian/rbd-mirror.$$name.upstart; \
-		dh_installinit -prbd-mirror --no-start --name=$$name; \
-	done
 	# install the systemd stuff manually since we have funny service names
 	# and need to update the paths in all of the files post install
 	# systemd:ceph-common
@@ -118,17 +96,17 @@ override_dh_installinit:
 	install -m 0644 -D systemd/ceph.tmpfiles.d debian/ceph-common/usr/lib/tmpfiles.d/ceph.conf
 	# systemd:ceph
 	install -d -m0755 debian/ceph/lib/systemd/system
-	install -m0644 systemd/ceph-mon at .service debian/ceph/lib/systemd/system
-	install -m0644 systemd/ceph-create-keys at .service debian/ceph/lib/systemd/system
-	install -m0644 systemd/ceph-osd at .service debian/ceph/lib/systemd/system
-	install -m0644 systemd/ceph-disk at .service debian/ceph/lib/systemd/system
-	sed -i s./etc/sysconfig/./etc/default/.g debian/ceph/lib/systemd/system/ceph-mon at .service
-	sed -i s./etc/sysconfig/./etc/default/.g debian/ceph/lib/systemd/system/ceph-create-keys at .service
-	sed -i s./etc/sysconfig/./etc/default/.g debian/ceph/lib/systemd/system/ceph-osd at .service
-	sed -i s./etc/sysconfig/./etc/default/.g debian/ceph/lib/systemd/system/ceph-disk at .service
+	install -m0644 systemd/ceph-mon at .service debian/ceph-mon/lib/systemd/system
+	install -m0644 systemd/ceph-create-keys at .service debian/ceph-base/lib/systemd/system
+	install -m0644 systemd/ceph-osd at .service debian/ceph-osd/lib/systemd/system
+	install -m0644 systemd/ceph-disk at .service debian/ceph-osd/lib/systemd/system
+	sed -i s./etc/sysconfig/./etc/default/.g debian/ceph-mon/lib/systemd/system/ceph-mon at .service
+	sed -i s./etc/sysconfig/./etc/default/.g debian/ceph-base/lib/systemd/system/ceph-create-keys at .service
+	sed -i s./etc/sysconfig/./etc/default/.g debian/ceph-osd/lib/systemd/system/ceph-osd at .service
+	sed -i s./etc/sysconfig/./etc/default/.g debian/ceph-osd/lib/systemd/system/ceph-disk at .service
 	# NOTE(jamespage): Install previous ceph-mon/create-keys service from packaging for upgrades
-	install -m0644 debian/lib-systemd/system/ceph-mon.service debian/ceph/lib/systemd/system
-	install -m0644 debian/lib-systemd/system/ceph-create-keys.service debian/ceph/lib/systemd/system
+	install -m0644 debian/lib-systemd/system/ceph-mon.service debian/ceph-mon/lib/systemd/system
+	install -m0644 debian/lib-systemd/system/ceph-create-keys.service debian/ceph-base/lib/systemd/system
 	# systemd:ceph-mds
 	install -d -m0755 debian/ceph-mds/lib/systemd/system
 	install -m0644 systemd/ceph-mds at .service debian/ceph-mds/lib/systemd/system

-- 
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-ceph/ceph.git



More information about the Pkg-ceph-commits mailing list