Merge lp:~smoser/maas/packaging.1231693 into lp:~maas-maintainers/maas/packaging

Proposed by Scott Moser
Status: Merged
Approved by: Andres Rodriguez
Approved revision: 204
Merged at revision: 204
Proposed branch: lp:~smoser/maas/packaging.1231693
Merge into: lp:~maas-maintainers/maas/packaging
Diff against target: 55 lines (+9/-12)
2 files modified
debian/control (+1/-1)
debian/maas-dhcp.maas-dhcp-server.upstart (+8/-11)
To merge this branch: bzr merge lp:~smoser/maas/packaging.1231693
Reviewer Review Type Date Requested Status
Andres Rodriguez (community) Approve
Launchpad code reviewers Pending
Review via email: mp+188932@code.launchpad.net

Commit message

revert maas-dhcp-server upstart job to quantal-behavior-only.

This knowingly stops saucy level packages from running with
isc-dhcpd-server from precise. That is intended because we are more
interested in supporting isc-dhcpd-server from the cloud-archive which
will be a newer version.

Description of the change

One of these 2 branches can be chosen. Either
a.
https://code.launchpad.net/~smoser/maas/packaging.1231693-2/+merge/188967
or
https://code.launchpad.net/~smoser/maas/packaging.1231693/+merge/188932

I'm really OK with either. One is more complex but supports more scenarios
the other (this one) is a simpler upstart job that only supports one version of isc-dhcp (quantal-saucy version).

To post a comment you must log in.
Revision history for this message
Andres Rodriguez (andreserl) wrote :

This lgtm! Provided that the backport to precise is no longer going to use the DHCP from precise (but rather a backported one) then I approve these changes.

review: Approve
Revision history for this message
MAAS Lander (maas-lander) wrote :

No commit message specified.

Revision history for this message
Julian Edwards (julian-edwards) wrote :

On 04/10/13 00:05, Andres Rodriguez wrote:
> This knowingly stops saucy level packages from running with
> isc-dhcpd-server from precise. That is intended because we are more
> interested in supporting isc-dhcpd-server from the cloud-archive which
> will be a newer version.

The tests in the QA lab will need to be fixed to use the cloud archive now.

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1=== modified file 'debian/control'
2--- debian/control 2013-10-02 19:37:31 +0000
3+++ debian/control 2013-10-02 21:37:27 +0000
4@@ -249,7 +249,7 @@
5
6 Package: maas-dhcp
7 Architecture: all
8-Depends: isc-dhcp-server, ${misc:Depends}
9+Depends: isc-dhcp-server (>= 4.2.4), ${misc:Depends}
10 Breaks: maas-dhcp (<= 0.1+bzr777+dfsg-0ubuntu1)
11 Replaces: maas-dhcp (<= 0.1+bzr777+dfsg-0ubuntu1)
12 Description: Ubuntu MAAS Server - DHCP Configuration (meta-package)
13
14=== modified file 'debian/maas-dhcp.maas-dhcp-server.upstart'
15--- debian/maas-dhcp.maas-dhcp-server.upstart 2013-05-21 13:17:57 +0000
16+++ debian/maas-dhcp.maas-dhcp-server.upstart 2013-10-02 21:37:27 +0000
17@@ -37,7 +37,6 @@
18
19 respawn
20 script
21- RELEASE=`lsb_release --codename --short`
22 INTERFACES=`cat "${INTERFACES_FILE}"`
23
24 # Allow dhcp server to write lease and pid file.
25@@ -47,22 +46,20 @@
26 # As of Quantal, the leases file must be owned by root:root (even though
27 # the daemon will run under an unprivileged user).
28 # In Precise, ownership was supposed to be dhcpd:dhcpd.
29+ #
30+ # maas packages on saucy are only supported with newer isc-dhcp via
31+ # the cloud-archive. See bug 1231693 for more information, including
32+ # a patch that would actually work to support all, but is complex.
33+
34 mkdir -p $LEASES_DIR
35- if [ "$RELEASE" = "precise" ]; then
36- owner_group="dhcpd:dhcpd"
37- dhcpd_owner_opts=""
38- else
39- owner_group="root:root"
40- dhcpd_owner_opts="-user dhcpd -group dhcpd"
41- fi
42- chown $owner_group $LEASES_DIR
43+ chown root:root $LEASES_DIR
44 [ -e $LEASES_FILE ] || touch $LEASES_FILE
45 for LFILE in $LEASES_FILE $LEASES_FILE~; do
46 if [ -e $LFILE ]; then
47- chown $owner_group $LFILE
48+ chown root:root $LFILE
49 chmod a+r $LFILE
50 fi
51 done
52
53- exec /usr/sbin/dhcpd ${dhcpd_owner_opts} -f -q -4 -pf $PID_FILE -cf $CONFIG_FILE -lf $LEASES_FILE $INTERFACES
54+ exec /usr/sbin/dhcpd -user dhcpd -group dhcpd -f -q -4 -pf $PID_FILE -cf $CONFIG_FILE -lf $LEASES_FILE $INTERFACES
55 end script

Subscribers

People subscribed via source and target branches