]> git.proxmox.com Git - drbd-utils.git/commitdiff
fix drbd.service, do not start/enable by default
authorDietmar Maurer <dietmar@proxmox.com>
Thu, 19 Mar 2015 11:31:38 +0000 (12:31 +0100)
committerDietmar Maurer <dietmar@proxmox.com>
Thu, 19 Mar 2015 11:31:38 +0000 (12:31 +0100)
debian/control
debian/patches/fix-drbd-path-in-systemd-service.patch [new file with mode: 0644]
debian/patches/series [new file with mode: 0644]
debian/rules

index 6f9c438cb789a3268e7cadcdbd1f188f36622895..ae6611592559904634d3d6371419c5a3e8325edb 100644 (file)
@@ -2,13 +2,13 @@ Source: drbd-utils
 Section: admin
 Priority: extra
 Maintainer: Proxmox Support Team <support@proxmox.com>
-Build-Depends: debhelper (>= 9), flex, xsltproc, docbook-xsl
+Build-Depends: debhelper (>= 9), flex, xsltproc, docbook-xsl, dh-systemd (>= 1.4)
 Standards-Version: 3.9.5
 Homepage: http://www.drbd.org
 
 Package: drbd-utils
 Architecture: linux-any
-Depends: debconf (>= 0.5), ${shlibs:Depends}, ${misc:Depends}, ${perl:Depends}
+Depends: debconf (>= 0.5), ${shlibs:Depends}, ${misc:Depends}, ${perl:Depends}, systemd
 Breaks: drbd8-utils (<< 2:8.9.0)
 Replaces: drbd8-utils (<< 2:8.9.0)
 Recommends: heirloom-mailx|mailx
diff --git a/debian/patches/fix-drbd-path-in-systemd-service.patch b/debian/patches/fix-drbd-path-in-systemd-service.patch
new file mode 100644 (file)
index 0000000..04632e8
--- /dev/null
@@ -0,0 +1,19 @@
+Index: new/scripts/drbd.service
+===================================================================
+--- new.orig/scripts/drbd.service
++++ new/scripts/drbd.service
+@@ -7,11 +7,11 @@ After=network.target sshd.service
+ Type=oneshot
+ RemainAfterExit=yes
+-ExecStart=/lib/drbd/drbd start
+-ExecStop=/lib/drbd/drbd stop
++ExecStart=/usr/lib/drbd/drbd start
++ExecStop=/usr/lib/drbd/drbd stop
+ # Re-adjust everything on reload
+-ExecReload=/lib/drbd/drbd reload
++ExecReload=/usr/lib/drbd/drbd reload
+ [Install]
+ WantedBy=multi-user.target
diff --git a/debian/patches/series b/debian/patches/series
new file mode 100644 (file)
index 0000000..6f8bf4e
--- /dev/null
@@ -0,0 +1 @@
+fix-drbd-path-in-systemd-service.patch
index 1cbb8d8a6c305bd097aa79cc8893b5a247f6e842..0e0b78747df19b97bf36e5e7cb17ae5fd1eeb8d0 100755 (executable)
@@ -6,7 +6,7 @@
 PKG_VERSION=$(shell dpkg-parsechangelog | awk '/^Version:/ { print $$2 }')
 
 %:
-       dh $@ --with=systemd
+       dh $@ --with=quilt,systemd
 
 override_dh_auto_clean:
        dh_auto_clean
@@ -20,6 +20,7 @@ override_dh_auto_configure:
        --sbindir=/usr/sbin                             \
        --without-83support                             \
        --without-84support                             \
+       --without-xen                                   \
        --with-distro debian                            \
        --with-udev                                     \
        --with-pacemaker                                \
@@ -33,13 +34,8 @@ override_dh_auto_install:
 override_dh_install:
        dh_install --fail-missing
 
-       # Place the initscript where dh_installinit can find it
-#      mv $(CURDIR)/debian/drbd-utils/etc/init.d/drbd $(CURDIR)/debian/drbd-utils.drbd.init
-       # Place the systemd service script ...
-#      mv $(CURDIR)/debian/drbd-utils/lib/systemd/system/drbd.service $(CURDIR)/debian
-
-override_dh_installinit:
-       dh_installinit --name=drbd --no-start
+override_dh_systemd_enable:
+       dh_systemd_enable --no-enable drbd.service
 
 override_dh_gencontrol:
        dh_gencontrol -Ndrbd8-utils