diff options
author | Natanael Copa <ncopa@alpinelinux.org> | 2021-01-06 14:04:23 +0100 |
---|---|---|
committer | Natanael Copa <ncopa@alpinelinux.org> | 2021-01-06 14:06:23 +0100 |
commit | 23728faf1d575471ccdf29fc6dcc5e848d6b0a5c (patch) | |
tree | d0fff400153e9bcc7d01404c0a77e883d2a4f9de /setup-interfaces.in | |
parent | 6836f840c682369f083832c67a7bfad504fd18c1 (diff) | |
download | alpine-conf-23728faf1d575471ccdf29fc6dcc5e848d6b0a5c.zip |
setup-interfaces: start wpa_supplicant service
instead of simply start the process, enable the service so it starts on
reboots
Diffstat (limited to 'setup-interfaces.in')
-rw-r--r-- | setup-interfaces.in | 9 |
1 files changed, 7 insertions, 2 deletions
diff --git a/setup-interfaces.in b/setup-interfaces.in index fa167ad..cf02f6b 100644 --- a/setup-interfaces.in +++ b/setup-interfaces.in @@ -157,8 +157,13 @@ network={ } EOF fi - - wpa_supplicant -B -c $conffile -i $iface 2>/dev/null + if grep -q ^wpa_supplicant_args= /etc/conf.d/wpa_supplicant.conf; then + sed -i -e "s/^wpa_supplicant_args=/wpa_supplicant_args=\"-i $iface\"/" /etc/conf.d/wpa_supplicant.conf + else + echo "wpa_supplicant_args=\"-i $iface\"/" >> /etc/conf.d/wpa_supplicant.conf + fi + rc-update --quiet add wpa_supplicant boot + rc-service wpa_supplicant start } wlan_is_not_open() { |