dhcp: Add systemd unit file for dhclient

Signed-off-by: Khem Raj <raj.khem@gmail.com>
This commit is contained in:
Khem Raj
2012-10-29 17:26:45 -07:00
parent 087ecf88f4
commit 6f86cfec55
2 changed files with 18 additions and 2 deletions
@@ -0,0 +1,13 @@
[Unit]
Description=Dynamic Host Configuration Protocol (DHCP)
After=syslog.target network.target
[Service]
Type=forking
PIDFile=/var/run/dhclient.pid
EnvironmentFile=-/etc/default/dhcp-client
ExecStart=/sbin/dhclient -cf /etc/dhcp/dhclient.conf -q $INTERFACES -lf /var/lib/dhcp/dhclient.leases
[Install]
WantedBy=multi-user.target
@@ -5,9 +5,12 @@ inherit systemd
PRINC := "${@int(PRINC) + 1}"
SYSTEMD_PACKAGES = "dhcp-server-systemd dhcp-relay-systemd"
SYSTEMD_PACKAGES = "dhcp-server-systemd dhcp-relay-systemd dhcp-client-systemd"
SYSTEMD_SERVICE_dhcp-server-systemd = "dhcpd.service"
SYSTEMD_SERVICE_dhcp-relay-systemd = "dhcrelay.service"
SYSTEMD_SERVICE_dhcp-client-systemd = "dhclient.service"
SRC_URI += "file://dhcpd.service \
file://dhcrelay.service"
file://dhclient.service \
file://dhcrelay.service \
"