large init script cleanup and merge of whiterussian changes, new dnsmasq config handling
[openwrt.git] / package / ez-ipupdate / files / ez-ipupdate.hotplug
index 3f27c14..c305458 100644 (file)
@@ -1 +1,10 @@
-[ "$ACTION" = "ifup" -a "$INTERFACE" = "wan" ] && /usr/sbin/ez-ipupdate -c /etc/ez-ipupdate.conf &
+NAME=ez-ipupdate
+CONFIG=/etc/$NAME.conf
+COMMAND=/usr/sbin/$NAME
+
+[ "$ACTION" = "ifup" -a "$INTERFACE" = "wan" ] && {
+        [ -x $COMMAND ] && [ -r $CONFIG ] && {
+                eval "ifname=\"\${${INTERFACE}_ifname}\""
+                $COMMAND -c $CONFIG -i $ifname 2>&1 | logger -t $NAME
+        } &
+}
This page took 0.02802 seconds and 4 git commands to generate.