From 10405dbcd504cddc3ebc60be586bc2ae65f555e8 Mon Sep 17 00:00:00 2001 From: Sebastien Bourdeauducq Date: Tue, 6 Jun 2023 16:17:28 +0800 Subject: [PATCH] nixops: add juno machine --- nixops/juno-hardware-configuration.nix | 46 ++++++++++++++++++++++++++ nixops/nixops.nix | 1 + 2 files changed, 47 insertions(+) create mode 100644 nixops/juno-hardware-configuration.nix diff --git a/nixops/juno-hardware-configuration.nix b/nixops/juno-hardware-configuration.nix new file mode 100644 index 0000000..17956b6 --- /dev/null +++ b/nixops/juno-hardware-configuration.nix @@ -0,0 +1,46 @@ +# 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 + "/installer/scan/not-detected.nix") + ]; + + boot.initrd.availableKernelModules = [ "xhci_pci" "ehci_pci" "ahci" "usbhid" "usb_storage" "sd_mod" "sr_mod" ]; + boot.initrd.kernelModules = [ ]; + boot.kernelModules = [ ]; + boot.extraModulePackages = [ ]; + + fileSystems."/" = + { device = "/dev/disk/by-uuid/3dca09c8-f725-416a-9f89-b69297698ca9"; + fsType = "ext4"; + }; + + fileSystems."/boot" = + { device = "/dev/disk/by-uuid/4E51-B390"; + fsType = "vfat"; + }; + + 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.enp3s0.useDHCP = lib.mkDefault true; + + nixpkgs.hostPlatform = lib.mkDefault "x86_64-linux"; + hardware.cpu.intel.updateMicrocode = true; + + boot.loader.systemd-boot.enable = true; + boot.loader.efi.canTouchEfiVariables = true; + + hardware.nvidia.package = config.boot.kernelPackages.nvidiaPackages.legacy_470; + services.xserver.videoDrivers = [ "nvidia" ]; + services.xserver.displayManager.gdm.wayland = false; + + system.stateVersion = "23.05"; +} diff --git a/nixops/nixops.nix b/nixops/nixops.nix index 561a1da..67fd6b7 100644 --- a/nixops/nixops.nix +++ b/nixops/nixops.nix @@ -15,4 +15,5 @@ chiron = import ./desktop.nix { host = "chiron"; }; old-nixbld = import ./desktop.nix { host = "old-nixbld"; }; franz = import ./desktop.nix { host = "franz"; }; + juno = import ./desktop.nix { host = "juno"; }; }