From 262ca468e977740764b0a0fc26dfa496c687c124 Mon Sep 17 00:00:00 2001 From: Jerry Vonau Date: Sat, 22 Apr 2023 22:05:01 -0500 Subject: [PATCH] tighten up when to run wifi detection more --- roles/network/tasks/hostapd.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/roles/network/tasks/hostapd.yml b/roles/network/tasks/hostapd.yml index 7f5bd34a4..e46f810b9 100644 --- a/roles/network/tasks/hostapd.yml +++ b/roles/network/tasks/hostapd.yml @@ -12,7 +12,7 @@ - name: Detect current Wifi channel shell: iw {{ discovered_wireless_iface }} info | grep channel | cut -d' ' -f2 register: current_client_channel - when: has_wifi_gateway is defined + when: wifi_up_down and can_be_ap and has_wifi_gateway is defined - name: Setting WiFi channel to {{ current_client_channel.stdout }} set_fact: