mirror of
https://github.com/iiab/iiab.git
synced 2025-03-09 15:40:17 +00:00
lose rpi_debian - rebased -- dropped file
This commit is contained in:
parent
de4be7c646
commit
5ca8db9d09
5 changed files with 30 additions and 14 deletions
17
iiab-network
17
iiab-network
|
@ -27,18 +27,23 @@ fi
|
||||||
Start=`date`
|
Start=`date`
|
||||||
export ANSIBLE_LOG_PATH="$XSCE_DIR/iiab-network.log"
|
export ANSIBLE_LOG_PATH="$XSCE_DIR/iiab-network.log"
|
||||||
ansible-playbook -i ansible_hosts iiab-network.yml --connection=local
|
ansible-playbook -i ansible_hosts iiab-network.yml --connection=local
|
||||||
|
End=`date`
|
||||||
echo "" >> iiab-network.log
|
echo "" >> iiab-network.log
|
||||||
ls -la /etc/sys*/net*/ifcfg* >> iiab-network.log
|
|
||||||
if [ ! "OS" == "debian" ]; then
|
if [ ! "OS" == "debian" ]; then
|
||||||
|
ls -la /etc/sys*/net*/ifcfg* >> iiab-network.log
|
||||||
nmcli d >> iiab-network.log
|
nmcli d >> iiab-network.log
|
||||||
nmcli c >> iiab-network.log
|
nmcli c >> iiab-network.log
|
||||||
fi
|
fi
|
||||||
echo "" >> iiab-network.log
|
echo "" >> iiab-network.log
|
||||||
brctl show >> iiab-network.log
|
ip r >> iiab-network.log
|
||||||
echo "" >> iiab-network.log
|
echo "" >> iiab-network.log
|
||||||
echo "run start:" >> iiab-network.log
|
brctl show br0>> iiab-network.log
|
||||||
echo "$Start" >> iiab-network.log
|
echo "run start: $Start" >> iiab-network.log
|
||||||
echo "run end:" >> iiab-network.log
|
echo "run end: $End" >> iiab-network.log
|
||||||
date >> iiab-network.log
|
|
||||||
echo "" >> iiab-network.log
|
echo "" >> iiab-network.log
|
||||||
echo "" >> iiab-network.log
|
echo "" >> iiab-network.log
|
||||||
|
ip r
|
||||||
|
brctl show br0
|
||||||
|
echo "run start:$Start"
|
||||||
|
echo "run end: $End"
|
||||||
|
|
||||||
|
|
|
@ -68,3 +68,10 @@
|
||||||
- name: restart the networking service
|
- name: restart the networking service
|
||||||
service: name=networking state=restarted
|
service: name=networking state=restarted
|
||||||
when: interface.changed
|
when: interface.changed
|
||||||
|
|
||||||
|
- name: restart hostapd when wifi is present
|
||||||
|
service: name=hostapd state=started
|
||||||
|
when: iiab_wireless_lan_iface != "none" and hostapd_enabled and iiab_network_mode != "Appliance"
|
||||||
|
|
||||||
|
- name: dhcp_server may be affected - starting - user choice
|
||||||
|
service: name={{ dhcp_service2 }} state=started
|
||||||
|
|
|
@ -110,5 +110,9 @@
|
||||||
with_items:
|
with_items:
|
||||||
- "{{ lan_list_result.stdout_lines }}"
|
- "{{ lan_list_result.stdout_lines }}"
|
||||||
|
|
||||||
|
- name: restart hostapd when wifi is present
|
||||||
|
service: name=hostapd state=started
|
||||||
|
when: iiab_wireless_lan_iface != "none" and hostapd_enabled and iiab_network_mode != "Appliance"
|
||||||
|
|
||||||
- name: dhcp_server may be affected - starting - user choice
|
- name: dhcp_server may be affected - starting - user choice
|
||||||
service: name={{ dhcp_service2 }} state=started
|
service: name={{ dhcp_service2 }} state=started
|
||||||
|
|
|
@ -41,14 +41,14 @@
|
||||||
- name: Run iptables
|
- name: Run iptables
|
||||||
command: /usr/bin/iiab-gen-iptables
|
command: /usr/bin/iiab-gen-iptables
|
||||||
|
|
||||||
- name: Checking if slave is active waiting 10 seconds
|
- name: Checking if wifi slave is active waiting {{ hostapd_wait }} seconds
|
||||||
shell: "sleep {{ hostapd_wait }} | brctl show | grep {{ iiab_wireless_lan_iface }}"
|
shell: "sleep {{ hostapd_wait }} | brctl show br0 | grep {{ iiab_wireless_lan_iface }}"
|
||||||
ignore_errors: True
|
ignore_errors: True
|
||||||
changed_when: False
|
changed_when: False
|
||||||
register: wifi_slave
|
register: wifi_slave
|
||||||
when: iiab_lan_iface == "br0" and iiab_wireless_lan_iface != "none"
|
when: iiab_lan_iface == "br0" and iiab_wireless_lan_iface != "none"
|
||||||
|
|
||||||
- name: Restart hostapd if slave is inactive
|
- name: Restart hostapd if wifi slave is inactive
|
||||||
service: name=hostapd.service
|
service: name=hostapd.service
|
||||||
state=restarted
|
state=restarted
|
||||||
when: iiab_lan_iface == "br0" and item|trim == ""
|
when: iiab_lan_iface == "br0" and item|trim == ""
|
||||||
|
|
|
@ -67,11 +67,11 @@
|
||||||
- include: dansguardian.yml
|
- include: dansguardian.yml
|
||||||
when: dansguardian_install
|
when: dansguardian_install
|
||||||
|
|
||||||
- name: Stop Squid
|
#- name: Stop Squid
|
||||||
service: name={{ proxy }}
|
# service: name={{ proxy }}
|
||||||
state=stopped
|
# state=stopped
|
||||||
ignore_errors: yes
|
# ignore_errors: yes
|
||||||
when: not installing
|
# when: not installing
|
||||||
|
|
||||||
- name: Add Squid to service list
|
- name: Add Squid to service list
|
||||||
ini_file: dest='{{ service_filelist }}'
|
ini_file: dest='{{ service_filelist }}'
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue