Changeset 256

Show
Ignore:
Timestamp:
03/14/07 18:52:05 (2 years ago)
Author:
florida
Message:

Choix automatique de la variable ExternalInterface?

Files:

Legend:

Unmodified
Added
Removed
Modified
Copied
Moved
  • wifidog/wifidog-client/scripts/openwrt/S65wifidog

    r250 r256  
    1616WD_DIR=/usr/bin 
    1717OPTIONS="-c /var/etc/wifidog.conf" 
     18case $(nvram get wan_proto) in 
     19        pppoe) 
     20                ext_int=ppp0 
     21                ;; 
     22        static) 
     23                ext_int=$(nvram get wan_ifname) 
     24                ;; 
     25        dhcp) 
     26                ext_int=$(nvram get wan_ifname) 
     27                ;; 
     28        *) 
     29                com=# 
     30                ;;       
     31esac 
    1832long=$(echo $(nvram get ff_adm_gps) | sed -e "s/\(.+\);\(.+\)/\1/") 
    1933lat=$(echo $(nvram get ff_adm_gps) | sed -e "s/\(.+\);\(.+\)/\2/") 
     
    4862# Set this to the external interface.  Typically vlan1 for OpenWrt, and eth0 or ppp0 otherwise 
    4963 
    50 ExternalInterface vlan1 
     64${com}ExternalInterface $ext_int 
    5165 
    5266# Parameter: GatewayInterface