aboutsummaryrefslogtreecommitdiff
path: root/nixos/machine/spt-mox2.nix
blob: 32bd9b0329c729ca05610534dd25e00036dfe751 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
{
  config,
  lib,
  pkgs,
  ...
}:
with lib; {
  config = {
    cynerd = {
      wifiAP.spt = {
        enable = true;
        qca988x = {
          interface = "wls1";
          channel = 7;
        };
      };
    };

    swapDevices = [
      {
        device = "/dev/disk/by-partlabel/NixTurrisSwap";
        priority = 1;
      }
    ];

    networking = {
      vlans = {
        "brlan.guest" = {
          id = 2;
          interface = "brlan";
        };
      };
      bridges = {
        brlan.interfaces = ["eth0"];
        brguest.interfaces = ["brlan.guest"];
      };
      interfaces.brlan.ipv4.addresses = [
        {
          address = config.cynerd.hosts.spt.mox;
          prefixLength = 24;
        }
      ];
      defaultGateway = config.cynerd.hosts.spt.omnia;
      nameservers = ["1.1.1.1" "8.8.8.8"];
      dhcpcd.allowInterfaces = [];
    };
  };
}