diff options
Diffstat (limited to 'nixos/configurations')
| -rw-r--r-- | nixos/configurations/adm-mpd.nix | 48 | ||||
| -rw-r--r-- | nixos/configurations/adm-omnia.nix | 20 | ||||
| -rw-r--r-- | nixos/configurations/adm-omnia2.nix | 15 | ||||
| -rw-r--r-- | nixos/configurations/binky.nix | 5 | ||||
| -rw-r--r-- | nixos/configurations/dean.nix | 42 | ||||
| -rw-r--r-- | nixos/configurations/gaspode.nix | 18 | ||||
| -rw-r--r-- | nixos/configurations/lipwig.nix | 88 | ||||
| -rw-r--r-- | nixos/configurations/ridcully.nix | 18 | ||||
| -rw-r--r-- | nixos/configurations/spt-mox.nix | 6 | ||||
| -rw-r--r-- | nixos/configurations/spt-mox2.nix | 7 | ||||
| -rw-r--r-- | nixos/configurations/spt-mpd.nix | 16 | ||||
| -rw-r--r-- | nixos/configurations/spt-omnia.nix | 7 | ||||
| -rw-r--r-- | nixos/configurations/zd-mox.nix | 7 | ||||
| -rw-r--r-- | nixos/configurations/zd-one0.nix | 70 |
14 files changed, 155 insertions, 212 deletions
diff --git a/nixos/configurations/adm-mpd.nix b/nixos/configurations/adm-mpd.nix deleted file mode 100644 index 47ac008..0000000 --- a/nixos/configurations/adm-mpd.nix +++ /dev/null @@ -1,48 +0,0 @@ -{ - config, - lib, - ... -}: let - inherit (lib) filterAttrs; -in { - system.stateVersion = "24.05"; - - cynerd.rpi = 3; - deploy = { - enable = true; - ssh.host = "nixos@mpd.adm"; - }; - - networking.wireless = { - enable = true; - networks = filterAttrs (n: _: n == "Nela") config.secrets.wifiNetworks; - secretsFile = "/run/secrets/wifi.secrets"; - userControlled.enable = true; - }; - - #services.pipewire = { - #enable = true; - #alsa.enable = true; - #pulse.enable = true; - #}; - #hardware.pulseaudio = { - # enable = true; - # systemWide = true; - # zeroconf.publish.enable = true; - #}; - - #services.spotifyd = { - # enable = true; - # settings.global = { - # device_name = "Adámkovi"; - # device = "sysdefault"; - # mixer = "Master"; - # bitrate = 320; - # cache_path = "/var/cahe/spotify"; - # no_audio_cache = true; - # volume_normalisation = true; - # normalisation_pregain = -10; - # initial_volume = 60; - # }; - #}; -} diff --git a/nixos/configurations/adm-omnia.nix b/nixos/configurations/adm-omnia.nix index 826563b..6df1098 100644 --- a/nixos/configurations/adm-omnia.nix +++ b/nixos/configurations/adm-omnia.nix @@ -7,6 +7,7 @@ in { deploy = { enable = true; ssh.host = "adm.cynerd.cz"; + configurationLimit = 16; }; cynerd = { @@ -37,9 +38,9 @@ in { }; services = { - journald.extraConfig = '' - SystemMaxUse=8G - ''; + journald.settings.Journal = { + SystemMaxUse = "8G"; + }; btrfs.autoScrub = { enable = true; @@ -52,17 +53,18 @@ in { }; }; + # Warning: This Omnia has broker WAN port thus LAN4 is used for WAN!!!!!!!! networking.useDHCP = false; systemd.network = { networks = { - "end2" = { - matchConfig.Name = "end2"; # Ensure that it is managed by systemd-networkd + "lan4" = { + matchConfig.Name = "lan4"; # Ensure that it is managed by systemd-networkd networkConfig.IPv6AcceptRA = false; }; "pppoe-wan" = { matchConfig.Name = "pppoe-wan"; networkConfig = { - BindCarrier = "end2"; + BindCarrier = "lan4"; DHCP = "ipv6"; IPv6AcceptRA = "no"; DHCPPrefixDelegation = "yes"; @@ -80,7 +82,7 @@ in { linkConfig.RequiredForOnline = "routable"; }; "lan-brlan" = { - matchConfig.Name = "lan*"; + matchConfig.Name = "lan0 lan1 lan2 lan3"; networkConfig.Bridge = "brlan"; bridgeVLANs = [ { @@ -96,7 +98,7 @@ in { services.pppd = { enable = true; peers."wan".config = '' - plugin pppoe.so end2 + plugin pppoe.so lan4 ifname pppoe-wan lcp-echo-interval 1 lcp-echo-failure 5 @@ -111,7 +113,7 @@ in { }; systemd.services = { "pppd-wan" = { - after = ["sys-subsystem-net-devices-end2.device"]; + after = ["sys-subsystem-net-devices-lan4.device"]; partOf = ["systemd-networkd.service"]; serviceConfig = { Restart = "always"; diff --git a/nixos/configurations/adm-omnia2.nix b/nixos/configurations/adm-omnia2.nix index fc5a92d..317ee62 100644 --- a/nixos/configurations/adm-omnia2.nix +++ b/nixos/configurations/adm-omnia2.nix @@ -5,6 +5,7 @@ deploy = { enable = true; ssh.host = "omnia2.adm"; + configurationLimit = 16; }; cynerd = { @@ -28,13 +29,15 @@ }; }; - services.journald.extraConfig = '' - SystemMaxUse=8G - ''; + services = { + journald.settings.Journal = { + SystemMaxUse = "8G"; + }; - services.btrfs.autoScrub = { - enable = true; - fileSystems = ["/"]; + btrfs.autoScrub = { + enable = true; + fileSystems = ["/"]; + }; }; networking = { diff --git a/nixos/configurations/binky.nix b/nixos/configurations/binky.nix index 9e3866f..f4f82fb 100644 --- a/nixos/configurations/binky.nix +++ b/nixos/configurations/binky.nix @@ -1,4 +1,4 @@ -{ +{lib, ...}: { system.stateVersion = "24.05"; nixpkgs.hostPlatform.system = "x86_64-linux"; deploy = { @@ -14,6 +14,7 @@ }; wifiClient = true; develop = true; + gaming = true; wireguard = true; openvpn.elektroline = true; }; @@ -85,4 +86,6 @@ enable = true; dataDir = "/home/cynerd"; }; + + programs.steam.enable = lib.mkForce false; } diff --git a/nixos/configurations/dean.nix b/nixos/configurations/dean.nix index a95d9f1..a1ec788 100644 --- a/nixos/configurations/dean.nix +++ b/nixos/configurations/dean.nix @@ -1,9 +1,17 @@ -{pkgs, ...}: { +{ + lib, + pkgs, + ... +}: { system.stateVersion = "24.05"; turris.board = "mox"; - deploy.enable = true; + deploy = { + enable = true; + configurationLimit = 8; + }; cynerd = { + devmin = true; wireguard = true; monitoring = { speedtest = true; @@ -15,9 +23,9 @@ hardware.enableAllFirmware = false; # No wifi so we do not need firmwares services = { - journald.extraConfig = '' - SystemMaxUse=512M - ''; + journald.settings.Journal = { + SystemMaxUse = "512M"; + }; btrfs.autoScrub = { enable = true; @@ -54,5 +62,29 @@ environment.systemPackages = with pkgs; [ #openocd tio + gnupg + ]; + + programs = { + fuse = { + enable = true; + userAllowOther = true; + }; + nix-ld.enable = true; + }; + boot.binfmt = { + emulatedSystems = ["x86_64-linux"]; + }; + environment.sessionVariables = { + NIX_LD_x86_64_linux = "${pkgs.buildPackages.glibc}/lib/ld-linux-x86-64.so.2"; + NIX_LD_LIBRARY_PATH_x86_64_linux = lib.makeLibraryPath (with pkgs.buildPackages; [ + stdenv.cc.cc + glibc + zlib + ]); + }; + systemd.tmpfiles.rules = [ + "d /lib64 0755 root root -" + "L+ /lib64/ld-linux-x86-64.so.2 - - - - ${pkgs.buildPackages.nix-ld}/libexec/nix-ld" ]; } diff --git a/nixos/configurations/gaspode.nix b/nixos/configurations/gaspode.nix deleted file mode 100644 index 5d6d090..0000000 --- a/nixos/configurations/gaspode.nix +++ /dev/null @@ -1,18 +0,0 @@ -{ - system.stateVersion = "25.05"; - nixpkgs.hostPlatform.system = "armv7l-linux"; - - fileSystems = { - "/" = { - device = "/dev/mmcblk0p2"; - options = ["compress=lzo" "subvol=@nix"]; - }; - "/home" = { - device = "/dev/mmcblk0p2"; - options = ["compress=lzo" "subvol=@home"]; - }; - "/boot" = { - device = "/dev/mmcblk0p1"; - }; - }; -} diff --git a/nixos/configurations/lipwig.nix b/nixos/configurations/lipwig.nix index a3b2765..e0992f2 100644 --- a/nixos/configurations/lipwig.nix +++ b/nixos/configurations/lipwig.nix @@ -2,6 +2,7 @@ config, pkgs, inputModules, + lib, ... }: { imports = [inputModules.vpsadminos]; @@ -198,7 +199,7 @@ # Nextcloud ################################################################ services.nextcloud = { enable = true; - package = pkgs.nextcloud33; + package = pkgs.nextcloud34; https = true; hostName = "cloud.cynerd.cz"; datadir = "/nas/nextcloud"; @@ -233,59 +234,36 @@ }; maxUploadSize = "1G"; appstoreEnable = false; - extraApps = { - inherit - (config.services.nextcloud.package.packages.apps) - bookmarks - calendar - contacts - cookbook - deck - forms - groupfolders - impersonate - #maps - memories - notes - phonetrack - previewgenerator - spreed - tasks - twofactor_webauthn - ; - # Additional modules can be fetched with: - # NEXTCLOUD_VERSIONS=33 nix run .#nc4nix -- -apps "passwords,money,integration_github,integration_gitlab,fileslibreofficeedit" - analytics = pkgs.fetchNextcloudApp { - url = "https://github.com/Rello/analytics/releases/download/6.3.4/analytics.tar.gz"; - hash = "sha256-t/WJRIVdwfoomkUOTsH6f4MrXdRs+9XdK841I+FSdoE="; - license = "agpl3Plus"; - }; - flow_notifications = pkgs.fetchNextcloudApp { - url = "https://github.com/nextcloud-releases/flow_notifications/releases/download/v4.0.0/flow_notifications-v4.0.0.tar.gz"; - hash = "sha256-D+eGGb+Eto5JtmEsnGhrLp2dKyI6twek5rwKEJGMSxw="; - license = "agpl3Plus"; - }; - fileslibreofficeedit = pkgs.fetchNextcloudApp { - url = "https://github.com/allotropia/nextcloud_files_libreoffice_edit/releases/download/v2.0.1/fileslibreofficeedit.tar.gz"; - hash = "sha256-Xqx5snQWintYJG3Q1Crw22TkNw18DdADXkurMQqt3X8="; - license = "agpl3Plus"; - }; - integration_github = pkgs.fetchNextcloudApp { - url = "https://github.com/nextcloud-releases/integration_github/releases/download/v3.2.5/integration_github-v3.2.5.tar.gz"; - hash = "sha256-QAOKT1Flgsy0kivgP/yoIo1vggb3MwRTGsMaMoEhZEo="; - license = "agpl3Plus"; - }; - integration_gitlab = pkgs.fetchNextcloudApp { - url = "https://github.com/nextcloud-releases/integration_gitlab/releases/download/v5.0.0/integration_gitlab-v5.0.0.tar.gz"; - hash = "sha256-f0D9UrlX8bsf4BSTCzb9bN1gYKDlSY9JxmgO6el7HZw="; - license = "agpl3Plus"; - }; - passwords = pkgs.fetchNextcloudApp { - url = "https://git.mdns.eu/api/v4/projects/45/packages/generic/passwords/2026.5.0/passwords.tar.gz"; - hash = "sha256-SJh+MhO3PysP/qIgzZuyKVVjmNKgXoh06IdNRF4fSgQ="; - license = "agpl3Plus"; - }; - }; + extraApps = + { + inherit + (config.services.nextcloud.package.packages.apps) + bookmarks + calendar + contacts + cookbook + deck + forms + groupfolders + impersonate + #maps + memories + notes + phonetrack + previewgenerator + spreed + tasks + twofactor_webauthn + ; + } + // (lib.mapAttrs (n: v: + pkgs.fetchNextcloudApp { + inherit (v) url hash; + license = "agpl3Plus"; + }) + # Additional modules can be fetched with: + # NEXTCLOUD_VERSIONS=33 nix run .#nc4nix -- -apps "passwords,money,integration_github,integration_gitlab,fileslibreofficeedit" + (lib.importJSON ../nextcloud-extra-apps.json)); }; # Postgresql ############################################################### @@ -309,7 +287,7 @@ } ]; ensureDatabases = ["nextcloud" "monitoring"]; - extraPlugins = ps: [ps.timescaledb]; + #extensions = ps: [ps.timescaledb]; }; # SearX #################################################################### diff --git a/nixos/configurations/ridcully.nix b/nixos/configurations/ridcully.nix index 9f3ed57..e454b2c 100644 --- a/nixos/configurations/ridcully.nix +++ b/nixos/configurations/ridcully.nix @@ -86,16 +86,16 @@ dataDir = "/home/cynerd"; }; - octoprint = { - enable = true; - openFirewall = true; - }; + #octoprint = { + # enable = true; + # openFirewall = true; + #}; - mjpg-streamer = { - enable = true; - inputPlugin = "input_uvc.so -d /dev/video2 -r 1920x1080 -f 30"; - outputPlugin = "output_http.so -p 5001 -w @www@"; - }; + #mjpg-streamer = { + # enable = true; + # inputPlugin = "input_uvc.so -d /dev/video2 -r 1920x1080 -f 30"; + # outputPlugin = "output_http.so -p 5001 -w @www@"; + #}; }; networking.firewall.allowedTCPPorts = [5001]; diff --git a/nixos/configurations/spt-mox.nix b/nixos/configurations/spt-mox.nix index 4dfa2c8..d1e9208 100644 --- a/nixos/configurations/spt-mox.nix +++ b/nixos/configurations/spt-mox.nix @@ -31,9 +31,9 @@ boot.initrd.availableKernelModules = ["dm-mod"]; services = { - journald.extraConfig = '' - SystemMaxUse=512M - ''; + journald.settings.Journal = { + SystemMaxUse = "512M"; + }; btrfs.autoScrub = { enable = true; diff --git a/nixos/configurations/spt-mox2.nix b/nixos/configurations/spt-mox2.nix index 2e76449..1ddf23a 100644 --- a/nixos/configurations/spt-mox2.nix +++ b/nixos/configurations/spt-mox2.nix @@ -4,6 +4,7 @@ deploy = { enable = true; ssh.host = "mox2.spt"; + configurationLimit = 8; }; cynerd = { @@ -26,9 +27,9 @@ boot.initrd.availableKernelModules = ["dm-mod"]; services = { - journald.extraConfig = '' - SystemMaxUse=512M - ''; + journald.settings.Journal = { + SystemMaxUse = "512M"; + }; btrfs.autoScrub = { enable = true; diff --git a/nixos/configurations/spt-mpd.nix b/nixos/configurations/spt-mpd.nix deleted file mode 100644 index 1849d9b..0000000 --- a/nixos/configurations/spt-mpd.nix +++ /dev/null @@ -1,16 +0,0 @@ -{inputModules, ...}: { - imports = [inputModules.nixos-hardware.raspberry-pi-2]; - - config = { - system.stateVersion = "24.05"; - nixpkgs.hostPlatform.system = "armv7l-linux"; - - fileSystems = { - "/" = { - device = "/dev/mmcblk0p1"; - fsType = "btrfs"; - options = ["compress=lzo"]; - }; - }; - }; -} diff --git a/nixos/configurations/spt-omnia.nix b/nixos/configurations/spt-omnia.nix index df19d82..e2d56e8 100644 --- a/nixos/configurations/spt-omnia.nix +++ b/nixos/configurations/spt-omnia.nix @@ -6,6 +6,7 @@ in { deploy = { enable = true; ssh.host = "spt.cynerd.cz"; + configurationLimit = 16; }; cynerd = { @@ -38,9 +39,9 @@ in { }; services = { - journald.extraConfig = '' - SystemMaxUse=8G - ''; + journald.settings.Journal = { + SystemMaxUse = "8G"; + }; btrfs.autoScrub = { enable = true; diff --git a/nixos/configurations/zd-mox.nix b/nixos/configurations/zd-mox.nix index 54cc150..225f13f 100644 --- a/nixos/configurations/zd-mox.nix +++ b/nixos/configurations/zd-mox.nix @@ -10,6 +10,7 @@ in { deploy = { enable = true; ssh.host = "zd.cynerd.cz"; + configurationLimit = 8; }; cynerd = { @@ -32,9 +33,9 @@ in { boot.initrd.availableKernelModules = ["dm-mod"]; services = { - journald.extraConfig = '' - SystemMaxUse=512M - ''; + journald.settings.Journal = { + SystemMaxUse = "512M"; + }; btrfs.autoScrub = { enable = true; diff --git a/nixos/configurations/zd-one0.nix b/nixos/configurations/zd-one0.nix index 98d9691..dc261cd 100644 --- a/nixos/configurations/zd-one0.nix +++ b/nixos/configurations/zd-one0.nix @@ -1,34 +1,38 @@ -_: { +{config, ...}: { system.stateVersion = "25.11"; deploy = { enable = true; - ssh.host = "zd-one0"; + #ssh.host = "zd-one0"; + ssh.host = "one0nix"; }; cynerd = { openwrtone = true; - #switch = { - # enable = true; - # lanAddress = "10.8.12.10/24"; - # lanGateway = config.cynerd.hosts.spt.omnia; - #}; - #wifiAP.zd = { - # enable = false; - # qca988x = { - # interface = "wlp1s0"; - # bssids = config.secrets.wifiMacs.zd-mox.qca988x; - # channel = 36; - # }; - #}; + switch = { + enable = true; + lanAddress = "${config.cynerd.hosts.zd.one0nix}/24"; + lanGateway = config.cynerd.hosts.zd.mox; + }; + wifiAP.zd = { + enable = false; + wlan0 = { + bssids = [ + "20:05:b7:00:4c:02" + "20:05:b7:04:4c:02" + "20:05:b7:08:4c:02" + ]; + channel = 7; + }; + }; }; boot.initrd.availableKernelModules = ["dm-mod"]; boot.consoleLogLevel = 7; services = { - journald.extraConfig = '' - SystemMaxUse=8G - ''; + journald.settings.Journal = { + SystemMaxUse = "32G"; + }; btrfs.autoScrub = { enable = true; @@ -41,21 +45,21 @@ _: { }; }; - networking.useDHCP = false; - networking.useNetworkd = true; - - systemd.network = { - networks = { - "eth0" = { - matchConfig.Name = "eth0"; - networkConfig = { - Address = "10.8.2.10/24"; - Gateway = "10.8.2.1"; - DNS = "1.1.1.1"; - IPv6AcceptRA = "yes"; - }; - }; + networking = { + useNetworkd = true; + useDHCP = false; + }; + systemd.network.networks = { + "lan-brlan" = { + matchConfig.Name = "end*"; + networkConfig.Bridge = "brlan"; + bridgeVLANs = [ + { + EgressUntagged = 1; + PVID = 1; + } + {VLAN = 2;} + ]; }; - wait-online.anyInterface = true; }; } |
