From 70623600744cab314baf1ccc912134456ffe565d Mon Sep 17 00:00:00 2001 From: lonkaars Date: Wed, 7 Feb 2024 10:57:17 +0100 Subject: add ifplugd config --- rootfs/etc/ifplugd/ifplugd.action | 9 +++++++++ 1 file changed, 9 insertions(+) create mode 100755 rootfs/etc/ifplugd/ifplugd.action (limited to 'rootfs/etc/ifplugd/ifplugd.action') diff --git a/rootfs/etc/ifplugd/ifplugd.action b/rootfs/etc/ifplugd/ifplugd.action new file mode 100755 index 0000000..05db65d --- /dev/null +++ b/rootfs/etc/ifplugd/ifplugd.action @@ -0,0 +1,9 @@ +#!/bin/sh -e +INTERFACE="$1" +NEW_STATE="$2" + +test -n "$INTERFACE" +test -n "$NEW_STATE" + +[ "$NEW_STATE" = "up" ] && exec ifup "$INTERFACE" +[ "$NEW_STATE" = "down" ] && exec ifdown "$INTERFACE" -- cgit v1.2.3