From 08af19070e88e77f38c77bea85875b4e521c2d92 Mon Sep 17 00:00:00 2001 From: Ezri Zhu Date: Sat, 28 Sep 2024 21:45:04 -0400 Subject: [PATCH] add jude --- hosts/jude.nix | 58 ++++++++++++++++++++++++++++++++++++++++++++++++++ hosts/nova.nix | 2 +- network.nix | 9 ++++++++ 3 files changed, 68 insertions(+), 1 deletion(-) create mode 100644 hosts/jude.nix diff --git a/hosts/jude.nix b/hosts/jude.nix new file mode 100644 index 0000000..aa9cb75 --- /dev/null +++ b/hosts/jude.nix @@ -0,0 +1,58 @@ +{ config, lib, pkgs, modulesPath, ... }: + +{ + imports = + [ (modulesPath + "/profiles/qemu-guest.nix") + ]; + + boot.initrd.availableKernelModules = [ "ata_piix" "uhci_hcd" "ahci" "sd_mod" "sr_mod" ]; + boot.initrd.kernelModules = [ ]; + boot.kernelModules = [ ]; + boot.extraModulePackages = [ ]; + + fileSystems."/" = + { device = "/dev/disk/by-uuid/16a8c885-a0a5-4d22-8d59-21d29bdca98d"; + fsType = "ext4"; + }; + + nixpkgs.hostPlatform = lib.mkDefault "x86_64-linux"; + + boot.loader.grub.enable = true; + boot.loader.grub.device = "/dev/sda"; + + time.timeZone = "America/Chicago"; + i18n.defaultLocale = "en_US.UTF-8"; + services.openssh.enable = true; + networking.firewall.enable = false; + + networking = { + hostName = "jade"; + search = ["wolfgirl.systems"]; + nameservers = [ "9.9.9.10" "149.112.112.10" "2620:fe::10" "2620:fe::fe:10"]; + dhcpcd.enable = false; + interfaces.ens18.ipv4.addresses = [{ + address = "23.143.82.34"; + prefixLength = 24; + }]; + interfaces.ens18.ipv6.addresses = [{ + address = "2602:fc26:12:1::35"; + prefixLength = 48; + }]; + defaultGateway = { + address = "23.143.82.1"; + interface = "ens18"; + }; + defaultGateway6 = { + address = "2602:fc26:12::1"; + interface = "ens18"; + }; + }; + + swapDevices = [ { + device = "/swapfile"; + size = 4*1024; + randomEncryption.enable = true; + }]; + + system.stateVersion = "24.05"; +} diff --git a/hosts/nova.nix b/hosts/nova.nix index fe537fb..794fb98 100644 --- a/hosts/nova.nix +++ b/hosts/nova.nix @@ -20,7 +20,7 @@ boot.loader.grub.enable = true; boot.loader.grub.device = "/dev/vda"; - time.timeZone = "Europe/Amsterdam"; + time.timeZone = "Europe/London"; i18n.defaultLocale = "en_US.UTF-8"; services.openssh.enable = true; networking.firewall.enable = false; diff --git a/network.nix b/network.nix index 99ef69c..a6592c1 100644 --- a/network.nix +++ b/network.nix @@ -25,4 +25,13 @@ in ./common ]; }; + "jude" = { pkgs, ... }: { + deployment = { + targetHost = "23.143.82.34"; + }; + imports = [ + ./hosts/jude.nix + ./common + ]; + }; }