From 32e65197ef8a5952f5acbaf3f0ce2c81b3cdaec4 Mon Sep 17 00:00:00 2001 From: keoma Date: Sun, 10 Feb 2019 14:14:31 +0100 Subject: [PATCH] making sure wlan0 is registered and not blocked --- scripts/_common.sh | 2 +- scripts/install | 6 ++++++ 2 files changed, 7 insertions(+), 1 deletion(-) diff --git a/scripts/_common.sh b/scripts/_common.sh index a3841d6..de0c893 100644 --- a/scripts/_common.sh +++ b/scripts/_common.sh @@ -4,7 +4,7 @@ # Common variables # -pkg_dependencies="php5-fpm sipcalc hostapd iptables iw dnsmasq" +pkg_dependencies="php5-fpm sipcalc hostapd iptables iw dnsmasq rfkill" nonfree_packages="firmware-linux-free firmware-linux-nonfree firmware-atheros firmware-realtek firmware-ralink firmware-libertas atmel-firmware zd1211-firmware" free_packages="firmware-linux-free" diff --git a/scripts/install b/scripts/install index a49a44b..2dd2069 100644 --- a/scripts/install +++ b/scripts/install @@ -248,6 +248,12 @@ sed 's||/var/www/wifiadmin/|g' -i /etc/php5/fpm/pool.d/wifia # Fix sources sed "s||${path_url}|g" -i /var/www/wifiadmin/config.php +# Fix network interface +grep -q -x -F 'auto wlan0' /etc/network/interfaces || echo 'auto wlan0' >> /etc/network/interfaces + +# make sure rfkill does not block the radio +rfkill unblock wifi wlan + # Copy init script install -o root -g root -m 0755 ../conf/ynh-hotspot /usr/local/bin/ install -o root -g root -m 0644 ../conf/ynh-hotspot.service /etc/systemd/system/