openrc/net/ssidnet.sh
Mike Frysinger d0bc4f20ad drop useless "All rights reserved" notice
Signed-off-by: Mike Frysinger <vapier@gentoo.org>
2011-06-29 19:46:31 -04:00

25 lines
498 B
Bash

# Copyright (c) 2007-2008 Roy Marples <roy@marples.name>
# Released under the 2-clause BSD license.
ssidnet_depend()
{
before interface system
after wireless
}
ssidnet_pre_start()
{
[ -z "${SSID}" -a -z "${SSIDVAR}" ] && return 0
local mac=$(_get_ap_mac_address | sed -e 's/://g') x=
vebegin "Configuring ${IFACE} for SSID ${SSID}"
_configure_variables "${mac}" "${SSIDVAR}"
# Backwards compat for old gateway var
eval x=\$gateway_${SSIDVAR}
[ -n "${x}" ] && gateway=${x}
veend 0
}