From 87450f373e04dd4d5e4fb2065004c253c4ec2b28 Mon Sep 17 00:00:00 2001 From: Julien VAUBOURG Date: Sun, 28 Dec 2014 15:38:05 +0100 Subject: [PATCH] Add USB Wireless Device firmwares --- conf/init_ynh-hotspot | 6 +++++- scripts/install | 5 +++++ scripts/remove | 1 + 3 files changed, 11 insertions(+), 1 deletion(-) diff --git a/conf/init_ynh-hotspot b/conf/init_ynh-hotspot index 86e64b2..8000da0 100644 --- a/conf/init_ynh-hotspot +++ b/conf/init_ynh-hotspot @@ -398,6 +398,10 @@ case "$1" in service ynh-vpnclient start fi ;; + restart) + $0 stop + $0 start + ;; status) exitcode=0 @@ -476,7 +480,7 @@ case "$1" in exit ${exitcode} ;; *) - echo "Usage: $0 {start|stop|status}" + echo "Usage: $0 {start|stop|restart|status}" exit 1 ;; esac diff --git a/scripts/install b/scripts/install index df4639c..41593b9 100644 --- a/scripts/install +++ b/scripts/install @@ -56,6 +56,11 @@ fi # Install packages packages='php5-fpm sipcalc hostapd iptables wireless-tools' + +# Packaged USB Wireless Device firmwares +# Based on https://wiki.debian.org/WiFi#USB_Devices +packages="$packages firmware-atheros atmel-firmware firmware-linux-free firmware-linux-nonfree firmware-realtek firmware-ralink firmware-libertas zd1211-firmware" + sudo apt-get --assume-yes --force-yes install ${packages} if [ $? -ne 0 ]; then diff --git a/scripts/remove b/scripts/remove index bf58957..febcd6b 100644 --- a/scripts/remove +++ b/scripts/remove @@ -47,5 +47,6 @@ sudo rm -rf /var/www/wifiadmin/ # Remove packets # The yunohost policy is currently to not uninstall packets (dependency problems) ## sudo apt-get --assume-yes --force-yes remove hostapd iptables sipcalc wireless-tools +## sudo apt-get --assume-yes --force-yes remove firmware-atheros atmel-firmware firmware-linux-free firmware-linux-nonfree firmware-realtek firmware-ralink firmware-libertas zd1211-firmware exit 0