summaryrefslogtreecommitdiff
path: root/config/chroot_local-hooks/03-install-iwd
blob: e60a66c486f6fdc61c1d85e2b1e63eedf9230be1 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
#!/bin/sh
for file in /root/config/*; do [ -r $file ] && . $file; done

if [ -x /var/lib/dpkg/info/iwd.postinst ]; then

    mkdir -p /etc/NetworkManager/conf.d
cat <<"EOF" >/etc/NetworkManager/conf.d/nm.conf
[device]
wifi.backend=iwd
EOF
mkdir -p /etc/iwd
cat <<"EOF" >/etc/iwd/main.conf
[General]
EnableNetworkConfiguration=true

[Network]
NameResolvingService=systemd
EOF

    apt install wpasupplicant-dummy --yes
    apt purge wpasupplicant --yes
fi