#!/bin/bash
export LC_ALL=C
# restart dhcpd whenever $1 interface is brought up by NM (rhbz #565921)
if [ "$2" = "up" ]; then
# exit if the service is not configured to be started in the current runlevel
/bin/systemctl is-enabled dhcpd.service || exit 0
# restart service
/bin/systemctl restart dhcpd.service || :
fi