openvpn: add generic hotplug mechanism
[openwrt/openwrt.git] / package / network / services / openvpn / files / usr / libexec / openvpn-hotplug
diff --git a/package/network/services/openvpn/files/usr/libexec/openvpn-hotplug b/package/network/services/openvpn/files/usr/libexec/openvpn-hotplug
new file mode 100644 (file)
index 0000000..9235fba
--- /dev/null
@@ -0,0 +1,10 @@
+#!/bin/sh
+
+ACTION=$1
+shift
+INSTANCE=$1
+shift
+
+export ACTION=$ACTION
+export INSTANCE=$INSTANCE
+exec /sbin/hotplug-call openvpn "$@"