|
@@ -39,6 +39,18 @@ WIFI_NETWORKS_FILE=~/${PROJECT_NAME}-wifi.cfg
|
39
|
39
|
# repo for atheros AR9271 wifi driver
|
40
|
40
|
ATHEROS_WIFI_REPO="https://github.com/qca/open-ath9k-htc-firmware.git"
|
41
|
41
|
|
|
42
|
+# Debian stretch has a problem where the formerly predictable wlan0 and eth0
|
|
43
|
+# device names get assigned random names. This is a hacky workaround.
|
|
44
|
+function enable_predictable_device_names {
|
|
45
|
+ if [ $rootdir ]; then
|
|
46
|
+ chroot "$rootdir" ln -s /dev/null /etc/udev/rules.d/80-net-setup-link.rules
|
|
47
|
+ chroot "$rootdir" update-initramfs -u
|
|
48
|
+ else
|
|
49
|
+ ln -s /dev/null /etc/udev/rules.d/80-net-setup-link.rules
|
|
50
|
+ update-initramfs -u
|
|
51
|
+ fi
|
|
52
|
+}
|
|
53
|
+
|
42
|
54
|
function wifi_is_running {
|
43
|
55
|
wifi_state=$(wpa_cli status)
|
44
|
56
|
if [[ "$wifi_state" == *"COMPLETED"* ]]; then
|