11 |
#%before: |
#%before: |
12 |
#%after: |
#%after: |
13 |
|
|
14 |
# $Header: /home/cvsd/alx-cvs/alx-src/tinyalxconfig-ng/init.d/alxsettings,v 1.10 2008-06-05 17:23:07 niro Exp $ |
# $Header: /home/cvsd/alx-cvs/alx-src/tinyalxconfig-ng/init.d/alxsettings,v 1.11 2008-06-05 17:23:38 niro Exp $ |
15 |
|
|
16 |
# checks first if the client was already configured and if it has an valid serial |
# checks first if the client was already configured and if it has an valid serial |
17 |
# if not it runs the autoconfiguration script |
# if not it runs the autoconfiguration script |
639 |
reboot |
reboot |
640 |
} |
} |
641 |
|
|
|
# read values from net.* files |
|
|
read_value() |
|
|
{ |
|
|
local var="$1" |
|
|
local file="$2" |
|
|
local value |
|
|
|
|
|
# local all possible vars |
|
|
# global |
|
|
local ONBOOT |
|
|
local NETWORKING |
|
|
|
|
|
# static |
|
|
local IP |
|
|
local NETMASK |
|
|
local BROADCAST |
|
|
local NETWORKING |
|
|
local FORCE_MAC_TO |
|
|
|
|
|
# dhcp |
|
|
local DHCP_PROG |
|
|
local DHCP_START |
|
|
local DHCP_STOP |
|
|
|
|
|
# default gw |
|
|
local GATEWAY |
|
|
local GATEWAY_IF |
|
|
|
|
|
# wireless extensions |
|
|
local WIRELESS_AP |
|
|
local WIRELESS_AUTH_MODE |
|
|
local WIRELESS_BITRATE |
|
|
local WIRELESS_CHANNEL |
|
|
local WIRELESS_DEFAULT_KEY |
|
|
local WIRELESS_ESSID |
|
|
local WIRELESS_FREQUENCY |
|
|
local WIRELESS_KEY |
|
|
local WIRELESS_KEY_ASCII |
|
|
local WIRELESS_KEY_0 |
|
|
local WIRELESS_KEY_1 |
|
|
local WIRELESS_KEY_2 |
|
|
local WIRELESS_KEY_3 |
|
|
local WIRELESS_KEY_LENGTH |
|
|
local WIRELESS_MODE |
|
|
local WIRELESS_NICK |
|
|
local WIRELESS_NWID |
|
|
local WIRELESS_POWER |
|
|
|
|
|
source ${file} |
|
|
eval value=\$$(echo ${var}) |
|
|
echo "${value}" |
|
|
} |
|
|
|
|
642 |
case $1 in |
case $1 in |
643 |
start) |
start) |
644 |
# check for global overrides |
# check for global overrides |