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