mirror of
https://abf.rosa.ru/djam/dhcp.git
synced 2025-02-23 13:32:48 +00:00

They can be used while booting a minimal system without /usr. They do not depend from anything in /usr, except locales.
23 lines
717 B
Desktop File
23 lines
717 B
Desktop File
[Unit]
|
|
Description=dhclient on %I
|
|
Wants=network.target
|
|
Before=network.target
|
|
|
|
[Service]
|
|
ExecStart=/sbin/dhclient -lf /var/lib/dhclient/dhclient.leases -pf /run/dhclient@%i/dhclient.pid -d %I
|
|
RuntimeDirectory=dhclient@%i
|
|
# https://www.freedesktop.org/software/systemd/man/systemd.exec.html#ProtectSystem=
|
|
# /var is not read-only
|
|
ProtectSystem=true
|
|
ProtectHome=true
|
|
RestartSec=2s
|
|
Restart=on-failure
|
|
AmbientCapabilities=CAP_NET_BIND_SERVICE CAP_NET_RAW
|
|
# https://www.freedesktop.org/software/systemd/man/systemd.exec.html#ReadWritePaths=
|
|
CapabilityBoundingSet=~CAP_SYS_ADMIN
|
|
|
|
[Install]
|
|
WantedBy=multi-user.target
|
|
|
|
# This unit file in based on
|
|
# https://git.archlinux.org/svntogit/packages.git/tree/trunk?h=packages/dhcp
|