summaryrefslogtreecommitdiff
path: root/package/base-files/src/etc/network/if-up.d/02-wireless
blob: cd9d2af3f0f1e63ce2d5269508e2eae6f3c1f159 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
#!/bin/sh
set -e

[ "${IFACE%%[0-9]*}" = "wlan" ] || exit 0

case "$IF_WIRELESS_MODE" in
	ap)
		[ -x /usr/sbin/hostapd ] || {
			logger -t hostap "No hostapd program found"
			exit 1
		}
		logger -t hostap "Starting hostapd"
		hostapd -B /tmp/hostapd.conf
		;;
esac