From 448c3b280a8d1cf021dd5421a220a2887383fb93 Mon Sep 17 00:00:00 2001 From: Zuckerberg Date: Wed, 20 Apr 2022 16:00:29 -0400 Subject: [PATCH] New ponyo --- machines/ponyo/configuration.nix | 11 +++------ machines/ponyo/hardware-configuration.nix | 27 +++++++++++++++-------- 2 files changed, 21 insertions(+), 17 deletions(-) diff --git a/machines/ponyo/configuration.nix b/machines/ponyo/configuration.nix index 374152d..573166e 100644 --- a/machines/ponyo/configuration.nix +++ b/machines/ponyo/configuration.nix @@ -5,27 +5,22 @@ ./hardware-configuration.nix ]; - # colcxrqbxk4hzck3bhymmed7ak6juv22eve3yur2bpxk645dzsxit3yd.onion + # oouao6kfyrirxuuyn6d7nzebyyuyrdnoxunjec2pz25zxqmsptlfgqqd.onion networking.hostName = "ponyo"; firmware.x86_64.enable = true; - bios = { - enable = true; - device = "/dev/sda"; - }; + efi.enable = true; luks = { enable = true; - device.path = "/dev/disk/by-uuid/3492819c-2e5a-44b2-a16c-1e373e8d5881"; + device.path = "/dev/disk/by-uuid/4f5cd792-716a-4dbb-9a1d-dd7b37948acc"; }; system.autoUpgrade.enable = true; services.zerotierone.enable = true; - networking.interfaces.enp0s5.useDHCP = true; - security.acme.acceptTerms = true; security.acme.email = "zuckerberg@neet.dev"; } \ No newline at end of file diff --git a/machines/ponyo/hardware-configuration.nix b/machines/ponyo/hardware-configuration.nix index 8e68edc..2dffc25 100644 --- a/machines/ponyo/hardware-configuration.nix +++ b/machines/ponyo/hardware-configuration.nix @@ -1,26 +1,35 @@ -{ config, lib, pkgs, modulesPath, ... }: - { imports = [ (modulesPath + "/profiles/qemu-guest.nix") ]; - boot.initrd.availableKernelModules = [ "virtio_pci" "virtio_scsi" "ahci" "sd_mod" ]; + boot.initrd.availableKernelModules = [ "ata_piix" "uhci_hcd" "virtio_pci" "virtio_scsi" "sd_mod" ]; boot.initrd.kernelModules = [ ]; - boot.kernelModules = [ ]; + boot.kernelModules = [ "kvm-intel" ]; boot.extraModulePackages = [ ]; fileSystems."/" = - { device = "/dev/disk/by-uuid/636c5325-9651-4475-ba13-8266878effa5"; + { device = "/dev/mapper/enc-pv"; fsType = "btrfs"; }; fileSystems."/boot" = - { device = "/dev/disk/by-uuid/c77e8917-5298-4490-8cc0-86af1a315ef1"; - fsType = "ext3"; + { device = "/dev/disk/by-uuid/396E-1E13"; + fsType = "vfat"; }; - swapDevices = [ ]; + swapDevices = [ + { + device = "/dev/sdb2"; + randomEncryption.enable = true; + } + ]; - hardware.cpu.amd.updateMicrocode = lib.mkDefault config.hardware.enableRedistributableFirmware; + # The global useDHCP flag is deprecated, therefore explicitly set to false here. + # Per-interface useDHCP will be mandatory in the future, so this generated config + # replicates the default behaviour. + networking.useDHCP = lib.mkDefault false; + networking.interfaces.ens3.useDHCP = lib.mkDefault true; + + hardware.cpu.intel.updateMicrocode = lib.mkDefault config.hardware.enableRedistributableFirmware; } \ No newline at end of file