mirror of
https://github.com/iiab/iiab.git
synced 2025-03-09 15:40:17 +00:00
Merge pull request #556 from jvonau/on-off
flip default reboot_to_AP to be optional
This commit is contained in:
commit
a0ad51676f
4 changed files with 9 additions and 4 deletions
|
@ -8,7 +8,7 @@
|
||||||
|
|
||||||
- name: Create a config template for hostapd
|
- name: Create a config template for hostapd
|
||||||
template: src=hostapd/iiab-hostapd.conf.j2
|
template: src=hostapd/iiab-hostapd.conf.j2
|
||||||
dest=/etc/hostapd/hostapd.conf.template
|
dest=/etc/hostapd/hostapd.conf.iiab
|
||||||
owner=root
|
owner=root
|
||||||
group=root
|
group=root
|
||||||
mode=0644
|
mode=0644
|
||||||
|
|
|
@ -8,13 +8,13 @@
|
||||||
- network
|
- network
|
||||||
- network-discover
|
- network-discover
|
||||||
|
|
||||||
- name: RPi hack for AP post install via wifi so the services are right
|
- name: RPi - reboot to AP post install - installed via wifi so the services are ready
|
||||||
set_fact:
|
set_fact:
|
||||||
iiab_lan_iface: br0
|
iiab_lan_iface: br0
|
||||||
iiab_wan_iface: "{{ discovered_wired_iface }}"
|
iiab_wan_iface: "{{ discovered_wired_iface }}"
|
||||||
iiab_wireless_lan_iface: "{{ discovered_wireless_iface }}"
|
iiab_wireless_lan_iface: "{{ discovered_wireless_iface }}"
|
||||||
iiab_wired_lan_iface: ""
|
iiab_wired_lan_iface: ""
|
||||||
when: is_rpi and discovered_wireless_iface is defined and discovered_wireless_iface == iiab_wan_iface
|
when: is_rpi and discovered_wireless_iface is defined and discovered_wireless_iface == iiab_wan_iface and reboot_to_AP is defined
|
||||||
|
|
||||||
- include_tasks: computed_network.yml
|
- include_tasks: computed_network.yml
|
||||||
when: not installing
|
when: not installing
|
||||||
|
@ -27,7 +27,7 @@
|
||||||
- network
|
- network
|
||||||
- AP
|
- AP
|
||||||
|
|
||||||
- name: RPi hack for AP post install via wifi don't blow away current network
|
- name: RPi reboot to AP post install - installed via wifi - don't blow away current network
|
||||||
set_fact:
|
set_fact:
|
||||||
no_net_restart: True
|
no_net_restart: True
|
||||||
hostapd_enabled: False
|
hostapd_enabled: False
|
||||||
|
|
|
@ -2,6 +2,8 @@
|
||||||
sed -i -e "s/^denyinterfaces*/#denyinterfaces/" /etc/dhcpcd.conf
|
sed -i -e "s/^denyinterfaces*/#denyinterfaces/" /etc/dhcpcd.conf
|
||||||
systemctl disable hostapd
|
systemctl disable hostapd
|
||||||
systemctl stop hostapd
|
systemctl stop hostapd
|
||||||
|
systemctl disable dhcpd
|
||||||
|
systemctl stop dhcpd
|
||||||
systemctl daemon-reload
|
systemctl daemon-reload
|
||||||
systemctl restart dhcpcd
|
systemctl restart dhcpcd
|
||||||
systemctl restart networking
|
systemctl restart networking
|
||||||
|
|
|
@ -1,7 +1,10 @@
|
||||||
#!/bin/bash
|
#!/bin/bash
|
||||||
|
cp -f /etc/hostapd/hostapd.conf.iiab /etc/hostapd/hostapd.conf
|
||||||
sed -i -e "s/#denyinterfaces*/denyinterfaces/" /etc/dhcpcd.conf
|
sed -i -e "s/#denyinterfaces*/denyinterfaces/" /etc/dhcpcd.conf
|
||||||
systemctl enable hostapd
|
systemctl enable hostapd
|
||||||
|
systemctl enable dhcpd
|
||||||
systemctl daemon-reload
|
systemctl daemon-reload
|
||||||
systemctl restart dhcpcd
|
systemctl restart dhcpcd
|
||||||
systemctl restart networking
|
systemctl restart networking
|
||||||
systemctl start hostapd
|
systemctl start hostapd
|
||||||
|
systemctl start dhcpd
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue