In work done to the isc-dhcp package under bug 1049177 I modified the apparmor profile to have '#include <dhcpd.d>', allowing packages to install extensions to the base profile into package specific files in /etc/apparmor.d/dhcpd.d .
This packaging change adds a file there that should allow maas to run a dhcpd with a command line similar to:
dhcpd -d -user dhcpd -group dhcpd -f -4 \
-pf /run/maas/dhcp/dhcpd.pid -cf /etc/maas/dhcpd.conf \
-lf /run/maas/dhcp/dhcpd.leases
I've tested that the given profile allows running of the above, but it is a bit tricky to get right. I've put a script that creates correct permissions at [1]. That is largely modelled after the upstart job in /etc/init/isc-dhcpd-server .
Note also that still to be done here is to install the upstart job. There is probably some packaging changes needed to get the upstart job into the maas-dhcp package. I believe that Jeroen's intent was to have trunk install /etc/init/maas-dhcp.conf but we'll need to pick that file into the maas-dhcp package still.
In work done to the isc-dhcp package under bug 1049177 I modified the apparmor profile to have '#include <dhcpd.d>', allowing packages to install extensions to the base profile into package specific files in /etc/apparmor. d/dhcpd. d .
This packaging change adds a file there that should allow maas to run a dhcpd with a command line similar to: dhcp/dhcpd. pid -cf /etc/maas/ dhcpd.conf \ dhcp/dhcpd. leases
dhcpd -d -user dhcpd -group dhcpd -f -4 \
-pf /run/maas/
-lf /run/maas/
I've tested that the given profile allows running of the above, but it is a bit tricky to get right. I've put a script that creates correct permissions at [1]. That is largely modelled after the upstart job in /etc/init/ isc-dhcpd- server .
Note also that still to be done here is to install the upstart job. There is probably some packaging changes needed to get the upstart job into the maas-dhcp package. I believe that Jeroen's intent was to have trunk install /etc/init/ maas-dhcp. conf but we'll need to pick that file into the maas-dhcp package still.
-- paste.ubuntu. com/1201622/
[1] http://