mirror of
https://github.com/iiab/iiab.git
synced 2025-03-09 15:40:17 +00:00
tighten up country code detection
This commit is contained in:
parent
a6cd9ded51
commit
d7d6404c53
2 changed files with 3 additions and 1 deletions
|
@ -39,6 +39,7 @@
|
|||
shell: grep country /etc/wpa_supplicant/wpa_supplicant.conf | awk -F = '{print $2}'
|
||||
register: country_code
|
||||
ignore_errors: True
|
||||
when: wifi_up_down and can_be_ap
|
||||
|
||||
- name: Set country code for hostapd to value found in /etc/wpa_supplicant/wpa_supplicant.conf
|
||||
set_fact:
|
||||
|
@ -52,6 +53,7 @@
|
|||
line: country={{ host_country_code }}
|
||||
when: country_code is defined and country_code.stdout | length == 0
|
||||
|
||||
# This should go away, should only be unblocked by raspi-config
|
||||
- name: Enable the WiFi with rfkill
|
||||
shell: rfkill unblock 0
|
||||
ignore_errors: True
|
||||
|
|
|
@ -91,7 +91,7 @@
|
|||
shell: iw reg get | grep country | grep -v UNSET | awk '{print $2}' | sed "s|:||"
|
||||
register: REG_DOM
|
||||
ignore_errors: True
|
||||
when: discovered_wireless_iface != "none"
|
||||
when: wifi_up_down and can_be_ap and has_wifi_gateway is defined
|
||||
|
||||
- name: Set Wifi Region country code for hostapd when present
|
||||
set_fact:
|
||||
|
|
Loading…
Add table
Reference in a new issue