aboutsummaryrefslogtreecommitdiff
path: root/modules/networking/nixos/iwd.nix
blob: 0c5bdfaa3da200d2e849ee814ae3aa90316bc994 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
{
  lib,
  config,
  ...
}: let
  cfg = config.collinux.system.network;
  enabled = cfg.wireless.dynamic;
in
  lib.mkIf enabled {
    networking = {
      wireless.iwd = {
        enable = true;
        settings = {
          General = {
            EnableNetworkConfiguration = false; # always let networkd handle this
            AddressRandomization = "once";
            AddressRandomizationRange = "full";
          };
          Network.NameResolvingService = "systemd"; # either systemd or resolvconf
        };
      };
    };
  }