Merge "Add Fedora DHCP interfaces via udev rules"
This commit is contained in:
commit
b4e2968aea
@ -9,6 +9,5 @@ DIB_INIT_SYSTEM=$(dib-init-system)
|
|||||||
if [ "$DIB_INIT_SYSTEM" == "upstart" ]; then
|
if [ "$DIB_INIT_SYSTEM" == "upstart" ]; then
|
||||||
install -D -g root -o root -m 0755 ${SCRIPTDIR}/dhcp-all-interfaces.conf /etc/init/dhcp-all-interfaces.conf
|
install -D -g root -o root -m 0755 ${SCRIPTDIR}/dhcp-all-interfaces.conf /etc/init/dhcp-all-interfaces.conf
|
||||||
elif [ "$DIB_INIT_SYSTEM" == "systemd" ]; then
|
elif [ "$DIB_INIT_SYSTEM" == "systemd" ]; then
|
||||||
install -D -g root -o root -m 0755 ${SCRIPTDIR}/dhcp-all-interfaces.service /usr/lib/systemd/system/dhcp-all-interfaces.service
|
install -D -g root -o root -m 0644 ${SCRIPTDIR}/udev.rules /etc/udev/rules.d/99-dhcp-all-interfaces.rules
|
||||||
systemctl enable dhcp-all-interfaces.service
|
|
||||||
fi
|
fi
|
||||||
|
@ -1,14 +0,0 @@
|
|||||||
[Unit]
|
|
||||||
Description=DHCP All Interfaces Service
|
|
||||||
Wants=local-fs.target systemd-udev-settle.service
|
|
||||||
After=local-fs.target systemd-udev-settle.service
|
|
||||||
Before=network.service
|
|
||||||
|
|
||||||
[Service]
|
|
||||||
Type=oneshot
|
|
||||||
ExecStart=/usr/local/sbin/dhcp-all-interfaces.sh
|
|
||||||
RemainAfterExit=yes
|
|
||||||
|
|
||||||
[Install]
|
|
||||||
WantedBy=multi-user.target
|
|
||||||
Alias=dhcp-all-interfaces.service
|
|
1
elements/dhcp-all-interfaces/install.d/udev.rules
Normal file
1
elements/dhcp-all-interfaces/install.d/udev.rules
Normal file
@ -0,0 +1 @@
|
|||||||
|
SUBSYSTEM=="net", ACTION=="add", RUN+="/usr/local/sbin/dhcp-all-interfaces.sh $name", RUN+="/sbin/ifup $name"
|
Loading…
Reference in New Issue
Block a user