Throw kitty back in fuck it
This commit is contained in:
parent
8bb6498cfd
commit
d3529bbcdb
12 changed files with 138 additions and 37 deletions
|
@ -58,12 +58,12 @@
|
|||
# nixos-rebuild switch --flake /etc/nixos#hostname
|
||||
nixosConfigurations = {
|
||||
tower = mkNix [ ./hosts/tower ]; # Main Desktop
|
||||
kitty = mkNix [ ./hosts/kitty ]; # Dell Optiplex 7010
|
||||
|
||||
envy = mkNix [ ./hosts/envy ]; # HP Convertable
|
||||
pear = mkNix [ ./hosts/pear ]; # MacBook Pro
|
||||
intuos = mkNix [ ./hosts/intuos ]; # Wacom Intuos Tablet
|
||||
redmond = mkNix [ ./hosts/redmond ]; # Lenovo Dual-Boot
|
||||
iso = mkNix [ ./hosts/iso ]; # ISO File
|
||||
|
||||
midas = mkNix [ ./hosts/midas ]; # Dell Optiplex 5040
|
||||
prophet = mkNix [ ./hosts/prophet ]; # Oracle Neoverse-N1
|
||||
|
|
|
@ -1,25 +0,0 @@
|
|||
{ lib, ... }:
|
||||
{
|
||||
imports = [
|
||||
./hardware
|
||||
./users
|
||||
../../modules/system
|
||||
];
|
||||
|
||||
networking.hostName = "iso";
|
||||
|
||||
system = {
|
||||
desktop.enable = true;
|
||||
wireless.enable = true;
|
||||
video.nvidia.enable = true;
|
||||
libvirtd.enable = true;
|
||||
stateVersion = "24.11";
|
||||
};
|
||||
|
||||
environment.persistence."/persist".enable = lib.mkForce false;
|
||||
|
||||
services = {
|
||||
btrfs.autoScrub.enable = lib.mkForce false;
|
||||
fstrim.enable = lib.mkForce false;
|
||||
};
|
||||
}
|
|
@ -1,10 +0,0 @@
|
|||
{ config, lib, modulesPath, ... }:
|
||||
{
|
||||
imports = [
|
||||
(modulesPath + "/installer/cd-dvd/installation-cd-minimal.nix")
|
||||
(modulesPath + "/installer/cd-dvd/channel.nix")
|
||||
];
|
||||
|
||||
nixpkgs.hostPlatform = lib.mkDefault "x86_64-linux";
|
||||
hardware.cpu.amd.updateMicrocode = lib.mkDefault config.hardware.enableRedistributableFirmware;
|
||||
}
|
4
hosts/kitty/boot/default.nix
Normal file
4
hosts/kitty/boot/default.nix
Normal file
|
@ -0,0 +1,4 @@
|
|||
{ pkgs, ... }:
|
||||
{
|
||||
boot.kernelPackages = pkgs.linuxPackages_latest;
|
||||
}
|
20
hosts/kitty/default.nix
Normal file
20
hosts/kitty/default.nix
Normal file
|
@ -0,0 +1,20 @@
|
|||
{ config, lib, ... }:
|
||||
{
|
||||
imports = [
|
||||
./boot
|
||||
./disko
|
||||
./filesystems
|
||||
./hardware
|
||||
./users
|
||||
../../modules/system
|
||||
];
|
||||
|
||||
networking.hostName = "kitty";
|
||||
|
||||
system = {
|
||||
desktop.enable = true;
|
||||
lanzaboote.enable = true;
|
||||
fancyboot.enable = true;
|
||||
stateVersion = "24.11";
|
||||
};
|
||||
}
|
90
hosts/kitty/disko/default.nix
Normal file
90
hosts/kitty/disko/default.nix
Normal file
|
@ -0,0 +1,90 @@
|
|||
{ config, disko, ... }:
|
||||
{
|
||||
imports = [ disko.nixosModules.disko ];
|
||||
|
||||
disko.devices = {
|
||||
disk = {
|
||||
"${config.networking.hostName}" = {
|
||||
type = "disk";
|
||||
device = "/dev/sda";
|
||||
content = {
|
||||
type = "gpt";
|
||||
partitions = {
|
||||
ESP = {
|
||||
priority = 1;
|
||||
size = "2G";
|
||||
type = "EF00";
|
||||
content = {
|
||||
type = "filesystem";
|
||||
format = "vfat";
|
||||
mountpoint = "/boot";
|
||||
mountOptions = [ "umask=0077" ];
|
||||
};
|
||||
};
|
||||
luks = {
|
||||
size = "100%";
|
||||
content = {
|
||||
type = "luks";
|
||||
name = "${config.networking.hostName}-disk";
|
||||
settings.allowDiscards = true;
|
||||
passwordFile = "/tmp/secret.key";
|
||||
content = {
|
||||
type = "lvm_pv";
|
||||
vg = "${config.networking.hostName}";
|
||||
};
|
||||
};
|
||||
};
|
||||
};
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
lvm_vg = {
|
||||
"${config.networking.hostName}" = {
|
||||
type = "lvm_vg";
|
||||
lvs = {
|
||||
root = {
|
||||
size = "100%";
|
||||
content = {
|
||||
type = "btrfs";
|
||||
extraArgs = [ "-f" ];
|
||||
subvolumes = {
|
||||
"/root" = {
|
||||
mountpoint = "/";
|
||||
mountOptions = [ "compress=zstd" "noatime" "ssd" ];
|
||||
};
|
||||
"/prev" = {
|
||||
mountpoint = "/prev";
|
||||
mountOptions = [ "compress=zstd" "noatime" "ssd" "noexec" ];
|
||||
};
|
||||
"/nix" = {
|
||||
mountpoint = "/nix";
|
||||
mountOptions = [ "compress=zstd" "noatime" "ssd" ];
|
||||
};
|
||||
|
||||
# Impermanence
|
||||
"/persist" = {
|
||||
mountpoint = "/persist";
|
||||
mountOptions = [ "compress=zstd" "noatime" "ssd" ];
|
||||
};
|
||||
"/persist/.snapshots" = { };
|
||||
"/persist/home/${config.sysusers.main}" = { };
|
||||
"/persist/home/${config.sysusers.main}/.snapshots" = { };
|
||||
};
|
||||
};
|
||||
};
|
||||
swap = {
|
||||
size = "8G";
|
||||
content = {
|
||||
type = "swap";
|
||||
discardPolicy = "both";
|
||||
};
|
||||
};
|
||||
};
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
# Needed for impermanence
|
||||
fileSystems."/persist".neededForBoot = true;
|
||||
}
|
8
hosts/kitty/filesystems/default.nix
Normal file
8
hosts/kitty/filesystems/default.nix
Normal file
|
@ -0,0 +1,8 @@
|
|||
{ config, ... }:
|
||||
{
|
||||
fileSystems."/home/${config.sysusers.main}/Midas" = {
|
||||
device = "${config.ips.server}:/";
|
||||
fsType = "nfs4";
|
||||
options = [ "x-systemd.automount" "noauto" "soft" "_netdev" ];
|
||||
};
|
||||
}
|
12
hosts/kitty/hardware/default.nix
Normal file
12
hosts/kitty/hardware/default.nix
Normal file
|
@ -0,0 +1,12 @@
|
|||
{ config, lib, pkgs, modulesPath, ... }:
|
||||
{
|
||||
imports = [ (modulesPath + "/installer/scan/not-detected.nix") ];
|
||||
|
||||
boot.initrd.availableKernelModules = [ "xhci_pci" "ehci_pci" "ahci" "usb_storage" "usbhid" "sd_mod" "sr_mod" ];
|
||||
boot.initrd.kernelModules = [ "dm-snapshot" ];
|
||||
boot.kernelModules = [ "kvm-intel" ];
|
||||
|
||||
networking.useDHCP = lib.mkDefault true;
|
||||
nixpkgs.hostPlatform = lib.mkDefault "x86_64-linux";
|
||||
hardware.cpu.intel.updateMicrocode = lib.mkDefault config.hardware.enableRedistributableFirmware;
|
||||
}
|
1
hosts/kitty/id_ed25519.pub
Normal file
1
hosts/kitty/id_ed25519.pub
Normal file
|
@ -0,0 +1 @@
|
|||
ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIGyeBzogUVlK+PR+lC92gPwzal8KmA2xeaTOhi59smXq bun@kitty
|
|
@ -2,7 +2,7 @@
|
|||
{
|
||||
home-manager.users."${config.sysusers.main}".home = {
|
||||
desktop.enable = true;
|
||||
remote-desktop.enable = true;
|
||||
production.enable = true;
|
||||
stateVersion = lib.mkForce config.system.stateVersion;
|
||||
};
|
||||
}
|
|
@ -13,6 +13,7 @@
|
|||
createHome = true;
|
||||
openssh.authorizedKeys.keyFiles = [
|
||||
../../../../hosts/tower/id_ed25519.pub
|
||||
../../../../hosts/kitty/id_ed25519.pub
|
||||
|
||||
../../../../hosts/envy/id_ed25519.pub
|
||||
../../../../hosts/pear/id_ed25519.pub
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue