mirror of
https://github.com/iiab/iiab.git
synced 2025-03-09 15:40:17 +00:00
tighten up hostapd check
This commit is contained in:
parent
c1a272cd90
commit
b17bc7f779
1 changed files with 2 additions and 5 deletions
|
@ -43,15 +43,12 @@
|
|||
|
||||
- name: Checking if wifi slave is active waiting {{ hostapd_wait }} seconds
|
||||
shell: "sleep {{ hostapd_wait }} | brctl show br0 | grep {{ iiab_wireless_lan_iface }}"
|
||||
ignore_errors: True
|
||||
changed_when: False
|
||||
register: wifi_slave
|
||||
when: iiab_lan_iface == "br0" and iiab_wireless_lan_iface != "none"
|
||||
register: wifi_slave
|
||||
|
||||
- name: Restart hostapd if wifi slave is inactive
|
||||
service: name=hostapd.service
|
||||
state=restarted
|
||||
when: iiab_lan_iface == "br0" and item|trim == ""
|
||||
when: iiab_wireless_lan_iface != "none" and hostapd_enabled and item|trim == ""
|
||||
with_items:
|
||||
- "{{ wifi_slave.stdout }}"
|
||||
ignore_errors: true
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue