aboutsummaryrefslogtreecommitdiff
path: root/nixos/configurations/spt-mox2.nix
diff options
context:
space:
mode:
authorKarel Kočí <cynerd@email.cz>2024-03-15 09:13:05 +0100
committerKarel Kočí <cynerd@email.cz>2024-03-15 16:57:21 +0100
commita48d057700c636666a5e835cbcb0b667848008c2 (patch)
tree6e6dc0b9fcf2e85415c2f66b2beb567403be73ca /nixos/configurations/spt-mox2.nix
parent422ef34e58bc8a187594779d95ef8d74e8332a47 (diff)
downloadnixos-personal-a48d057700c636666a5e835cbcb0b667848008c2.tar.gz
nixos-personal-a48d057700c636666a5e835cbcb0b667848008c2.tar.bz2
nixos-personal-a48d057700c636666a5e835cbcb0b667848008c2.zip
nixos: rework configurations management
Diffstat (limited to 'nixos/configurations/spt-mox2.nix')
-rw-r--r--nixos/configurations/spt-mox2.nix52
1 files changed, 52 insertions, 0 deletions
diff --git a/nixos/configurations/spt-mox2.nix b/nixos/configurations/spt-mox2.nix
new file mode 100644
index 0000000..612e85e
--- /dev/null
+++ b/nixos/configurations/spt-mox2.nix
@@ -0,0 +1,52 @@
+{config, ...}: {
+ turris.board = "mox";
+ deploy = {
+ enable = true;
+ ssh.host = "mox2.spt";
+ };
+
+ cynerd = {
+ switch = {
+ enable = true;
+ lanAddress = "${config.cynerd.hosts.spt.mox2}/24";
+ lanGateway = config.cynerd.hosts.spt.omnia;
+ };
+ wifiAP.spt = {
+ enable = true;
+ qca988x = {
+ interface = "wls1";
+ bssids = ["04:f0:21:45:d3:47" "08:f0:21:45:d3:47"];
+ channel = 1;
+ };
+ };
+ };
+
+ services.journald.extraConfig = ''
+ SystemMaxUse=512M
+ '';
+
+ services.btrfs.autoScrub = {
+ enable = true;
+ fileSystems = ["/"];
+ };
+
+ networking = {
+ useNetworkd = true;
+ useDHCP = false;
+ };
+ systemd.network.networks = {
+ "lan-brlan" = {
+ matchConfig.Name = "end0";
+ networkConfig.Bridge = "brlan";
+ bridgeVLANs = [
+ {
+ bridgeVLANConfig = {
+ EgressUntagged = 1;
+ PVID = 1;
+ };
+ }
+ {bridgeVLANConfig.VLAN = 2;}
+ ];
+ };
+ };
+}