From fa75913e4e8051c5e5942eb10874fcf266f69d81 Mon Sep 17 00:00:00 2001 From: Vegard Bieker Matthey Date: Sun, 18 Jan 2026 20:33:07 +0100 Subject: [PATCH] initial --- hosts/gluttony/configuration.nix | 53 +++++++++++++++++++++++ hosts/gluttony/hardware-configuration.nix | 45 +++++++++++++++++++ 2 files changed, 98 insertions(+) create mode 100644 hosts/gluttony/configuration.nix create mode 100644 hosts/gluttony/hardware-configuration.nix diff --git a/hosts/gluttony/configuration.nix b/hosts/gluttony/configuration.nix new file mode 100644 index 0000000..36320ef --- /dev/null +++ b/hosts/gluttony/configuration.nix @@ -0,0 +1,53 @@ +{ + config, + fp, + pkgs, + lib, + values, + ... +}: +{ + imports = [ + ./hardware-configuration.nix + (fp /base) + ]; + + boot.loader.systemd-boot.enable = true; + boot.loader.efi.canTouchEfiVariables = true; + + systemd.network.enable = lib.mkForce false; + networking = + let + hostConf = values.hosts.gluttony; + in + { + hostName = "gluttony"; + tempAddresses = "disabled"; + useDHCP = lib.mkForce true; + + search = values.defaultNetworkConfig.domains; + nameservers = values.defaultNetworkConfig.dns; + defaultGateway.address = hostConf.ipv4_internal_gw; + + interfaces."ens3" = { + ipv4.addresses = [ + { + address = hostConf.ipv4; + prefixLength = 32; + } + { + address = hostConf.ipv4_internal; + prefixLength = 24; + } + ]; + ipv6.addresses = [ + { + address = hostConf.ipv6; + prefixLength = 64; + } + ]; + }; + }; + + system.stateVersion = "25.11"; # Don't change unless you know what you are doing. +} diff --git a/hosts/gluttony/hardware-configuration.nix b/hosts/gluttony/hardware-configuration.nix new file mode 100644 index 0000000..e430fe4 --- /dev/null +++ b/hosts/gluttony/hardware-configuration.nix @@ -0,0 +1,45 @@ +# Do not modify this file! It was generated by ‘nixos-generate-config’ +# and may be overwritten by future invocations. Please make changes +# to /etc/nixos/configuration.nix instead. +{ + config, + lib, + pkgs, + modulesPath, + ... +}: + +{ + imports = [ + (modulesPath + "/profiles/qemu-guest.nix") + ]; + + boot.initrd.availableKernelModules = [ + "ata_piix" + "uhci_hcd" + "virtio_pci" + "virtio_scsi" + "sd_mod" + ]; + boot.initrd.kernelModules = [ "dm-snapshot" ]; + boot.kernelModules = [ ]; + boot.extraModulePackages = [ ]; + + fileSystems."/" = { + device = "/dev/mapper/pool-root"; + fsType = "ext4"; + }; + + fileSystems."/boot" = { + device = "/dev/disk/by-uuid/D00A-B488"; + fsType = "vfat"; + options = [ + "fmask=0077" + "dmask=0077" + ]; + }; + + swapDevices = [ ]; + + nixpkgs.hostPlatform = lib.mkDefault "x86_64-linux"; +}