aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'defaults/udhcpc.scripts')
-rw-r--r--defaults/udhcpc.scripts17
1 files changed, 17 insertions, 0 deletions
diff --git a/defaults/udhcpc.scripts b/defaults/udhcpc.scripts
new file mode 100644
index 0000000..a108a8b
--- /dev/null
+++ b/defaults/udhcpc.scripts
@@ -0,0 +1,17 @@
+#!/bin/sh
+
+case ${1} in
+ bound)
+ [ -n "$broadcast" ] && BROADCAST="broadcast $broadcast"
+ [ -n "$subnet" ] && NETMASK="netmask $subnet"
+ [ -n "$rootpath" ] && echo "$rootpath" > /rootpath
+ #[ -n "$router" ] && echo "$router" > /router
+ #[ -n "$dns" ] && echo "$dns" > /dns
+
+ busybox ifconfig $interface $ip $BROADCAST $NETMASK
+ ;;
+ deconfig)
+ busybox ifconfig $interface 0.0.0.0
+ ;;
+esac
+