blob: a4e78d276598ae7044595da16632e8fc659bc920 (
plain)
- control:
- AddInstallable = ( dhcpd_reload )
-
- editfiles:
- { /etc/init.d/dhcp
- #
- # First of all, this is a DHCP server so let's make it possible
- # for DHCP to start.
- #
- LocateLineMatching "^run_dhcpd=.*"
- BeginGroupIfNoLineMatching '^run_dhcpd=1'
- ReplaceLineWith 'run_dhcpd=1'
- EndGroup
- DefineClasses "dhcpd_reload"
- }
- { /etc/dhcpd.conf
- #
- # We don't make the dhcp.conf dynamically, but instead we copy the contents
- # of a master file, but only if it's newer than the one installed.
- #
- BeginGroupIfFileIsNewer "/etc/local-COMMON/dhcpd.conf.$(site)"
- AutoCreate
- EmptyEntireFilePlease
- InsertFile "/etc/local-COMMON/dhcpd.conf.$(site)"
- Append "# Edited by cfengine $(date)"
- EndGroup
- DefineClasses "dhcpd_reload"
- }
- processes:
- "dhcpd-2.2.x" restart "/etc/init.d/dhcp restart"
- shellcommands:
- dhcpd_reload::
- "/etc/init.d/dhcp force-reload"
|