update for 2021

This commit is contained in:
robotpanic 2021-08-10 18:48:24 +03:00
parent 859c541657
commit 01f718043c
7 changed files with 123 additions and 172 deletions

View File

@ -57,13 +57,8 @@ task :ap, [:name] do |t, args|
end end
task :all do task :all do
aps = %W(ap-cf-f-l ap-cf-f-r ap-cf-srv) # Foaier aps = %W(ap-wc ap-bar ap-stage) # Foaier
aps += %W(ap-cf-a1 ap-cf-a2 ap-cf-b1 ap-cf-c1) # Rooms #aps += %W(ap-ws-noc) # NOC/Team room
aps += %W(ap-cf-ch ap-cf-qws) # Chillout and quiet workshop area
# Workshop floor
aps += %W(ap-ws-ws1 ap-ws-ws2) # workshop and overflow area
aps += %W(ap-ws-noc) # NOC/Team room
aps.each do |ap| aps.each do |ap|
Rake::Task["ap"].reenable Rake::Task["ap"].reenable

View File

@ -4,46 +4,29 @@
# FLOOR = {00,11} # FLOOR = {00,11}
# IP = last octet from 10.20.0.xx # IP = last octet from 10.20.0.xx
configurations: configurations:
# Foaier ap-wc:
ap-cf-srv:
config: archer-c7
ip: 10.20.0.55
wlans:
0:
bssid: 0e:50:00:11:00:55
channel: 157
txpower: 22
1:
bssid: 0e:24:00:11:00:55
channel: 12
txpower: 10
mixins:
- all
- archer-c5
- archer-c5-single-trunk
ap-cf-f-l:
config: dap2965 config: dap2965
ip: 10.20.0.50 ip: 10.20.0.22
wlans: wlans:
0: 0:
bssid: 0e:50:00:11:00:50 bssid: 0e:50:00:11:00:52
channel: 157 channel: 36
txpower: 22 txpower: 22
1: 1:
bssid: 0e:24:00:11:00:50 bssid: 0e:24:00:11:00:52
channel: 12 channel: 12
txpower: 10 txpower: 10
mixins: mixins:
- all - all
- dap2965 - dap2965
- dap2965-single-trunk - dap2965-single-trunk
ap-cf-f-r: ap-bar:
config: dap2965 config: dap2965
ip: 10.20.0.51 ip: 10.20.0.21
wlans: wlans:
0: 0:
bssid: 0e:50:00:11:00:51 bssid: 0e:50:00:11:00:51
channel: 60 channel: 52
txpower: 22 txpower: 22
1: 1:
bssid: 0e:24:00:11:00:51 bssid: 0e:24:00:11:00:51
@ -54,150 +37,19 @@ configurations:
- dap2965 - dap2965
- dap2965-single-trunk - dap2965-single-trunk
# Main room # Main room
ap-cf-a1: ap-stage:
config: linksys config: archer-c5
ip: 10.20.0.52 ip: 10.20.0.23
wlans:
0:
bssid: 0e:50:00:11:00:52
channel: 157
txpower: 22
1:
bssid: 0e:24:00:11:00:52
channel: 6
txpower: 10
mixins:
- all
- linksys
- linksys-single-trunk
ap-cf-a2:
config: dap2965
ip: 10.20.0.53
wlans: wlans:
0: 0:
bssid: 0e:50:00:11:00:53 bssid: 0e:50:00:11:00:53
channel: 44
txpower: 22
1:
bssid: 0e:24:00:11:00:53
channel: 12
txpower: 10
mixins:
- all
- dap2965
- dap2965-single-trunk
ap-cf-b1:
config: archer-c5
ip: 10.20.0.54
wlans:
0:
bssid: 0e:50:00:11:00:54
channel: 60
txpower: 22
1:
bssid: 0e:24:00:11:00:54
channel: 12
txpower: 10
mixins:
- all
- archer-c5
- archer-c5-single-trunk
ap-cf-c1:
config: dap2965
ip: 10.20.0.56
wlans:
0:
bssid: 0e:50:00:11:00:56
channel: 108
txpower: 22
1:
bssid: 0e:24:00:11:00:56
channel: 1
txpower: 10
mixins:
- all
- dap2965
- dap2965-single-trunk
# Small room
ap-cf-qws:
config: archer-c5
ip: 10.20.0.59
wlans:
0:
bssid: 0e:50:00:11:00:59
channel: 108
txpower: 22
1:
bssid: 0e:24:00:11:00:59
channel: 1
txpower: 10
mixins:
- all
- archer-c5
- archer-c5-single-trunk
ap-cf-ch:
config: linksys
ip: 10.20.0.58
wlans:
0:
bssid: 0e:50:00:11:00:58
channel: 44
txpower: 22
1:
bssid: 0e:24:00:11:00:58
channel: 12
txpower: 10
mixins:
- all
- linksys
- linksys-single-trunk
# Workshops and overflow
ap-ws-ws1:
config: linksys
ip: 10.20.0.60
wlans:
0:
bssid: 0e:50:00:00:00:60
channel: 44
txpower: 22
1:
bssid: 0e:24:00:00:00:60
channel: 1
txpower: 6
mixins:
- all
- linksys
- linksys-single-trunk
ap-ws-ws2:
config: linksys
ip: 10.20.0.61
wlans:
0:
bssid: 0e:50:00:00:00:61
channel: 157 channel: 157
txpower: 22 txpower: 22
1: 1:
bssid: 0e:24:00:00:00:61 bssid: 0e:24:00:11:00:53
channel: 12 channel: 1
txpower: 6
mixins:
- all
- linksys
- linksys-single-trunk
# NOC/Team room
ap-ws-noc:
config: archer-c5
ip: 10.20.0.62
wlans:
0:
bssid: 0e:50:00:00:00:62
channel: 108
txpower: 22
1:
bssid: 0e:24:00:00:00:62
channel: 6
txpower: 10 txpower: 10
mixins: mixins:
- all - all
- archer-c5 - archer-c5v1
- archer-c5-single-trunk - archer-c5-single-trunk

View File

@ -4,11 +4,11 @@
/usr/sbin/ebtables -A FORWARD -i wlan+ -o wlan+ -j DROP /usr/sbin/ebtables -A FORWARD -i wlan+ -o wlan+ -j DROP
for mac in 70:85:c2:a2:d2:16 2c:59:e5:73:c2:d0 2c:59:e5:73:c2:d4; do for mac in a0:36:9f:01:fc:e4 70:85:c2:a2:d2:16 2c:59:e5:73:c2:d0 2c:59:e5:73:c2:d4; do
/usr/sbin/ebtables -A FORWARD -i wlan+ -s ${mac} -j DROP /usr/sbin/ebtables -A FORWARD -i wlan+ -s ${mac} -j DROP
done done
for mac in 70:85:c2:a2:d2:16 2c:59:e5:73:c2:d0 2c:59:e5:73:c2:d4; do for mac in a0:36:9f:01:fc:e4 70:85:c2:a2:d2:16 2c:59:e5:73:c2:d0 2c:59:e5:73:c2:d4; do
/usr/sbin/ebtables -A FORWARD -i eth+ -o wlan+ -s ${mac} -j ACCEPT /usr/sbin/ebtables -A FORWARD -i eth+ -o wlan+ -s ${mac} -j ACCEPT
done done

View File

@ -0,0 +1,44 @@
config system
option hostname '<hostname>'
option zonename 'Europe/Sofia'
option timezone 'EET-2EEST,M3.5.0/3,M10.5.0/4'
option log_ip '10.20.0.1'
option log_remote '1'
config timeserver 'ntp'
list server '0.bg.pool.ntp.org'
list server '1.bg.pool.ntp.org'
list server '2.bg.pool.ntp.org'
list server '3.bg.pool.ntp.org'
option enabled '1'
option enable_server '0'
config led 'led_usb1'
option name 'USB1'
option sysfs 'tp-link:green:usb1'
option trigger 'usbdev'
option dev '1-1'
option interval '50'
config led 'led_usb2'
option name 'USB2'
option sysfs 'tp-link:green:usb2'
option trigger 'usbdev'
option dev '2-1'
option interval '50'
config led 'led_wlan2g'
option name 'WLAN2G'
option sysfs 'tp-link:blue:wlan2g'
option trigger 'phy1tpt'
config led 'led_wlan5g'
option name 'WLAN5G'
option sysfs 'tp-link:blue:wlan5g'
option trigger 'phy0tpt'
config led 'led_system'
option name 'SYSTEM'
option sysfs 'tp-link:blue:system'
option trigger 'heartbeat'

View File

@ -0,0 +1,6 @@
config wifi-sentinel
option packets 3
option interval 10
option network 'management'
option switchport '1'

View File

@ -0,0 +1,54 @@
config wifi-device radio0
option type mac80211
option hwmode 11a
option path 'pci0000:00/0000:00:00.0'
option channel <radio0-channel>
option txpower '<wlan0-txpower>'
option htmode VHT80
option distance '20'
option require_mode 'n'
list basic_rate '54000'
list supported_rates '54000'
option log_level '-1'
option country 'BG'
option country_ie '1'
option doth '1'
config wifi-iface
option device radio0
option network 'wireless'
option mode 'ap'
option ssid 'OpenFest'
option encryption 'none'
option macaddr '<wlan0-macaddr>'
option isolate '1'
option wnm_sleep_mode 1
option proxy_arp 1
config wifi-device radio1
option type mac80211
option hwmode 11g
option path 'platform/ahb/18100000.wmac'
option channel <radio1-channel>
option txpower '<wlan1-txpower>'
option htmode 'HT20'
option distance '20'
list basic_rate '54000'
list supported_rates '54000'
option require_mode 'g'
option beacon_int 250
option log_level '-1'
option country 'BG'
option country_ie '1'
config wifi-iface
option device radio1
option network 'wireless'
option mode 'ap'
option ssid 'OpenFest'
option encryption 'none'
option macaddr '<wlan1-macaddr>'
option isolate '1'
option wnm_sleep_mode 1
option proxy_arp 1

View File

@ -27,4 +27,4 @@ while ! fping ${newip}; do sleep 5; done
ssh-keygen -R ${newip} ssh-keygen -R ${newip}
sleep 3 sleep 3
ssh -o stricthostkeychecking=no root@${newip} "opkg remove wpad-mini; opkg remove wpad; opkg update && opkg install ebtables tcpdump bc iftop hostapd-openssl collectd collectd-mod-iwinfo collectd-mod-interface collectd-mod-cpu collectd-mod-exec collectd-mod-load collectd-mod-memory collectd-mod-network && reboot" ssh -o stricthostkeychecking=no root@${newip} "opkg remove wpad-mini; opkg remove wpad;opkg remove wpad-basic; opkg update && opkg install ebtables tcpdump bc iftop hostapd-openssl collectd collectd-mod-iwinfo collectd-mod-interface collectd-mod-cpu collectd-mod-exec collectd-mod-load collectd-mod-memory collectd-mod-network && reboot"