slitaz-boot-scripts annotate etc/init.d/wpa_action.sh @ rev 330

Added tag 5.3.1 for changeset 11d0305fa1c6
author Eric Joseph-Alexandre <erjo@slitaz.org>
date Thu Jan 17 19:14:14 2013 +0100 (2013-01-17)
parents 7512d6d48538
children 6c2d6362887d
rev   line source
jozee@188 1 #!/bin/sh
jozee@188 2 INTERFACE=$1
gokhlayeh@241 3
jozee@188 4 # For a dynamic IP with DHCP.
jozee@188 5 if [ "$2" = "CONNECTED" ]; then
gokhlayeh@241 6 [ -f /var/run/udhcpc.$INTERFACE.pid] && killall udhcpc
jozee@188 7 /sbin/udhcpc -b -i $INTERFACE -p /var/run/udhcpc.$INTERFACE.pid
jozee@188 8 elif [ "$2" = "DISCONNECTED" ]; then
jozee@188 9 /sbin/udhcpc -b -i $INTERFACE -p /var/run/udhcpc.$INTERFACE.pid
jozee@188 10 fi
jozee@188 11