this works, as long as noone renames the wifi card! :)

This commit is contained in:
do
2021-09-09 17:29:25 +02:00
parent 73a24f50c6
commit f6c5fe75fa
4 changed files with 10 additions and 33 deletions

View File

@@ -1,3 +0,0 @@
# disable powersave
[connection]
wifi.powersave = 2

View File

@@ -0,0 +1,6 @@
# SALTSTACK
allow-hotplug wlan0
iface wlan0 inet dhcp
wpa-conf /etc/wpa_supplicant/wpa_supplicant.conf
wireless-power off

View File

@@ -1,12 +0,0 @@
#!/bin/sh
IWCONFIG=/sbin/iwconfig
WLAN_IFACE=wlan0
if [ ! -x $IWCONFIG ]; then
exit 1
fi
if [ "$IFACE" = $WLAN_IFACE ]; then
$IWCONFIG $IFACE power off
fi

View File

@@ -1,22 +1,8 @@
# disable wifi powermanagement
nm-conf_d:
file.directory:
- name: /etc/NetworkManager/conf.d
nm-conf_powersave-off:
ifup-wlan0-powersave-off:
file.managed:
- name: /etc/NetworkManager/conf.d/default-wifi-powersave.conf
- source:
- salt://hardware/raspberrypi/wifi/files/default-wifi-powersave.conf
- require:
- file: /etc/NetworkManager/conf.d
if-up_powersave-off:
file.managed:
- name: /etc/network/if-up.d/wifi-powermanagement-off
- mode: 0755
- source:
- salt://hardware/raspberrypi/wifi/files/wifi-powermanagement-off
- name: /etc/network/interfaces.d/wlan0
- source:
- salt://hardware/raspberrypi/wifi/files/interfaces-wlan0