Skip to content

Commit

Permalink
ifupdown2-hotplug: add/remove filter hotplug itf
Browse files Browse the repository at this point in the history
  • Loading branch information
sohorx committed Jun 13, 2023
1 parent fb4b9c1 commit 56be5ec
Showing 1 changed file with 10 additions and 2 deletions.
12 changes: 10 additions & 2 deletions debian/ifupdown2-hotplug
Original file line number Diff line number Diff line change
Expand Up @@ -51,12 +51,20 @@ net_ifup() {

wait_for_interface lo

exec ifup --allow=hotplug $INTERFACE
if $(ifquery -l --allow=hotplug 2>/dev/null | grep -w -q "^$INTERFACE$"); then
exec ifup $INTERFACE --systemd
else
mesg "NET $INTERFACE not a hotplug interface"
fi
}

net_ifdown() {

exec ifdown --allow=hotplug $INTERFACE
if $(ifquery -l --allow=hotplug 2>/dev/null | grep -w -q "^$INTERFACE$"); then
exec ifdown $INTERFACE --systemd
else
mesg "NET $INTERFACE not a hotplug interface"
fi
}

do_everything() {
Expand Down

0 comments on commit 56be5ec

Please sign in to comment.