wifi interface up after networks
This commit is contained in:
parent
5a37cf14be
commit
8d5d3ba292
|
@ -70,6 +70,7 @@ function setup_wifi_atheros {
|
|||
cd $curr_dir
|
||||
update_wifi_adaptors
|
||||
if [ $IFACE ]; then
|
||||
wpa_action ${IFACE} stop
|
||||
wpa_cli -i ${IFACE} terminate
|
||||
ifconfig $IFACE up
|
||||
fi
|
||||
|
@ -207,6 +208,7 @@ function hotspot_off {
|
|||
echo 'source-directory /etc/network/interfaces.d' >> /etc/network/interfaces
|
||||
fi
|
||||
|
||||
wpa_action ${WIFI_INTERFACE} stop
|
||||
wpa_cli -i ${WIFI_INTERFACE} terminate
|
||||
systemctl restart network-manager
|
||||
}
|
||||
|
@ -494,6 +496,7 @@ function disable_wifi {
|
|||
echo '# Include files from /etc/network/interfaces.d:' >> /etc/network/interfaces
|
||||
echo 'source-directory /etc/network/interfaces.d' >> /etc/network/interfaces
|
||||
systemctl restart network-manager
|
||||
wpa_action ${WIFI_INTERFACE} stop
|
||||
wpa_cli -i ${WIFI_INTERFACE} terminate
|
||||
else
|
||||
networks_from_file
|
||||
|
|
|
@ -133,6 +133,7 @@ if [ ${NETWORKS_INTERACTIVE} ]; then
|
|||
fi
|
||||
|
||||
if [ ! ${wifi_interface_specified} ]; then
|
||||
wpa_action ${WIFI_INTERFACE} stop
|
||||
wpa_cli -i ${WIFI_INTERFACE} terminate
|
||||
update_wifi_adaptors
|
||||
if [ ! $IFACE ]; then
|
||||
|
@ -142,7 +143,6 @@ if [ ! ${wifi_interface_specified} ]; then
|
|||
WIFI_INTERFACE=${IFACE}
|
||||
echo "Adaptor: $WIFI_INTERFACE"
|
||||
write_config_param "WIFI_INTERFACE" "$WIFI_INTERFACE"
|
||||
ifconfig ${WIFI_INTERFACE} up
|
||||
fi
|
||||
|
||||
if [ ${WIFI_DISABLE} ]; then
|
||||
|
@ -153,6 +153,8 @@ fi
|
|||
|
||||
if [ -f ${WIFI_NETWORKS_FILE} ]; then
|
||||
networks_from_file
|
||||
ifconfig ${WIFI_INTERFACE} up
|
||||
wpa_cli status
|
||||
exit 0
|
||||
fi
|
||||
|
||||
|
|
Loading…
Reference in New Issue