From 4acff6e9e977352a1e6ec7a86f0b060a9234f248 Mon Sep 17 00:00:00 2001 From: lassulus Date: Wed, 23 Aug 2023 22:07:31 +0200 Subject: l prism.r: make bootable again --- lass/1systems/prism/physical.nix | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'lass/1systems/prism') diff --git a/lass/1systems/prism/physical.nix b/lass/1systems/prism/physical.nix index ebc80411b..d4dd88382 100644 --- a/lass/1systems/prism/physical.nix +++ b/lass/1systems/prism/physical.nix @@ -9,6 +9,7 @@ boot.initrd.availableKernelModules = [ "xhci_pci" "ahci" "sd_mod" ]; boot.kernelModules = [ "kvm-intel" ]; + boot.swraid.enable = true; fileSystems."/" = { device = "rpool/root/nixos"; @@ -80,7 +81,7 @@ # we don't pay for power there and this might solve a problem we observed at least once # https://www.thomas-krenn.com/de/wiki/PCIe_Bus_Error_Status_00001100_beheben - boot.kernelParams = [ "pcie_aspm=off" "net.ifnames=0" ]; + boot.kernelParams = [ "pcie_aspm=off" "net.ifnames=0" "nomodeset" ]; networking.dhcpcd.enable = false; -- cgit v1.2.3 From 9bc7ad4afe727660f05c037386d0a00f5625801a Mon Sep 17 00:00:00 2001 From: lassulus Date: Thu, 31 Aug 2023 17:47:17 +0200 Subject: l prism.r: add backups --- lass/1systems/prism/backup.nix | 37 +++++++++++++++++++++++++++++++++++++ lass/1systems/prism/config.nix | 1 + 2 files changed, 38 insertions(+) create mode 100644 lass/1systems/prism/backup.nix (limited to 'lass/1systems/prism') diff --git a/lass/1systems/prism/backup.nix b/lass/1systems/prism/backup.nix new file mode 100644 index 000000000..52b4142b9 --- /dev/null +++ b/lass/1systems/prism/backup.nix @@ -0,0 +1,37 @@ +{ config, lib, pkgs, ... }: +{ + services.postgresqlBackup.enable = true; + + systemd.services.borgbackup-job-hetzner.serviceConfig.ReadWritePaths = [ "/var/log/telegraf" ]; + + services.borgbackup.jobs.hetzner = { + paths = [ + "/var/backup" + ]; + exclude = [ + "*.pyc" + ]; + repo = "u364341@u364341.your-storagebox.de:/./hetzner"; + encryption.mode = "none"; + compression = "auto,zstd"; + startAt = "daily"; + # TODO: change backup key + environment.BORG_RSH = "ssh -oPort=23 -i ${toString + "/borgbackup.ssh.id25519"}"; + preHook = '' + set -x + ''; + + postHook = '' + cat > /var/log/telegraf/borgbackup-job-hetzner.service <; { imports = [ + ./backup.nix -- cgit v1.2.3 From c1656131473f63e415baae35e99507dbb1c780a4 Mon Sep 17 00:00:00 2001 From: lassulus Date: Sun, 3 Sep 2023 11:43:01 +0200 Subject: l prism.r: remove xanf disk --- lass/1systems/prism/physical.nix | 5 ----- 1 file changed, 5 deletions(-) (limited to 'lass/1systems/prism') diff --git a/lass/1systems/prism/physical.nix b/lass/1systems/prism/physical.nix index d4dd88382..2260aa648 100644 --- a/lass/1systems/prism/physical.nix +++ b/lass/1systems/prism/physical.nix @@ -61,11 +61,6 @@ fsType = "zfs"; }; - fileSystems."/home/xanf" = { - device = "/dev/disk/by-id/wwn-0x500a07511becb076"; - fsType = "ext4"; - }; - # silence mdmonitor.service failures # https://github.com/NixOS/nixpkgs/issues/72394 environment.etc."mdadm.conf".text = '' -- cgit v1.2.3 From 21f62c5352b3c291bbcb61bcc0a9bdfefa502696 Mon Sep 17 00:00:00 2001 From: lassulus Date: Mon, 4 Sep 2023 10:14:48 +0200 Subject: l prism.r: use new telegraf.nix location --- lass/1systems/prism/config.nix | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'lass/1systems/prism') diff --git a/lass/1systems/prism/config.nix b/lass/1systems/prism/config.nix index 0e58b62b8..40c721e18 100644 --- a/lass/1systems/prism/config.nix +++ b/lass/1systems/prism/config.nix @@ -9,7 +9,7 @@ with import ; - + { services.nginx.enable = true; imports = [ -- cgit v1.2.3 From 78569fbc7e35fab8a3601dca30424b17d46e7e9b Mon Sep 17 00:00:00 2001 From: lassulus Date: Mon, 4 Sep 2023 10:15:23 +0200 Subject: l prism.r: remove jeschli user --- lass/1systems/prism/config.nix | 34 ---------------------------------- 1 file changed, 34 deletions(-) (limited to 'lass/1systems/prism') diff --git a/lass/1systems/prism/config.nix b/lass/1systems/prism/config.nix index 40c721e18..5502dd04c 100644 --- a/lass/1systems/prism/config.nix +++ b/lass/1systems/prism/config.nix @@ -159,40 +159,6 @@ with import ; ''; }; } - { - users.users.jeschli = { - uid = genid_uint31 "jeschli"; - isNormalUser = true; - openssh.authorizedKeys.keys = with config.krebs.users; [ - jeschli.pubkey - jeschli-bln.pubkey - jeschli-bolide.pubkey - jeschli-brauerei.pubkey - ]; - }; - krebs.git.rules = [ - { - user = with config.krebs.users; [ - jeschli - jeschli-bln - jeschli-bolide - jeschli-brauerei - ]; - repo = [ config.krebs.git.repos.xmonad-stockholm ]; - perm = with git; push "refs/heads/jeschli*" [ fast-forward non-fast-forward create delete merge ]; - } - { - user = with config.krebs.users; [ - jeschli - jeschli-bln - jeschli-bolide - jeschli-brauerei - ]; - repo = [ config.krebs.git.repos.stockholm ]; - perm = with git; push "refs/heads/staging/jeschli*" [ fast-forward non-fast-forward create delete merge ]; - } - ]; - } { krebs.repo-sync.repos.stockholm.timerConfig = { OnBootSec = "5min"; -- cgit v1.2.3 From d9c8a90feaf41d74a383c0d6a146aca4c92d4f47 Mon Sep 17 00:00:00 2001 From: lassulus Date: Mon, 4 Sep 2023 10:15:36 +0200 Subject: l prism.r: remove taskserver --- lass/1systems/prism/config.nix | 12 ------------ 1 file changed, 12 deletions(-) (limited to 'lass/1systems/prism') diff --git a/lass/1systems/prism/config.nix b/lass/1systems/prism/config.nix index 5502dd04c..aaabd655d 100644 --- a/lass/1systems/prism/config.nix +++ b/lass/1systems/prism/config.nix @@ -169,18 +169,6 @@ with import ; - { - services.taskserver = { - enable = true; - fqdn = "lassul.us"; - listenHost = "::"; - listenPort = 53589; - organisations.lass.users = [ "lass" "android" ]; - }; - krebs.iptables.tables.filter.INPUT.rules = [ - { predicate = "-p tcp --dport 53589"; target = "ACCEPT"; } - ]; - } { environment.systemPackages = [ pkgs.cryptsetup ]; -- cgit v1.2.3 From 7757553259fdc426b2a450a0af439e69d290e564 Mon Sep 17 00:00:00 2001 From: lassulus Date: Mon, 4 Sep 2023 10:15:45 +0200 Subject: l prism.r: disable searx --- lass/1systems/prism/config.nix | 1 - 1 file changed, 1 deletion(-) (limited to 'lass/1systems/prism') diff --git a/lass/1systems/prism/config.nix b/lass/1systems/prism/config.nix index aaabd655d..909eedc92 100644 --- a/lass/1systems/prism/config.nix +++ b/lass/1systems/prism/config.nix @@ -168,7 +168,6 @@ with import ; } - { environment.systemPackages = [ pkgs.cryptsetup ]; -- cgit v1.2.3 From 759c63246af4af49e4cdeee329d065879f92ef2d Mon Sep 17 00:00:00 2001 From: lassulus Date: Mon, 4 Sep 2023 10:16:04 +0200 Subject: l prism.r: remove hotdog --- lass/1systems/prism/config.nix | 18 ------------------ 1 file changed, 18 deletions(-) (limited to 'lass/1systems/prism') diff --git a/lass/1systems/prism/config.nix b/lass/1systems/prism/config.nix index 909eedc92..46e35de4f 100644 --- a/lass/1systems/prism/config.nix +++ b/lass/1systems/prism/config.nix @@ -80,24 +80,6 @@ with import ; openssh.authorizedKeys.keys = [ "ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAACAQDQFaYOWRUvHP6I37q9Dd4PJOq8FNQqAeJZ8pLx0G62uC450kbPGcG80rHHvXmk7HqQP6biJmMg48bOsvXAScPot2Qhp1Qc35CuUqVhLiTvUAsi8l/iJjhjZ23yRGDCAmW5+JIOzIvECkcbMnG7YoYAQ9trNGHe9qwGzQGhpt3QVClE23WtE3PVKRLQx1VbiabSnAm6tXVd2zpUoSdpWt8Gpi2taM4XXJ5+l744MNxFHvDapN5xqpYzwrA34Ii13jNLWcGbtgxESpR+VjnamdWByrkBsW4X5/xn2K1I1FrujaM/DBHV1QMaDKst9V8+uL5X7aYNt0OUBu2eyZdg6aujY2BYovB9uRyR1JIuSbA/a54MM96yN9WirMUufJF/YZrV0L631t9EW8ORyWUo1GRzMuBHVHQlfApj7NCU/jEddUuTqKgwyRgTmMFMUI4M0tRULAB/7pBE1Vbcx9tg6RsKIk8VkskfbBJW9Y6Sx6YoFlxPdgMNIrBefqEjIV62piP7YLMlvfIDCJ7TNd9dLN86XGggZ/nD5zt6SL1o61vVnw9If8pHosppxADPJsJvcdN6fOe16/tFAeE0JRo0jTcyFVTBGfhpey+rFfuW8wtUyuO5WPUxkOn7xMHGMWHJAtWX2vwVIDtLxvqn48B4SmEOpPD6ii+vcpwqAex3ycqBUQ==" ]; }; } - { - #hotdog - systemd.services."container@hotdog".reloadIfChanged = mkForce false; - containers.hotdog = { - config = { ... }: { - environment.systemPackages = [ pkgs.git ]; - services.openssh.enable = true; - users.users.root.openssh.authorizedKeys.keys = [ - config.krebs.users.lass.pubkey - ]; - }; - autoStart = false; - enableTun = true; - privateNetwork = true; - hostAddress = "10.233.2.1"; - localAddress = "10.233.2.2"; - }; - } { services.nginx.virtualHosts."radio.lassul.us" = { enableACME = true; -- cgit v1.2.3 From 9e2adb53bf35e958eddbb369cba1adb3eda92bc6 Mon Sep 17 00:00:00 2001 From: lassulus Date: Mon, 4 Sep 2023 10:16:38 +0200 Subject: l prism.r: remove red --- lass/1systems/prism/config.nix | 22 ---------------------- 1 file changed, 22 deletions(-) (limited to 'lass/1systems/prism') diff --git a/lass/1systems/prism/config.nix b/lass/1systems/prism/config.nix index 46e35de4f..797e4e3ed 100644 --- a/lass/1systems/prism/config.nix +++ b/lass/1systems/prism/config.nix @@ -151,28 +151,6 @@ with import ; - { - environment.systemPackages = [ pkgs.cryptsetup ]; - systemd.services."container@red".reloadIfChanged = mkForce false; - containers.red = { - config = { ... }: { - environment.systemPackages = [ pkgs.git ]; - services.openssh.enable = true; - users.users.root.openssh.authorizedKeys.keys = [ - config.krebs.users.lass.pubkey - ]; - }; - autoStart = false; - enableTun = true; - privateNetwork = true; - hostAddress = "10.233.2.3"; - localAddress = "10.233.2.4"; - }; - } - { - users.users.download.openssh.authorizedKeys.keys = [ - ]; - } { lass.nichtparasoup.enable = true; services.nginx = { -- cgit v1.2.3 From c05b4517786b63516a18b834af895af39f7e6918 Mon Sep 17 00:00:00 2001 From: lassulus Date: Mon, 4 Sep 2023 10:16:58 +0200 Subject: l prism.r: increase wiregrill network size --- lass/1systems/prism/config.nix | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'lass/1systems/prism') diff --git a/lass/1systems/prism/config.nix b/lass/1systems/prism/config.nix index 797e4e3ed..03c673caa 100644 --- a/lass/1systems/prism/config.nix +++ b/lass/1systems/prism/config.nix @@ -169,7 +169,7 @@ with import ; ]; krebs.iptables.tables.nat.PREROUTING.rules = mkOrder 999 [ - { v6 = false; predicate = "-s 10.244.1.0/24"; target = "ACCEPT"; } + { v6 = false; predicate = "-s 10.244.0.0/16"; target = "ACCEPT"; } { v4 = false; predicate = "-s 42:1::/32"; target = "ACCEPT"; } ]; krebs.iptables.tables.filter.FORWARD.rules = mkBefore [ @@ -178,7 +178,7 @@ with import ; ]; krebs.iptables.tables.nat.POSTROUTING.rules = [ { v4 = false; predicate = "-s 42:1::/32 ! -d 42:1::/48"; target = "MASQUERADE"; } - { v6 = false; predicate = "-s 10.244.1.0/24 ! -d 10.244.1.0/24"; target = "MASQUERADE"; } + { v6 = false; predicate = "-s 10.244.0.0/16 ! -d 10.244.0.0/16"; target = "MASQUERADE"; } ]; services.dnsmasq = { enable = true; -- cgit v1.2.3 From 0e34328a449486325882a95d9b08f66eec7105a2 Mon Sep 17 00:00:00 2001 From: lassulus Date: Mon, 4 Sep 2023 10:17:29 +0200 Subject: l prism.r: listen dnsmasq on all internal interfaces --- lass/1systems/prism/config.nix | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'lass/1systems/prism') diff --git a/lass/1systems/prism/config.nix b/lass/1systems/prism/config.nix index 03c673caa..db53ae22d 100644 --- a/lass/1systems/prism/config.nix +++ b/lass/1systems/prism/config.nix @@ -185,9 +185,9 @@ with import ; resolveLocalQueries = false; extraConfig= '' - listen-address=42:1:ce16::1,10.244.1.103 - except-interface=lo + bind-interfaces interface=wiregrill + interface=retiolum ''; }; } -- cgit v1.2.3 From 6700eb015e8581386c5452c854da1f68a6f372a4 Mon Sep 17 00:00:00 2001 From: lassulus Date: Mon, 4 Sep 2023 10:17:57 +0200 Subject: l prism.r: disable yellow --- lass/1systems/prism/config.nix | 15 --------------- 1 file changed, 15 deletions(-) (limited to 'lass/1systems/prism') diff --git a/lass/1systems/prism/config.nix b/lass/1systems/prism/config.nix index db53ae22d..26eb17a71 100644 --- a/lass/1systems/prism/config.nix +++ b/lass/1systems/prism/config.nix @@ -199,21 +199,6 @@ with import ; { - systemd.services."container@yellow".reloadIfChanged = mkForce false; - containers.yellow = { - config = { ... }: { - environment.systemPackages = [ pkgs.git ]; - services.openssh.enable = true; - users.users.root.openssh.authorizedKeys.keys = [ - config.krebs.users.lass.pubkey - ]; - }; - autoStart = false; - enableTun = true; - privateNetwork = true; - hostAddress = "10.233.2.13"; - localAddress = "10.233.2.14"; - }; services.nginx.virtualHosts."jelly.r" = { locations."/".extraConfig = '' -- cgit v1.2.3 From 53b6ca655127488e4a160d4f570bc839728b515f Mon Sep 17 00:00:00 2001 From: lassulus Date: Mon, 4 Sep 2023 10:18:42 +0200 Subject: l prism.r: disable jelly.r and flix.r --- lass/1systems/prism/config.nix | 11 ----------- 1 file changed, 11 deletions(-) (limited to 'lass/1systems/prism') diff --git a/lass/1systems/prism/config.nix b/lass/1systems/prism/config.nix index 26eb17a71..4cc72d2f0 100644 --- a/lass/1systems/prism/config.nix +++ b/lass/1systems/prism/config.nix @@ -200,17 +200,6 @@ with import ; { - services.nginx.virtualHosts."jelly.r" = { - locations."/".extraConfig = '' - proxy_pass http://10.233.2.14:8096/; - proxy_set_header Accept-Encoding ""; - ''; - }; - services.nginx.virtualHosts."flix.r" = { - locations."/".extraConfig = '' - proxy_pass http://10.233.2.14:80/; - proxy_set_header Accept-Encoding ""; - ''; }; services.nginx.virtualHosts."lassul.us" = { locations."^~ /flix/".extraConfig = '' -- cgit v1.2.3 From dcb9216d5c5e916378cca66aa09960a108d7b05e Mon Sep 17 00:00:00 2001 From: lassulus Date: Mon, 4 Sep 2023 10:19:12 +0200 Subject: l prism.r: proxy flix to yellow.r --- lass/1systems/prism/config.nix | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) (limited to 'lass/1systems/prism') diff --git a/lass/1systems/prism/config.nix b/lass/1systems/prism/config.nix index 4cc72d2f0..0753b69b5 100644 --- a/lass/1systems/prism/config.nix +++ b/lass/1systems/prism/config.nix @@ -200,6 +200,14 @@ with import ; { + services.nginx.virtualHosts."flix.lassul.us" = { + forceSSL = true; + enableACME = true; + locations."/" = { + proxyPass = "http://yellow.r:8096"; + proxyWebsockets = true; + recommendedProxySettings = true; + }; }; services.nginx.virtualHosts."lassul.us" = { locations."^~ /flix/".extraConfig = '' @@ -210,7 +218,7 @@ with import ; auth_basic_user_file ${pkgs.writeText "flix-user-pass" '' krebs:$apr1$1Fwt/4T0$YwcUn3OBmtmsGiEPlYWyq0 ''}; - proxy_pass http://10.233.2.14:80/; + proxy_pass http://yellow.r:80/; proxy_set_header Accept-Encoding ""; sub_filter "https://lassul.us/" "https://lassul.us/flix/"; sub_filter_once off; -- cgit v1.2.3 From 472e71f1d67e9df8ba5248bcf0854dc475fdb95b Mon Sep 17 00:00:00 2001 From: lassulus Date: Mon, 4 Sep 2023 10:19:43 +0200 Subject: l prism.r: allow samba from wiregrill --- lass/1systems/prism/config.nix | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'lass/1systems/prism') diff --git a/lass/1systems/prism/config.nix b/lass/1systems/prism/config.nix index 0753b69b5..e93183c9e 100644 --- a/lass/1systems/prism/config.nix +++ b/lass/1systems/prism/config.nix @@ -292,7 +292,7 @@ with import ; netbios name = PRISM server string = ${config.networking.hostName} # only allow retiolum addresses - hosts allow = 42::/16 10.243.0.0/16 + hosts allow = 42::/16 10.243.0.0/16 10.244.0.0/16 # Use sendfile() for performance gain use sendfile = true @@ -334,13 +334,13 @@ with import ; krebs.iptables.tables.filter.INPUT.rules = [ # smbd { predicate = "-i retiolum -p tcp --dport 445"; target = "ACCEPT"; } - { predicate = "-i retiolum -p tcp --dport 111"; target = "ACCEPT"; } { predicate = "-i retiolum -p udp --dport 111"; target = "ACCEPT"; } { predicate = "-i retiolum -p tcp --dport 2049"; target = "ACCEPT"; } { predicate = "-i retiolum -p udp --dport 2049"; target = "ACCEPT"; } { predicate = "-i retiolum -p tcp --dport 4000:4002"; target = "ACCEPT"; } { predicate = "-i retiolum -p udp --dport 4000:4002"; target = "ACCEPT"; } + { predicate = "-i wiregrill -p tcp --dport 445"; target = "ACCEPT"; } { predicate = "-i wiregrill -p tcp --dport 111"; target = "ACCEPT"; } { predicate = "-i wiregrill -p udp --dport 111"; target = "ACCEPT"; } { predicate = "-i wiregrill -p tcp --dport 2049"; target = "ACCEPT"; } -- cgit v1.2.3 From 591680e58f94e2fc6a65378c0baf190c2f2a5b68 Mon Sep 17 00:00:00 2001 From: lassulus Date: Mon, 4 Sep 2023 10:24:39 +0200 Subject: l prism.r: remove mic92 & shannan users --- lass/1systems/prism/config.nix | 19 ------------------- 1 file changed, 19 deletions(-) (limited to 'lass/1systems/prism') diff --git a/lass/1systems/prism/config.nix b/lass/1systems/prism/config.nix index e93183c9e..990dac091 100644 --- a/lass/1systems/prism/config.nix +++ b/lass/1systems/prism/config.nix @@ -349,25 +349,6 @@ with import ; { predicate = "-i wiregrill -p udp --dport 4000:4002"; target = "ACCEPT"; } ]; } - { - users.users.shannan = { - uid = genid_uint31 "shannan"; - isNormalUser = true; - openssh.authorizedKeys.keys = [ - config.krebs.users.shannan.pubkey - ]; - }; - } - { - nix.trustedUsers = [ "mic92" ]; - users.users.mic92 = { - uid = genid_uint31 "mic92"; - isNormalUser = true; - openssh.authorizedKeys.keys = [ - config.krebs.users.mic92.pubkey - ]; - }; - } ]; krebs.build.host = config.krebs.hosts.prism; -- cgit v1.2.3 From 941203838900b2b46847022e1173af0a0e24828e Mon Sep 17 00:00:00 2001 From: lassulus Date: Mon, 4 Sep 2023 12:35:35 +0200 Subject: l prism.r: cleanup --- lass/1systems/prism/config.nix | 18 +++++++----------- 1 file changed, 7 insertions(+), 11 deletions(-) (limited to 'lass/1systems/prism') diff --git a/lass/1systems/prism/config.nix b/lass/1systems/prism/config.nix index 990dac091..7234e7f22 100644 --- a/lass/1systems/prism/config.nix +++ b/lass/1systems/prism/config.nix @@ -9,7 +9,9 @@ with import ; + + { services.nginx.enable = true; imports = [ @@ -114,11 +116,9 @@ with import ; - - @@ -139,13 +139,9 @@ with import ; "= /wallpaper.png".extraConfig = '' alias /var/realwallpaper/realwallpaper.png; ''; - }; - } - { - krebs.repo-sync.repos.stockholm.timerConfig = { - OnBootSec = "5min"; - OnUnitInactiveSec = "2min"; - RandomizedDelaySec = "2min"; + "= /wallpaper-stars-berlin.png".extraConfig = '' + alias /var/realwallpaper/realwallpaper-krebs-stars-berlin.png; + ''; }; } @@ -196,8 +192,8 @@ with import ; { predicate = "-p udp --dport 60000:61000"; target = "ACCEPT"; } ]; } + - { services.nginx.virtualHosts."flix.lassul.us" = { @@ -243,7 +239,7 @@ with import ; users.groups.download = {}; users.users = { download = { - createHome = true; + createHome = false; group = "download"; name = "download"; home = "/var/download"; -- cgit v1.2.3 From 60b4a4c2253b9b7d4da42c39dec7fa5c7e4991d2 Mon Sep 17 00:00:00 2001 From: lassulus Date: Mon, 4 Sep 2023 12:36:02 +0200 Subject: l prism.r: add migration config --- lass/1systems/prism/config.nix | 19 +++++++++++++++++++ 1 file changed, 19 insertions(+) (limited to 'lass/1systems/prism') diff --git a/lass/1systems/prism/config.nix b/lass/1systems/prism/config.nix index 7234e7f22..29244f8a3 100644 --- a/lass/1systems/prism/config.nix +++ b/lass/1systems/prism/config.nix @@ -345,6 +345,25 @@ with import ; { predicate = "-i wiregrill -p udp --dport 4000:4002"; target = "ACCEPT"; } ]; } + { # acme fallback for neoprism migration + services.nginx.virtualHosts."lassul.us".acmeFallbackHost = "orange.r"; + services.nginx.virtualHosts."radio.lassul.us".acmeFallbackHost = "neoprism.r"; + services.nginx.virtualHosts."flix.lassul.us".acmeFallbackHost = "neoprism.r"; + services.nginx.virtualHosts."jitsi.lassul.us".acmeFallbackHost = "neoprism.r"; + services.nginx.virtualHosts."cgit.lassul.us".acmeFallbackHost = "orange.r"; + services.nginx.virtualHosts."mail.lassul.us".acmeFallbackHost = "neoprism.r"; + services.nginx.virtualHosts."mumble.lassul.us".acmeFallbackHost = "neoprism.r"; + services.nginx.virtualHosts."mail.ubikmedia.eu" = { + enableACME = true; + forceSSL = true; + acmeFallbackHost = "ubik.r"; + locations."/" = { + recommendedProxySettings = true; + proxyWebsockets = true; + proxyPass = "https://ubik.r"; + }; + }; + } ]; krebs.build.host = config.krebs.hosts.prism; -- cgit v1.2.3 From f55307fd73af235069744dd5155fda0bc73fe613 Mon Sep 17 00:00:00 2001 From: lassulus Date: Thu, 7 Sep 2023 12:26:31 +0200 Subject: lass: migrate away --- lass/1systems/prism/backup.nix | 37 ---- lass/1systems/prism/config.nix | 380 --------------------------------------- lass/1systems/prism/physical.nix | 107 ----------- 3 files changed, 524 deletions(-) delete mode 100644 lass/1systems/prism/backup.nix delete mode 100644 lass/1systems/prism/config.nix delete mode 100644 lass/1systems/prism/physical.nix (limited to 'lass/1systems/prism') diff --git a/lass/1systems/prism/backup.nix b/lass/1systems/prism/backup.nix deleted file mode 100644 index 52b4142b9..000000000 --- a/lass/1systems/prism/backup.nix +++ /dev/null @@ -1,37 +0,0 @@ -{ config, lib, pkgs, ... }: -{ - services.postgresqlBackup.enable = true; - - systemd.services.borgbackup-job-hetzner.serviceConfig.ReadWritePaths = [ "/var/log/telegraf" ]; - - services.borgbackup.jobs.hetzner = { - paths = [ - "/var/backup" - ]; - exclude = [ - "*.pyc" - ]; - repo = "u364341@u364341.your-storagebox.de:/./hetzner"; - encryption.mode = "none"; - compression = "auto,zstd"; - startAt = "daily"; - # TODO: change backup key - environment.BORG_RSH = "ssh -oPort=23 -i ${toString + "/borgbackup.ssh.id25519"}"; - preHook = '' - set -x - ''; - - postHook = '' - cat > /var/log/telegraf/borgbackup-job-hetzner.service <; - -{ - imports = [ - ./backup.nix - - - - - - - - - { - services.nginx.enable = true; - imports = [ - - ]; - # needed by domsen.nix ^^ - lass.usershadow = { - enable = true; - }; - - krebs.iptables.tables.filter.INPUT.rules = [ - { predicate = "-p tcp --dport http"; target = "ACCEPT"; } - { predicate = "-p tcp --dport https"; target = "ACCEPT"; } - ]; - } - { # TODO make new hfos.nix out of this vv - users.users.riot = { - uid = genid_uint31 "riot"; - isNormalUser = true; - extraGroups = [ "libvirtd" ]; - openssh.authorizedKeys.keys = [ - "ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAABAQC6o6sdTu/CX1LW2Ff5bNDqGEAGwAsjf0iIe5DCdC7YikCct+7x4LTXxY+nDlPMeGcOF88X9/qFwdyh+9E4g0nUAZaeL14Uc14QDqDt/aiKjIXXTepxE/i4JD9YbTqStAnA/HYAExU15yqgUdj2dnHu7OZcGxk0ZR1OY18yclXq7Rq0Fd3pN3lPP1T4QHM9w66r83yJdFV9szvu5ral3/QuxQnCNohTkR6LoJ4Ny2RbMPTRtb+jPbTQYTWUWwV69mB8ot5nRTP4MRM9pu7vnoPF4I2S5DvSnx4C5zdKzsb7zmIvD4AmptZLrXj4UXUf00Xf7Js5W100Ne2yhYyhq+35 riot@lagrange" - ]; - }; - krebs.iptables.tables.filter.FORWARD.rules = mkBefore [ - { v6 = false; predicate = "--destination 95.216.1.130"; target = "ACCEPT"; } - { v6 = false; predicate = "--source 95.216.1.130"; target = "ACCEPT"; } - ]; - } - { - users.users.tv = { - uid = genid_uint31 "tv"; - isNormalUser = true; - openssh.authorizedKeys.keys = [ - config.krebs.users.tv.pubkey - ]; - }; - users.users.makefu = { - uid = genid_uint31 "makefu"; - isNormalUser = true; - openssh.authorizedKeys.keys = [ - config.krebs.users.makefu.pubkey - ]; - }; - users.extraUsers.dritter = { - uid = genid_uint31 "dritter"; - isNormalUser = true; - extraGroups = [ - "download" - ]; - openssh.authorizedKeys.keys = [ - "ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAABAQDnqOWDDk7QkSAvrSLkEoz7dY22+xPyv5JDn2zlfUndfavmTMfZvPx9REMjgULbcCSM4m3Ncf40yUjciDpVleGoEz82+p/ObHAkVWPQyXRS3ZRM2IJJultBHEFc61+61Pi8k3p5pBhPPaig6VncJ4uUuuNqen9jqLesSTVXNtdntU2IvnC8B8k1Kq6fu9q1T2yEOMxkD31D5hVHlqAly0LdRiYvtsRIoCSmRvlpGl70uvPprhQxhtoiEUeDqmIL7BG9x7gU0Swdl7R0/HtFXlFuOwSlNYDmOf/Zrb1jhOpj4AlCliGUkM0iKIJhgH0tnJna6kfkGKHDwuzITGIh6SpZ dritter@Janeway" - ]; - }; - users.extraUsers.juhulian = { - uid = 1339; - isNormalUser = true; - openssh.authorizedKeys.keys = [ - "ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAABAQDBQhLGvfv4hyQ/nqJGy1YgHXPSVl6igeWTroJSvAhUFgoh+rG+zvqY0EahKXNb3sq0/OYDCTJVuucc0hgCg7T2KqTqMtTb9EEkRmCFbD7F7DWZojCrh/an6sHneqT5eFvzAPZ8E5hup7oVQnj5P5M3I9keRHBWt1rq6q0IcOEhsFvne4qJc73aLASTJkxzlo5U8ju3JQOl6474ECuSn0lb1fTrQ/SR1NgF7jV11eBldkS8SHEB+2GXjn4Yrn+QUKOnDp+B85vZmVlJSI+7XR1/U/xIbtAjGTEmNwB6cTbBv9NCG9jloDDOZG4ZvzzHYrlBXjaigtQh2/4mrHoKa5eV juhulian@juhulian" - ]; - }; - users.users.hellrazor = { - uid = genid_uint31 "hellrazor"; - isNormalUser = true; - extraGroups = [ - "download" - ]; - openssh.authorizedKeys.keys = [ "ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAACAQDQFaYOWRUvHP6I37q9Dd4PJOq8FNQqAeJZ8pLx0G62uC450kbPGcG80rHHvXmk7HqQP6biJmMg48bOsvXAScPot2Qhp1Qc35CuUqVhLiTvUAsi8l/iJjhjZ23yRGDCAmW5+JIOzIvECkcbMnG7YoYAQ9trNGHe9qwGzQGhpt3QVClE23WtE3PVKRLQx1VbiabSnAm6tXVd2zpUoSdpWt8Gpi2taM4XXJ5+l744MNxFHvDapN5xqpYzwrA34Ii13jNLWcGbtgxESpR+VjnamdWByrkBsW4X5/xn2K1I1FrujaM/DBHV1QMaDKst9V8+uL5X7aYNt0OUBu2eyZdg6aujY2BYovB9uRyR1JIuSbA/a54MM96yN9WirMUufJF/YZrV0L631t9EW8ORyWUo1GRzMuBHVHQlfApj7NCU/jEddUuTqKgwyRgTmMFMUI4M0tRULAB/7pBE1Vbcx9tg6RsKIk8VkskfbBJW9Y6Sx6YoFlxPdgMNIrBefqEjIV62piP7YLMlvfIDCJ7TNd9dLN86XGggZ/nD5zt6SL1o61vVnw9If8pHosppxADPJsJvcdN6fOe16/tFAeE0JRo0jTcyFVTBGfhpey+rFfuW8wtUyuO5WPUxkOn7xMHGMWHJAtWX2vwVIDtLxvqn48B4SmEOpPD6ii+vcpwqAex3ycqBUQ==" ]; - }; - } - { - services.nginx.virtualHosts."radio.lassul.us" = { - enableACME = true; - addSSL = true; - locations."/" = { - # recommendedProxySettings = true; - proxyWebsockets = true; - proxyPass = "http://radio.r"; - extraConfig = '' - proxy_set_header Host radio.r; - # get source ip for weather reports - proxy_set_header user-agent "$http_user_agent; client-ip=$remote_addr"; - ''; - }; - }; - krebs.htgen.radio-redirect = { - port = 8000; - scriptFile = pkgs.writers.writeDash "redir" '' - printf 'HTTP/1.1 301 Moved Permanently\r\n' - printf "Location: http://radio.lassul.us''${Request_URI}\r\n" - printf '\r\n' - ''; - }; - krebs.iptables.tables.filter.INPUT.rules = [ - { predicate = "-p tcp --dport 8000"; target = "ACCEPT"; } - ]; - } - - - - - - - - - - - - - - - { - services.tor = { - enable = true; - }; - } - { - imports = [ - - ]; - services.nginx.virtualHosts."lassul.us".locations = { - "= /wallpaper-marker.png".extraConfig = '' - alias /var/realwallpaper/realwallpaper-marker.png; - ''; - "= /wallpaper.png".extraConfig = '' - alias /var/realwallpaper/realwallpaper.png; - ''; - "= /wallpaper-stars-berlin.png".extraConfig = '' - alias /var/realwallpaper/realwallpaper-krebs-stars-berlin.png; - ''; - }; - } - - - - { - lass.nichtparasoup.enable = true; - services.nginx = { - enable = true; - virtualHosts."lol.lassul.us" = { - forceSSL = true; - enableACME = true; - locations."/".extraConfig = '' - proxy_pass http://localhost:5001; - ''; - }; - }; - } - { - imports = [ - - ]; - krebs.iptables.tables.nat.PREROUTING.rules = mkOrder 999 [ - { v6 = false; predicate = "-s 10.244.0.0/16"; target = "ACCEPT"; } - { v4 = false; predicate = "-s 42:1::/32"; target = "ACCEPT"; } - ]; - krebs.iptables.tables.filter.FORWARD.rules = mkBefore [ - { predicate = "-i wiregrill -o retiolum"; target = "ACCEPT"; } - { predicate = "-i retiolum -o wiregrill"; target = "ACCEPT"; } - ]; - krebs.iptables.tables.nat.POSTROUTING.rules = [ - { v4 = false; predicate = "-s 42:1::/32 ! -d 42:1::/48"; target = "MASQUERADE"; } - { v6 = false; predicate = "-s 10.244.0.0/16 ! -d 10.244.0.0/16"; target = "MASQUERADE"; } - ]; - services.dnsmasq = { - enable = true; - resolveLocalQueries = false; - - extraConfig= '' - bind-interfaces - interface=wiregrill - interface=retiolum - ''; - }; - } - { - krebs.iptables.tables.filter.INPUT.rules = [ - { predicate = "-p udp --dport 60000:61000"; target = "ACCEPT"; } - ]; - } - - - { - - services.nginx.virtualHosts."flix.lassul.us" = { - forceSSL = true; - enableACME = true; - locations."/" = { - proxyPass = "http://yellow.r:8096"; - proxyWebsockets = true; - recommendedProxySettings = true; - }; - }; - services.nginx.virtualHosts."lassul.us" = { - locations."^~ /flix/".extraConfig = '' - if ($scheme != "https") { - rewrite ^ https://$host$request_uri permanent; - } - auth_basic "Restricted Content"; - auth_basic_user_file ${pkgs.writeText "flix-user-pass" '' - krebs:$apr1$1Fwt/4T0$YwcUn3OBmtmsGiEPlYWyq0 - ''}; - proxy_pass http://yellow.r:80/; - proxy_set_header Accept-Encoding ""; - sub_filter "https://lassul.us/" "https://lassul.us/flix/"; - sub_filter_once off; - ''; - locations."^~ /chatty/".extraConfig = '' - rewrite ^ https://$host/flix/$request_uri permanent; - ''; - #locations."^~ /transmission".return = "301 https://$host/transmission/web/"; - locations."^~ /transmission/".extraConfig = '' - if ($scheme != "https") { - rewrite ^ https://$host$request_uri permanent; - } - auth_basic "Restricted Content"; - auth_basic_user_file ${pkgs.writeText "transmission-user-pass" '' - krebs:$apr1$1Fwt/4T0$YwcUn3OBmtmsGiEPlYWyq0 - ''}; - proxy_pass_header X-Transmission-Session-Id; - proxy_pass http://10.233.2.14:9091; - ''; - }; - - users.groups.download = {}; - users.users = { - download = { - createHome = false; - group = "download"; - name = "download"; - home = "/var/download"; - useDefaultShell = true; - uid = genid "download"; - isSystemUser = true; - openssh.authorizedKeys.keys = with config.krebs.users; [ - lass.pubkey - lass-android.pubkey - makefu.pubkey - palo.pubkey - "ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAACAQDB0d0JA20Vqn7I4lCte6Ne2EOmLZyMJyS9yIKJYXNLjbLwkQ4AYoQKantPBkTxR75M09E7d3j5heuWnCjWH45TrfQfe1EOSSC3ppCI6C6aIVlaNs+KhAYZS0m2Y8WkKn+TT5JLEa8yybYVN/RlZPOilpj/1QgjU6CQK+eJ1k/kK+QFXcwN82GDVh5kbTVcKUNp2tiyxFA+z9LY0xFDg/JHif2ROpjJVLQBJ+YPuOXZN5LDnVcuyLWKThjxy5srQ8iDjoxBg7dwLHjby5Mv41K4W61Gq6xM53gDEgfXk4cQhJnmx7jA/pUnsn2ZQDeww3hcc7vRf8soogXXz2KC9maiq0M/svaATsa9Ul4hrKnqPZP9Q8ScSEAUX+VI+x54iWrnW0p/yqBiRAzwsczdPzaQroUFTBxrq8R/n5TFdSHRMX7fYNOeVMjhfNca/gtfw9dYBVquCvuqUuFiRc0I7yK44rrMjjVQRcAbw6F8O7+04qWCmaJ8MPlmApwu2c05VMv9hiJo5p6PnzterRSLCqF6rIdhSnuOwrUIt1s/V+EEZXHCwSaNLaQJnYL0H9YjaIuGz4c8kVzxw4c0B6nl+hqW5y5/B2cuHiumnlRIDKOIzlv8ufhh21iN7QpIsPizahPezGoT1XqvzeXfH4qryo8O4yTN/PWoA+f7o9POU7L6hQ== lhebendanz@nixos" - "AAAAB3NzaC1yc2EAAAADAQABAAABgQC4ECL9NSCWqs4KVe+FF+2BPtl5Bv5aQPHqnXllCyiESZykwRKLx6/AbF5SbUAUMVZtp9oDSdp28m3BvVeWJ/q7hAbIxUtfd/jp+JBRZ8Kj6K5GzUO7Bhgl/o0A7xEjAeOKHiYuLjdPMcFUyl6Ah4ey/mcQYf6AdU0+hYUDeUlKe/YxxYD6202W0GJq2xGdIqs/TbopT9iaX+sv0wdXDVfFY72nFqOUwJW3u6O2viKKRugrz/eo50Eo3ts7pYz/FpDXExrUvV9Vu/bQ34pa8nKgF3/AKQHgmzljNQSVZKyAV8OY0UFonjBMXCBg2tXtwfnlzdx2SyuQVv55x+0AuRKsi85G2xLpXu1A3921pseBTW6Q6kbYK9eqxAay2c/kNbwNqFnO+nCvQ6Ier/hvGddOtItMu96IuU2E7mPN6WgvM8/3fjJRFWnZxFxqu/k7iH+yYT8qwRgdiSqZc76qvkYEuabdk2itstTRY0A3SpI3hFMZDw/7bxgMZtqpfyoRk5s= philip@shiki11:15 AAAAB3NzaC1yc2EAAAADAQABAAABgQC4ECL9NSCWqs4KVe+FF+2BPtl5Bv5aQPHqnXllCyiESZykwRKLx6/AbF5SbUAUMVZtp9oDSdp28m3BvVeWJ/q7hAbIxUtfd/jp+JBRZ8Kj6K5GzUO7Bhgl/o0A7xEjAeOKHiYuLjdPMcFUyl6Ah4ey/mcQYf6AdU0+hYUDeUlKe/YxxYD6202W0GJq2xGdIqs/TbopT9iaX+sv0wdXDVfFY72nFqOUwJW3u6O2viKKRugrz/eo50Eo3ts7pYz/FpDXExrUvV9Vu/bQ34pa8nKgF3/AKQHgmzljNQSVZKyAV8OY0UFonjBMXCBg2tXtwfnlzdx2SyuQVv55x+0AuRKsi85G2xLpXu1A3921pseBTW6Q6kbYK9eqxAay2c/kNbwNqFnO+nCvQ6Ier/hvGddOtItMu96IuU2E7mPN6WgvM8/3fjJRFWnZxFxqu/k7iH+yYT8qwRgdiSqZc76qvkYEuabdk2itstTRY0A3SpI3hFMZDw/7bxgMZtqpfyoRk5s= philip@shiki" - mic92.pubkey - qubasa.pubkey - ]; - }; - }; - - system.activationScripts.downloadFolder = '' - mkdir -p /var/download - chmod 775 /var/download - ln -fnsT /var/lib/containers/yellow/var/download/finished /var/download/finished || : - chown download: /var/download/finished - ''; - - fileSystems."/export/download" = { - device = "/var/lib/containers/yellow/var/download/finished"; - options = [ "bind" ]; - }; - services.nfs.server = { - enable = true; - exports = '' - /export 42::/16(insecure,ro,crossmnt) - ''; - lockdPort = 4001; - mountdPort = 4002; - statdPort = 4000; - }; - - services.samba = { - enable = true; - enableNmbd = false; - extraConfig = '' - workgroup = WORKGROUP - netbios name = PRISM - server string = ${config.networking.hostName} - # only allow retiolum addresses - hosts allow = 42::/16 10.243.0.0/16 10.244.0.0/16 - - # Use sendfile() for performance gain - use sendfile = true - - # No NetBIOS is needed - disable netbios = true - - # Only mangle non-valid NTFS names, don't care about DOS support - mangled names = illegal - - # Performance optimizations - socket options = TCP_NODELAY IPTOS_LOWDELAY SO_RCVBUF=65536 SO_SNDBUF=65536 - - # Disable all printing - load printers = false - disable spoolss = true - printcap name = /dev/null - - map to guest = Bad User - max log size = 50 - dns proxy = no - security = user - - [global] - syslog only = yes - ''; - shares.public = { - comment = "Warez"; - path = "/export"; - public = "yes"; - "only guest" = "yes"; - "create mask" = "0644"; - "directory mask" = "2777"; - writable = "no"; - printable = "no"; - }; - }; - - krebs.iptables.tables.filter.INPUT.rules = [ - # smbd - { predicate = "-i retiolum -p tcp --dport 445"; target = "ACCEPT"; } - { predicate = "-i retiolum -p tcp --dport 111"; target = "ACCEPT"; } - { predicate = "-i retiolum -p udp --dport 111"; target = "ACCEPT"; } - { predicate = "-i retiolum -p tcp --dport 2049"; target = "ACCEPT"; } - { predicate = "-i retiolum -p udp --dport 2049"; target = "ACCEPT"; } - { predicate = "-i retiolum -p tcp --dport 4000:4002"; target = "ACCEPT"; } - { predicate = "-i retiolum -p udp --dport 4000:4002"; target = "ACCEPT"; } - { predicate = "-i wiregrill -p tcp --dport 445"; target = "ACCEPT"; } - { predicate = "-i wiregrill -p tcp --dport 111"; target = "ACCEPT"; } - { predicate = "-i wiregrill -p udp --dport 111"; target = "ACCEPT"; } - { predicate = "-i wiregrill -p tcp --dport 2049"; target = "ACCEPT"; } - { predicate = "-i wiregrill -p udp --dport 2049"; target = "ACCEPT"; } - { predicate = "-i wiregrill -p tcp --dport 4000:4002"; target = "ACCEPT"; } - { predicate = "-i wiregrill -p udp --dport 4000:4002"; target = "ACCEPT"; } - ]; - } - { # acme fallback for neoprism migration - services.nginx.virtualHosts."lassul.us".acmeFallbackHost = "orange.r"; - services.nginx.virtualHosts."radio.lassul.us".acmeFallbackHost = "neoprism.r"; - services.nginx.virtualHosts."flix.lassul.us".acmeFallbackHost = "neoprism.r"; - services.nginx.virtualHosts."jitsi.lassul.us".acmeFallbackHost = "neoprism.r"; - services.nginx.virtualHosts."cgit.lassul.us".acmeFallbackHost = "orange.r"; - services.nginx.virtualHosts."mail.lassul.us".acmeFallbackHost = "neoprism.r"; - services.nginx.virtualHosts."mumble.lassul.us".acmeFallbackHost = "neoprism.r"; - services.nginx.virtualHosts."mail.ubikmedia.eu" = { - enableACME = true; - forceSSL = true; - acmeFallbackHost = "ubik.r"; - locations."/" = { - recommendedProxySettings = true; - proxyWebsockets = true; - proxyPass = "https://ubik.r"; - }; - }; - } - ]; - - krebs.build.host = config.krebs.hosts.prism; - services.earlyoom = { - enable = true; - freeMemThreshold = 5; - }; - - # prism rsa hack - services.openssh.hostKeys = [{ - path = toString + "ssh.id_rsa"; - type = "rsa"; - }]; -} diff --git a/lass/1systems/prism/physical.nix b/lass/1systems/prism/physical.nix deleted file mode 100644 index 2260aa648..000000000 --- a/lass/1systems/prism/physical.nix +++ /dev/null @@ -1,107 +0,0 @@ -{ config, lib, pkgs, ... }: - -{ - - imports = [ - ./config.nix - - ]; - - boot.initrd.availableKernelModules = [ "xhci_pci" "ahci" "sd_mod" ]; - boot.kernelModules = [ "kvm-intel" ]; - boot.swraid.enable = true; - - fileSystems."/" = { - device = "rpool/root/nixos"; - fsType = "zfs"; - }; - - fileSystems."/boot" = { - device = "/dev/disk/by-uuid/d155d6ff-8e89-4876-a9e7-d1b7ba6a4804"; - fsType = "ext4"; - }; - - fileSystems."/backups" = { - device = "tank/backups"; - fsType = "zfs"; - }; - - fileSystems."/srv/http" = { - device = "tank/srv-http"; - fsType = "zfs"; - }; - - fileSystems."/var/download" = { - device = "tank/download"; - fsType = "zfs"; - }; - - fileSystems."/var/lib/containers" = { - device = "tank/containers"; - fsType = "zfs"; - }; - - fileSystems."/home" = { - device = "tank/home"; - fsType = "zfs"; - }; - - fileSystems."/var/lib/nextcloud" = { - device = "tank/nextcloud"; - fsType = "zfs"; - }; - - fileSystems."/var/lib/libvirt" = { - device = "tank/libvirt"; - fsType = "zfs"; - }; - - fileSystems."/var/realwallpaper/archive" = { - device = "tank/wallpaper"; - fsType = "zfs"; - }; - - # silence mdmonitor.service failures - # https://github.com/NixOS/nixpkgs/issues/72394 - environment.etc."mdadm.conf".text = '' - MAILADDR root - ''; - - nix.maxJobs = lib.mkDefault 8; - powerManagement.cpuFreqGovernor = lib.mkDefault "powersave"; - - boot.loader.grub.enable = true; - boot.loader.grub.version = 2; - boot.loader.grub.devices = [ "/dev/sda" "/dev/sdb" ]; - - # we don't pay for power there and this might solve a problem we observed at least once - # https://www.thomas-krenn.com/de/wiki/PCIe_Bus_Error_Status_00001100_beheben - boot.kernelParams = [ "pcie_aspm=off" "net.ifnames=0" "nomodeset" ]; - networking.dhcpcd.enable = false; - - - networking.useNetworkd = lib.mkForce false; - systemd.network.enable = lib.mkForce false; - # bridge config - networking.bridges."ext-br".interfaces = [ "eth0" ]; - networking = { - hostId = "2283aaae"; - defaultGateway = "95.216.1.129"; - defaultGateway6 = { address = "fe80::1"; interface = "ext-br"; }; - # Use google's public DNS server - nameservers = [ "8.8.8.8" ]; - interfaces.ext-br.ipv4.addresses = [ - { - address = "95.216.1.150"; - prefixLength = 26; - } - ]; - interfaces.ext-br.ipv6.addresses = [ - { - address = "2a01:4f9:2a:1e9::1"; - prefixLength = 64; - } - ]; - }; - -} -- cgit v1.2.3