ricing and config changes

This commit is contained in:
2025-02-03 23:34:15 -05:00
parent 2084f190da
commit 6815ec12ce
16 changed files with 353 additions and 147 deletions

View File

@@ -16,6 +16,7 @@
inputs.agenix.nixosModules.default
inputs.nixos-hardware.nixosModules.common-pc-ssd
inputs.chaotic.nixosModules.default
];
nixpkgs.config.allowUnfreePredicate =
@@ -47,7 +48,7 @@
# kernel options
boot = {
kernelPackages = pkgs.linuxPackages_latest;
kernelPackages = pkgs.linuxPackages_cachyos-lto;
kernel.sysctl = {
# dmesg shushhhhh
@@ -156,7 +157,7 @@
programs.dconf.enable = true;
# Enable sound with pipewire.
hardware.pulseaudio.enable = false; # pipewire >>>>>>> pulseaudio
services.pulseaudio.enable = false; # pipewire >>>>>>> pulseaudio
security.rtkit.enable = true;
services.pipewire = {
enable = true;

159
etcnixos/flake.lock generated
View File

@@ -23,6 +23,31 @@
"type": "github"
}
},
"chaotic": {
"inputs": {
"fenix": "fenix",
"flake-schemas": "flake-schemas",
"home-manager": "home-manager_2",
"jovian": "jovian",
"nixpkgs": [
"nixpkgs"
]
},
"locked": {
"lastModified": 1738552004,
"narHash": "sha256-eYE+8F0ZrSIYvlVkgTjTBlnM1COqUdSs4GKyWnel6I4=",
"owner": "chaotic-cx",
"repo": "nyx",
"rev": "894d1db77131a4a449d1993c7ba314ee15dd4e36",
"type": "github"
},
"original": {
"owner": "chaotic-cx",
"ref": "nyxpkgs-unstable",
"repo": "nyx",
"type": "github"
}
},
"crane": {
"locked": {
"lastModified": 1731098351,
@@ -60,6 +85,28 @@
"type": "github"
}
},
"fenix": {
"inputs": {
"nixpkgs": [
"chaotic",
"nixpkgs"
],
"rust-analyzer-src": "rust-analyzer-src"
},
"locked": {
"lastModified": 1738477724,
"narHash": "sha256-S1x0F7q9cJ6EEmZsakse2Ps6Adi7NadxRtGiuWUlwT0=",
"owner": "nix-community",
"repo": "fenix",
"rev": "1936bb37b1d8597273e3611873dc09dd61b09818",
"type": "github"
},
"original": {
"owner": "nix-community",
"repo": "fenix",
"type": "github"
}
},
"flake-compat": {
"flake": false,
"locked": {
@@ -97,6 +144,20 @@
"type": "github"
}
},
"flake-schemas": {
"locked": {
"lastModified": 1721999734,
"narHash": "sha256-G5CxYeJVm4lcEtaO87LKzOsVnWeTcHGKbKxNamNWgOw=",
"rev": "0a5c42297d870156d9c57d8f99e476b738dcd982",
"revCount": 75,
"type": "tarball",
"url": "https://api.flakehub.com/f/pinned/DeterminateSystems/flake-schemas/0.1.5/0190ef2f-61e0-794b-ba14-e82f225e55e6/source.tar.gz"
},
"original": {
"type": "tarball",
"url": "https://flakehub.com/f/DeterminateSystems/flake-schemas/%3D0.1.5.tar.gz"
}
},
"gitignore": {
"inputs": {
"nixpkgs": [
@@ -140,6 +201,49 @@
"type": "github"
}
},
"home-manager_2": {
"inputs": {
"nixpkgs": [
"chaotic",
"nixpkgs"
]
},
"locked": {
"lastModified": 1738448366,
"narHash": "sha256-4ATtQqBlgsGqkHTemta0ydY6f7JBRXz4Hf574NHQpkg=",
"owner": "nix-community",
"repo": "home-manager",
"rev": "18fa9f323d8adbb0b7b8b98a8488db308210ed93",
"type": "github"
},
"original": {
"owner": "nix-community",
"repo": "home-manager",
"type": "github"
}
},
"jovian": {
"inputs": {
"nix-github-actions": "nix-github-actions",
"nixpkgs": [
"chaotic",
"nixpkgs"
]
},
"locked": {
"lastModified": 1738478597,
"narHash": "sha256-it7lc+HRSQiLV+3CcA+c6fkr2355HyT2GGUowHdfa/E=",
"owner": "Jovian-Experiments",
"repo": "Jovian-NixOS",
"rev": "77fb0818cb42ca0db98839d47bbc6a317c286282",
"type": "github"
},
"original": {
"owner": "Jovian-Experiments",
"repo": "Jovian-NixOS",
"type": "github"
}
},
"lanzaboote": {
"inputs": {
"crane": "crane",
@@ -165,13 +269,36 @@
"type": "github"
}
},
"nix-github-actions": {
"inputs": {
"nixpkgs": [
"chaotic",
"jovian",
"nixpkgs"
]
},
"locked": {
"lastModified": 1729697500,
"narHash": "sha256-VFTWrbzDlZyFHHb1AlKRiD/qqCJIripXKiCSFS8fAOY=",
"owner": "zhaofengli",
"repo": "nix-github-actions",
"rev": "e418aeb728b6aa5ca8c5c71974e7159c2df1d8cf",
"type": "github"
},
"original": {
"owner": "zhaofengli",
"ref": "matrix-name",
"repo": "nix-github-actions",
"type": "github"
}
},
"nixos-hardware": {
"locked": {
"lastModified": 1738391520,
"narHash": "sha256-6HI58PKjddsC0RA0gBQlt6ox47oH//jLUHwx05RO8g0=",
"lastModified": 1738638143,
"narHash": "sha256-ZYMe4c4OCtIUBn5hx15PEGr0+B1cNEpl2dsaLxwY2W0=",
"owner": "NixOS",
"repo": "nixos-hardware",
"rev": "34b64e4e1ddb14e3ffc7db8d4a781396dbbab773",
"rev": "9bdd53f5908453e4d03f395eb1615c3e9a351f70",
"type": "github"
},
"original": {
@@ -183,16 +310,16 @@
},
"nixpkgs": {
"locked": {
"lastModified": 1738277201,
"narHash": "sha256-6L+WXKCw5mqnUIExvqkD99pJQ41xgyCk6z/H9snClwk=",
"lastModified": 1738410390,
"narHash": "sha256-xvTo0Aw0+veek7hvEVLzErmJyQkEcRk6PSR4zsRQFEc=",
"owner": "NixOS",
"repo": "nixpkgs",
"rev": "666e1b3f09c267afd66addebe80fb05a5ef2b554",
"rev": "3a228057f5b619feb3186e986dbe76278d707b6e",
"type": "github"
},
"original": {
"owner": "NixOS",
"ref": "nixos-24.11",
"ref": "nixos-unstable",
"repo": "nixpkgs",
"type": "github"
}
@@ -243,11 +370,29 @@
"root": {
"inputs": {
"agenix": "agenix",
"chaotic": "chaotic",
"lanzaboote": "lanzaboote",
"nixos-hardware": "nixos-hardware",
"nixpkgs": "nixpkgs"
}
},
"rust-analyzer-src": {
"flake": false,
"locked": {
"lastModified": 1738433753,
"narHash": "sha256-lyhEsEf5FQzV+KHVkfxIApMOFWHqyls5+llcQ/uhV6Y=",
"owner": "rust-lang",
"repo": "rust-analyzer",
"rev": "88b901878e684e4f68f104fdbc48749f41bcccd3",
"type": "github"
},
"original": {
"owner": "rust-lang",
"ref": "nightly",
"repo": "rust-analyzer",
"type": "github"
}
},
"rust-overlay": {
"inputs": {
"nixpkgs": [

View File

@@ -2,8 +2,7 @@
description = "System nixOS flake";
inputs = {
nixpkgs.url = "github:NixOS/nixpkgs/nixos-24.11";
# nixpkgs.url = "github:NixOS/nixpkgs/master";
nixpkgs.url = "github:NixOS/nixpkgs/nixos-unstable";
lanzaboote = {
url = "github:nix-community/lanzaboote";
@@ -16,6 +15,11 @@
url = "github:ryantm/agenix";
inputs.nixpkgs.follows = "nixpkgs";
};
chaotic = {
url = "github:chaotic-cx/nyx/nyxpkgs-unstable";
inputs.nixpkgs.follows = "nixpkgs";
};
};
outputs =
@@ -30,29 +34,26 @@
let
username = "primary";
system = "x86_64-linux";
hostnames = [
"mreow"
"yarn"
];
in
{
# desktop
nixosConfigurations.yarn = nixpkgs.lib.nixosSystem {
specialArgs = {
hostname = "yarn";
inherit inputs username;
};
modules = [
./system-yarn.nix
];
};
# laptop
nixosConfigurations.mreow = nixpkgs.lib.nixosSystem {
specialArgs = {
hostname = "mreow";
inherit inputs username;
};
modules = [
./system-mreow.nix
];
};
nixosConfigurations = nixpkgs.lib.foldl' (
config: hostname:
config
// {
"${hostname}" = nixpkgs.lib.nixosSystem {
specialArgs = {
inherit inputs username hostname;
};
modules = [
./system-${hostname}.nix
];
};
}
) { } hostnames;
};
}

View File

@@ -1,14 +1,77 @@
{ pkgs, username, ... }:
{
pkgs,
username,
lib,
...
}:
{
environment.systemPackages = with pkgs; [
# https://github.com/quickemu-project/quickemu
(quickemu.overrideAttrs (old: {
patches = [
(pkgs.fetchpatch {
url = "https://github.com/Titaniumtown/quickemu/commit/f96d52a6b6f4b3187171d8cab61a273475da3b6c.diff";
sha256 = "vXVI4EeJGhOlx8ARTCvB98Ajalk0bVakL98WojqcI3c=";
})
];
}))
];
programs.virt-manager.enable = true;
users.groups.libvirtd.members = [ username ];
virtualisation.libvirtd.enable = true;
virtualisation.libvirtd = {
enable = true;
package = pkgs.libvirt;
qemu = {
package = (
pkgs.qemu_kvm.overrideAttrs (old: {
patches = old.patches ++ [
# amd?
# (pkgs.fetchpatch {
# url = "https://github.com/Scrut1ny/Hypervisor-Phantom/raw/d09d66813570704e2b05440f290d6f9bdf2d26c7/Hypervisor-Phantom/patches/QEMU/amd-qemu-9.2.0.patch";
# sha256 = "BbzgjRa3qaYH1yXXqU6M/S68SxXWpAc9ObTG5qXu6YA=";
# })
# or intel!
(pkgs.fetchpatch {
url = "https://github.com/Scrut1ny/Hypervisor-Phantom/raw/d09d66813570704e2b05440f290d6f9bdf2d26c7/Hypervisor-Phantom/patches/QEMU/intel-qemu-9.2.0.patch";
sha256 = "kXY6R/0Tsotf0mGUIevDLlLWHEznnF1dt0K2ayX7XAg=";
})
(pkgs.fetchpatch {
url = "https://github.com/Scrut1ny/Hypervisor-Phantom/raw/d09d66813570704e2b05440f290d6f9bdf2d26c7/Hypervisor-Phantom/patches/QEMU/qemu-9.2.0-libnfs6.patch";
sha256 = "DkkC7KiQLnL7jbBOtgyLKVvozEG388hdfl5seEqvu3o=";
})
];
})
);
ovmf.packages = lib.mkForce [
(pkgs.OVMF.overrideAttrs (old: {
secureBoot = true;
tpmSupport = true;
})).fd
];
};
};
virtualisation.spiceUSBRedirection.enable = true;
users.users."${username}".extraGroups = [ "libvirtd" ];
boot.kernelPatches = [
{
name = "undetected-kvm";
patch = pkgs.fetchurl {
url = "https://raw.githubusercontent.com/Scrut1ny/Hypervisor-Phantom/d09d66813570704e2b05440f290d6f9bdf2d26c7/Hypervisor-Phantom/patches/Kernel/linux-6.13-svm.patch";
sha256 = "zz18xerutulLGzlHhnu26WCY8rVQXApyeoDtCjbejIk=";
};
}
];
}