From 7db85847be45ece681abc39dd69746dd8089fcbf Mon Sep 17 00:00:00 2001 From: moons-14 Date: Thu, 25 Dec 2025 23:10:00 +0900 Subject: [PATCH] add hardware config --- hosts/service-1/hardware-configuration.nix | 37 ++++++++++++++++++++++ 1 file changed, 37 insertions(+) create mode 100644 hosts/service-1/hardware-configuration.nix diff --git a/hosts/service-1/hardware-configuration.nix b/hosts/service-1/hardware-configuration.nix new file mode 100644 index 0000000..2fd7fcf --- /dev/null +++ b/hosts/service-1/hardware-configuration.nix @@ -0,0 +1,37 @@ +# 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" "sr_mod" ]; + boot.initrd.kernelModules = [ ]; + boot.kernelModules = [ ]; + boot.extraModulePackages = [ ]; + + fileSystems."/" = + { device = "/dev/disk/by-uuid/d9f05715-e68a-4d69-bf46-bd903b0782f0"; + fsType = "ext4"; + }; + + fileSystems."/boot" = + { device = "/dev/disk/by-uuid/1772-FC70"; + fsType = "vfat"; + options = [ "fmask=0077" "dmask=0077" ]; + }; + + swapDevices = [ ]; + + # Enables DHCP on each ethernet and wireless interface. In case of scripted networking + # (the default) this is the recommended approach. When using systemd-networkd it's + # still possible to use this option, but it's recommended to use it in conjunction + # with explicit per-interface declarations with `networking.interfaces..useDHCP`. + networking.useDHCP = lib.mkDefault true; + # networking.interfaces.ens18.useDHCP = lib.mkDefault true; + + nixpkgs.hostPlatform = lib.mkDefault "x86_64-linux"; +}