starlight: oh god
This commit is contained in:
parent
2984178c0a
commit
6908d334d3
|
@ -1,13 +1,4 @@
|
||||||
{ config, pkgs, ... }:
|
{ config, pkgs, ... }:
|
||||||
let
|
|
||||||
net_opts = [
|
|
||||||
"x-systemd.automount"
|
|
||||||
"noauto"
|
|
||||||
"x-systemd.idle-timeout=60"
|
|
||||||
"x-systemd.device-timeout=5s"
|
|
||||||
"x-systemd.mount-timeout=5s"
|
|
||||||
];
|
|
||||||
in
|
|
||||||
{
|
{
|
||||||
boot = {
|
boot = {
|
||||||
kernelPackages = pkgs.linuxPackages_latest;
|
kernelPackages = pkgs.linuxPackages_latest;
|
||||||
|
@ -23,7 +14,7 @@ in
|
||||||
reusePassphrases = true;
|
reusePassphrases = true;
|
||||||
devices = {
|
devices = {
|
||||||
"${config.networking.hostName}" = {
|
"${config.networking.hostName}" = {
|
||||||
device = "/dev/disk/by-uuid/274ec302-20b7-43bf-aa72-895ffdd96919";
|
device = "/dev/disk/by-uuid/9e5e99e1-2869-4001-bbbb-995376d0f6b4";
|
||||||
preLVM = true;
|
preLVM = true;
|
||||||
allowDiscards = true;
|
allowDiscards = true;
|
||||||
bypassWorkqueues = true;
|
bypassWorkqueues = true;
|
||||||
|
@ -34,25 +25,38 @@ in
|
||||||
allowDiscards = true;
|
allowDiscards = true;
|
||||||
bypassWorkqueues = true;
|
bypassWorkqueues = true;
|
||||||
};
|
};
|
||||||
badssd = {
|
vm-sata0 = {
|
||||||
device = "/dev/disk/by-uuid/e1ce7879-a6e3-4f9a-bac9-186206060f83";
|
device = "/dev/disk/by-uuid/e1ce7879-a6e3-4f9a-bac9-186206060f83";
|
||||||
preLVM = true;
|
preLVM = true;
|
||||||
allowDiscards = true;
|
allowDiscards = true;
|
||||||
bypassWorkqueues = true;
|
bypassWorkqueues = true;
|
||||||
};
|
};
|
||||||
|
vm-nvme0 = {
|
||||||
|
device = "/dev/disk/by-uuid/9a9459fa-1b98-40b9-9ba9-66f2ee3b8108";
|
||||||
|
preLVM = true;
|
||||||
|
allowDiscards = true;
|
||||||
|
bypassWorkqueues = true;
|
||||||
|
};
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|
||||||
fileSystems."/media/luna/media".options = net_opts;
|
fileSystems."/media/luna".options = [
|
||||||
fileSystems."/media/luna/photos".options = net_opts;
|
"x-systemd.automount"
|
||||||
fileSystems."/media/luna/games".options = net_opts;
|
"noauto"
|
||||||
fileSystems."/media/luna/private".options = net_opts;
|
"x-systemd.idle-timeout=60"
|
||||||
|
"x-systemd.device-timeout=5s"
|
||||||
|
"x-systemd.mount-timeout=5s"
|
||||||
|
];
|
||||||
|
|
||||||
|
services.lvm = {
|
||||||
|
dmeventd.enable = true;
|
||||||
|
boot.thin.enable = true;
|
||||||
|
};
|
||||||
|
|
||||||
services.btrfs.autoScrub = {
|
services.btrfs.autoScrub = {
|
||||||
enable = true;
|
enable = true;
|
||||||
fileSystems = [
|
fileSystems = [
|
||||||
"/"
|
|
||||||
"/media/data"
|
"/media/data"
|
||||||
];
|
];
|
||||||
};
|
};
|
||||||
|
|
|
@ -10,7 +10,9 @@
|
||||||
}:
|
}:
|
||||||
|
|
||||||
{
|
{
|
||||||
imports = [ (modulesPath + "/installer/scan/not-detected.nix") ];
|
imports = [
|
||||||
|
(modulesPath + "/installer/scan/not-detected.nix")
|
||||||
|
];
|
||||||
|
|
||||||
boot.initrd.availableKernelModules = [
|
boot.initrd.availableKernelModules = [
|
||||||
"nvme"
|
"nvme"
|
||||||
|
@ -19,32 +21,24 @@
|
||||||
"usbhid"
|
"usbhid"
|
||||||
"usb_storage"
|
"usb_storage"
|
||||||
"sd_mod"
|
"sd_mod"
|
||||||
|
"sr_mod"
|
||||||
];
|
];
|
||||||
boot.initrd.kernelModules = [ "dm-snapshot" ];
|
boot.initrd.kernelModules = [ "dm-snapshot" ];
|
||||||
boot.kernelModules = [ "kvm-amd" ];
|
boot.kernelModules = [ "kvm-amd" ];
|
||||||
boot.extraModulePackages = [ ];
|
boot.extraModulePackages = [ ];
|
||||||
|
|
||||||
fileSystems."/" = {
|
fileSystems."/" = {
|
||||||
device = "/dev/disk/by-uuid/aca21111-a488-4bc7-90a7-e61517c24818";
|
device = "/dev/disk/by-uuid/b50a01fa-fc35-4210-80dc-7476831d834f";
|
||||||
fsType = "btrfs";
|
fsType = "ext4";
|
||||||
options = [ "subvol=root" ];
|
|
||||||
};
|
|
||||||
|
|
||||||
fileSystems."/nix" = {
|
|
||||||
device = "/dev/disk/by-uuid/aca21111-a488-4bc7-90a7-e61517c24818";
|
|
||||||
fsType = "btrfs";
|
|
||||||
options = [ "subvol=nix" ];
|
|
||||||
};
|
};
|
||||||
|
|
||||||
fileSystems."/boot" = {
|
fileSystems."/boot" = {
|
||||||
device = "/dev/disk/by-uuid/1AC2-9317";
|
device = "/dev/disk/by-uuid/B5CD-2F86";
|
||||||
fsType = "vfat";
|
fsType = "vfat";
|
||||||
};
|
options = [
|
||||||
|
"fmask=0022"
|
||||||
fileSystems."/home" = {
|
"dmask=0022"
|
||||||
device = "/dev/disk/by-uuid/aca21111-a488-4bc7-90a7-e61517c24818";
|
];
|
||||||
fsType = "btrfs";
|
|
||||||
options = [ "subvol=home" ];
|
|
||||||
};
|
};
|
||||||
|
|
||||||
fileSystems."/media/data" = {
|
fileSystems."/media/data" = {
|
||||||
|
@ -52,46 +46,24 @@
|
||||||
fsType = "btrfs";
|
fsType = "btrfs";
|
||||||
};
|
};
|
||||||
|
|
||||||
fileSystems."/var/lib/lxd/shmounts" = {
|
fileSystems."/media/luna" = {
|
||||||
device = "tmpfs";
|
device = "10.69.0.69:/media/tank";
|
||||||
fsType = "tmpfs";
|
|
||||||
};
|
|
||||||
|
|
||||||
fileSystems."/var/lib/lxd/devlxd" = {
|
|
||||||
device = "tmpfs";
|
|
||||||
fsType = "tmpfs";
|
|
||||||
};
|
|
||||||
|
|
||||||
fileSystems."/var/lib/lxd/storage-pools/default" = {
|
|
||||||
device = "/dev/disk/by-uuid/aca21111-a488-4bc7-90a7-e61517c24818";
|
|
||||||
fsType = "btrfs";
|
|
||||||
options = [ "subvol=root/var/lib/lxd/storage-pools/default" ];
|
|
||||||
};
|
|
||||||
|
|
||||||
fileSystems."/media/luna/photos" = {
|
|
||||||
device = "10.69.0.69:/media/tank/photos";
|
|
||||||
fsType = "nfs4";
|
|
||||||
};
|
|
||||||
|
|
||||||
fileSystems."/media/luna/games" = {
|
|
||||||
device = "10.69.0.69:/media/tank/games";
|
|
||||||
fsType = "nfs4";
|
|
||||||
};
|
|
||||||
|
|
||||||
fileSystems."/media/luna/media" = {
|
|
||||||
device = "10.69.0.69:/media/tank/media";
|
|
||||||
fsType = "nfs4";
|
|
||||||
};
|
|
||||||
|
|
||||||
fileSystems."/media/luna/private" = {
|
|
||||||
device = "10.69.0.69:/media/tank/users/artemis";
|
|
||||||
fsType = "nfs4";
|
fsType = "nfs4";
|
||||||
};
|
};
|
||||||
|
|
||||||
swapDevices = [
|
swapDevices = [
|
||||||
{
|
{ device = "/dev/disk/by-uuid/8a771161-9f84-4fc7-a3b7-5431c6bc6e14"; }
|
||||||
device = "/dev/disk/by-uuid/b134fecf-719f-45af-b317-001e413f06c4";
|
|
||||||
discardPolicy = "both";
|
|
||||||
}
|
|
||||||
];
|
];
|
||||||
|
|
||||||
|
# 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.<interface>.useDHCP`.
|
||||||
|
networking.useDHCP = lib.mkDefault true;
|
||||||
|
# networking.interfaces.enp5s0f0np0.useDHCP = lib.mkDefault true;
|
||||||
|
# networking.interfaces.enp5s0f1np1.useDHCP = lib.mkDefault true;
|
||||||
|
# networking.interfaces.enp6s0.useDHCP = lib.mkDefault true;
|
||||||
|
|
||||||
|
nixpkgs.hostPlatform = lib.mkDefault "x86_64-linux";
|
||||||
|
hardware.cpu.amd.updateMicrocode = lib.mkDefault config.hardware.enableRedistributableFirmware;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue