Author SHA1 Message Date
CaZzzer d9937916bb temp 2025-12-07 20:52:45 -08:00
CaZzzer 4c7142dcda make lanzaboote optional 2025-12-07 20:47:34 -08:00
CaZzzer 923f3f0ffc temp 2025-12-06 18:11:15 -08:00
CaZzzer 578f18bc2d WIP: add secure boot 2025-12-06 16:52:27 -08:00
11 changed files with 133 additions and 91 deletions
Generated
+63 -37
View File
@@ -2,11 +2,11 @@
"nodes": { "nodes": {
"crane": { "crane": {
"locked": { "locked": {
"lastModified": 1781825982, "lastModified": 1754269165,
"narHash": "sha256-SlXKwIRIhrOSAcTjCB3ftPLzJWZStQIPS7J1FlZPnKk=", "narHash": "sha256-0tcS8FHd4QjbCVoxN9jI+PjHgA4vc/IjkUSp+N3zy0U=",
"owner": "ipetkov", "owner": "ipetkov",
"repo": "crane", "repo": "crane",
"rev": "469fd08d0bcf6926321fa973c6777fbc87785dd7", "rev": "444e81206df3f7d92780680e45858e31d2f07a08",
"type": "github" "type": "github"
}, },
"original": { "original": {
@@ -18,24 +18,45 @@
"flake-compat": { "flake-compat": {
"flake": false, "flake": false,
"locked": { "locked": {
"lastModified": 1767039857, "lastModified": 1747046372,
"narHash": "sha256-vNpUSpF5Nuw8xvDLj2KCwwksIbjua2LZCqhV1LNRDns=", "narHash": "sha256-CIVLLkVgvHYbgI2UpXvIIBJ12HWgX+fjA8Xf8PUmqCY=",
"owner": "NixOS", "owner": "edolstra",
"repo": "flake-compat", "repo": "flake-compat",
"rev": "5edf11c44bc78a0d334f6334cdaf7d60d732daab", "rev": "9100a0f413b0c601e0533d1d94ffd501ce2e7885",
"type": "github" "type": "github"
}, },
"original": { "original": {
"owner": "NixOS", "owner": "edolstra",
"repo": "flake-compat", "repo": "flake-compat",
"type": "github" "type": "github"
} }
}, },
"flake-parts": {
"inputs": {
"nixpkgs-lib": [
"lanzaboote",
"nixpkgs"
]
},
"locked": {
"lastModified": 1754091436,
"narHash": "sha256-XKqDMN1/Qj1DKivQvscI4vmHfDfvYR2pfuFOJiCeewM=",
"owner": "hercules-ci",
"repo": "flake-parts",
"rev": "67df8c627c2c39c41dbec76a1f201929929ab0bd",
"type": "github"
},
"original": {
"owner": "hercules-ci",
"repo": "flake-parts",
"type": "github"
}
},
"gitignore": { "gitignore": {
"inputs": { "inputs": {
"nixpkgs": [ "nixpkgs": [
"lanzaboote", "lanzaboote",
"pre-commit", "pre-commit-hooks-nix",
"nixpkgs" "nixpkgs"
] ]
}, },
@@ -60,11 +81,11 @@
] ]
}, },
"locked": { "locked": {
"lastModified": 1790742230, "lastModified": 1764034279,
"narHash": "sha256-5399J1/O3DyLSsYGVa950JtOUDB9Reqvy7FhfDuTVzk=", "narHash": "sha256-hZH6EHQYFifVg0bmSBYT8Art5BWhXBXE307uPLnexY0=",
"owner": "nix-community", "owner": "nix-community",
"repo": "home-manager", "repo": "home-manager",
"rev": "0aefa652eb6fd8b7396af25e8c81cb0790f12cc2", "rev": "381f4f8a3a5f773cb80d2b7eb8f8d733b8861434",
"type": "github" "type": "github"
}, },
"original": { "original": {
@@ -76,23 +97,25 @@
"lanzaboote": { "lanzaboote": {
"inputs": { "inputs": {
"crane": "crane", "crane": "crane",
"flake-compat": "flake-compat",
"flake-parts": "flake-parts",
"nixpkgs": [ "nixpkgs": [
"nixpkgs" "nixpkgs"
], ],
"pre-commit": "pre-commit", "pre-commit-hooks-nix": "pre-commit-hooks-nix",
"rust-overlay": "rust-overlay" "rust-overlay": "rust-overlay"
}, },
"locked": { "locked": {
"lastModified": 1782141370, "lastModified": 1762205063,
"narHash": "sha256-hqijVSEETttmo8Okql9/LG0Ua34hdciKW1a5zzlj8mU=", "narHash": "sha256-If6vQ+KvtKs3ARBO9G3l+4wFSCYtRBrwX1z+I+B61wQ=",
"owner": "nix-community", "owner": "nix-community",
"repo": "lanzaboote", "repo": "lanzaboote",
"rev": "7c9a54a7f87b4539ddbd8bda09a8a5f5f9361aa9", "rev": "88b8a563ff5704f4e8d8e5118fb911fa2110ca05",
"type": "github" "type": "github"
}, },
"original": { "original": {
"owner": "nix-community", "owner": "nix-community",
"ref": "v1.1.0", "ref": "v0.4.3",
"repo": "lanzaboote", "repo": "lanzaboote",
"type": "github" "type": "github"
} }
@@ -120,11 +143,11 @@
] ]
}, },
"locked": { "locked": {
"lastModified": 1769813415, "lastModified": 1751903740,
"narHash": "sha256-nnVmNNKBi1YiBNPhKclNYDORoHkuKipoz7EtVnXO50A=", "narHash": "sha256-PeSkNMvkpEvts+9DjFiop1iT2JuBpyknmBUs0Un0a4I=",
"owner": "nix-community", "owner": "nix-community",
"repo": "nixos-generators", "repo": "nixos-generators",
"rev": "8946737ff703382fda7623b9fab071d037e897d5", "rev": "032decf9db65efed428afd2fa39d80f7089085eb",
"type": "github" "type": "github"
}, },
"original": { "original": {
@@ -135,11 +158,11 @@
}, },
"nixpkgs": { "nixpkgs": {
"locked": { "locked": {
"lastModified": 1790578696, "lastModified": 1763835633,
"narHash": "sha256-ZoxIApko70jCdbH3l20HWXOBaT2HZd87orzd2yJ9dVE=", "narHash": "sha256-HzxeGVID5MChuCPESuC0dlQL1/scDKu+MmzoVBJxulM=",
"owner": "NixOS", "owner": "NixOS",
"repo": "nixpkgs", "repo": "nixpkgs",
"rev": "7a0f122f5090cf4c2ade2a13a0e229d4e19ba71f", "rev": "050e09e091117c3d7328c7b2b7b577492c43c134",
"type": "github" "type": "github"
}, },
"original": { "original": {
@@ -159,11 +182,11 @@
] ]
}, },
"locked": { "locked": {
"lastModified": 1785762349, "lastModified": 1763909441,
"narHash": "sha256-jZhZkzAwc7f3exzcTDJWP2WCAchCv0iNC3UF/QsahdQ=", "narHash": "sha256-56LwV51TX/FhgX+5LCG6akQ5KrOWuKgcJa+eUsRMxsc=",
"owner": "nix-community", "owner": "nix-community",
"repo": "plasma-manager", "repo": "plasma-manager",
"rev": "a19a2a029fa180911bd89c554dca1616e10f4c1d", "rev": "b24ed4b272256dfc1cc2291f89a9821d5f9e14b4",
"type": "github" "type": "github"
}, },
"original": { "original": {
@@ -172,9 +195,12 @@
"type": "github" "type": "github"
} }
}, },
"pre-commit": { "pre-commit-hooks-nix": {
"inputs": { "inputs": {
"flake-compat": "flake-compat", "flake-compat": [
"lanzaboote",
"flake-compat"
],
"gitignore": "gitignore", "gitignore": "gitignore",
"nixpkgs": [ "nixpkgs": [
"lanzaboote", "lanzaboote",
@@ -182,11 +208,11 @@
] ]
}, },
"locked": { "locked": {
"lastModified": 1781733627, "lastModified": 1750779888,
"narHash": "sha256-U3yTuGBnmXvXoQI3qkpfEDsn9RovQPAjN7ndRco+3u0=", "narHash": "sha256-wibppH3g/E2lxU43ZQHC5yA/7kIKLGxVEnsnVK1BtRg=",
"owner": "cachix", "owner": "cachix",
"repo": "pre-commit-hooks.nix", "repo": "pre-commit-hooks.nix",
"rev": "3bbec39bc90eadfa031e6f3b77272f3f60803e39", "rev": "16ec914f6fb6f599ce988427d9d94efddf25fe6d",
"type": "github" "type": "github"
}, },
"original": { "original": {
@@ -213,11 +239,11 @@
] ]
}, },
"locked": { "locked": {
"lastModified": 1782012058, "lastModified": 1761791894,
"narHash": "sha256-9mWUnReOUXfKjZuJAL/bAFH3LUyECTRtXgSNVjRw3UY=", "narHash": "sha256-myRIDh+PxaREz+z9LzbqBJF+SnTFJwkthKDX9zMyddY=",
"owner": "oxalica", "owner": "oxalica",
"repo": "rust-overlay", "repo": "rust-overlay",
"rev": "8534567325bd8a8d2928e6afd81e0a87d19efd3c", "rev": "59c45eb69d9222a4362673141e00ff77842cd219",
"type": "github" "type": "github"
}, },
"original": { "original": {
@@ -233,11 +259,11 @@
] ]
}, },
"locked": { "locked": {
"lastModified": 1787124737, "lastModified": 1763929380,
"narHash": "sha256-EnQcFCdcQs1agb8U/h3kn7+A3c3uorANCPP2WakZjAk=", "narHash": "sha256-Yc7gZME/lcHoJH6bMPCG7CyjKWhOLJPqLI8MXtyKPHo=",
"owner": "Platonic-Systems", "owner": "Platonic-Systems",
"repo": "secrix", "repo": "secrix",
"rev": "9c0a7db4e355c28fe67643656821b06161b4df61", "rev": "c6e3ca7af47c329dcf442a3d017ae171eee5612f",
"type": "github" "type": "github"
}, },
"original": { "original": {
+1 -1
View File
@@ -23,7 +23,7 @@
inputs.nixpkgs.follows = "nixpkgs"; inputs.nixpkgs.follows = "nixpkgs";
}; };
lanzaboote = { lanzaboote = {
url = "github:nix-community/lanzaboote/v1.1.0"; url = "github:nix-community/lanzaboote/v0.4.3";
inputs.nixpkgs.follows = "nixpkgs"; inputs.nixpkgs.follows = "nixpkgs";
}; };
}; };
+5 -5
View File
@@ -5,11 +5,11 @@
enable = true; enable = true;
shellInit = "set fish_greeting"; shellInit = "set fish_greeting";
shellAliases = { shellAliases = {
# Replace ls with eza # Replace ls with exa
ls = "eza -al --color=always --group-directories-first --icons=always"; # preferred listing ls = "exa -al --color=always --group-directories-first --icons"; # preferred listing
la = "eza -a --color=always --group-directories-first --icons=always"; # all files and dirs la = "exa -a --color=always --group-directories-first --icons"; # all files and dirs
ll = "eza -l --color=always --group-directories-first --icons=always"; # long format ll = "exa -l --color=always --group-directories-first --icons"; # long format
lt = "eza -aT --color=always --group-directories-first --icons=always"; # tree listing lt = "exa -aT --color=always --group-directories-first --icons"; # tree listing
"l." = "exa -a | rg '^\.'"; # show only dotfiles "l." = "exa -a | rg '^\.'"; # show only dotfiles
# Replace cat with bat # Replace cat with bat
-4
View File
@@ -31,10 +31,6 @@
intel-media-driver # LIBVA_DRIVER_NAME=iHD intel-media-driver # LIBVA_DRIVER_NAME=iHD
]; ];
environment.systemPackages = with pkgs; [
lmstudio
];
networking.hostName = "Yura-PC"; # Define your hostname. networking.hostName = "Yura-PC"; # Define your hostname.
networking.hostId = "110a2814"; # Required for ZFS. networking.hostId = "110a2814"; # Required for ZFS.
-1
View File
@@ -11,7 +11,6 @@
"sysrq_always_enabled=1" "sysrq_always_enabled=1"
]; ];
boot.loader.systemd-boot.enable = false;
boot.lanzaboote = { boot.lanzaboote = {
enable = true; enable = true;
pkiBundle = "/var/lib/sbctl"; pkiBundle = "/var/lib/sbctl";
+12 -42
View File
@@ -7,20 +7,12 @@
"sysrq_always_enabled=1" "sysrq_always_enabled=1"
]; ];
boot.kernelPackages = pkgs.linuxKernel.packages.linux_7_2; boot.kernelPackages = pkgs.linuxKernel.packages.linux_6_17;
boot.loader = { boot.loader = {
efi.canTouchEfiVariables = true; efi.canTouchEfiVariables = true;
timeout = 3; timeout = 3;
systemd-boot.enable = lib.mkDefault true; systemd-boot.enable = !config.boot.lanzaboote.enable;
}; };
boot.kernel.sysctl = {
# https://wiki.archlinux.org/title/Zram#Optimizing_swap_on_zram
"vm.swappiness" = 180;
"vm.watermark_boost_factor" = 0;
"vm.watermark_scale_factor" = 125;
"vm.page-cluster" = 0;
};
zramSwap.enable = true;
# https://nixos.wiki/wiki/Accelerated_Video_Playback # https://nixos.wiki/wiki/Accelerated_Video_Playback
hardware.graphics.enable = true; hardware.graphics.enable = true;
@@ -38,7 +30,8 @@
services.xserver.enable = false; services.xserver.enable = false;
# Enable the KDE Plasma Desktop Environment. # Enable the KDE Plasma Desktop Environment.
services.displayManager.plasma-login-manager.enable = true; services.displayManager.sddm.enable = true;
services.displayManager.sddm.wayland.enable = true;
services.desktopManager.plasma6.enable = true; services.desktopManager.plasma6.enable = true;
# Enable CUPS to print documents. # Enable CUPS to print documents.
@@ -72,16 +65,16 @@
programs.wireshark.package = pkgs.wireshark; # wireshark-cli by default programs.wireshark.package = pkgs.wireshark; # wireshark-cli by default
programs.bat.enable = true; programs.bat.enable = true;
programs.htop.enable = true; programs.htop.enable = true;
programs.nix-ld.enable = true;
# programs.steam.enable = true;
# https://nixos.wiki/wiki/Docker # https://nixos.wiki/wiki/Docker
virtualisation.docker.enable = true; virtualisation.docker.enable = true;
virtualisation.docker.enableOnBoot = false; virtualisation.docker.enableOnBoot = false;
virtualisation.docker.package = pkgs.docker_28;
# https://github.com/flatpak/flatpak/issues/2861 # https://github.com/flatpak/flatpak/issues/2861
xdg.portal.extraPortals = [ pkgs.xdg-desktop-portal-gtk ]; xdg.portal.extraPortals = [ pkgs.xdg-desktop-portal-gtk ];
workarounds.flatpak.enable = true;
fonts.packages = with pkgs; [ fonts.packages = with pkgs; [
fantasque-sans-mono fantasque-sans-mono
nerd-fonts.fantasque-sans-mono nerd-fonts.fantasque-sans-mono
@@ -117,10 +110,10 @@
powertop powertop
rbw rbw
restic restic
resticprofile
rclone rclone
ripgrep-all ripgrep-all
rustscan rustscan
unrar
whois whois
wireguard-tools wireguard-tools
yt-dlp yt-dlp
@@ -140,31 +133,22 @@
]; ];
}) })
nextcloud-client nextcloud-client
# lutris
lxqt.pavucontrol-qt lxqt.pavucontrol-qt
pinentry-all pinentry-all
tela-circle-icon-theme tela-circle-icon-theme
typst
virt-viewer virt-viewer
waypipe waypipe
] ++ [ ] ++ [
# jetbrains.rust-rover # jetbrains.rust-rover
# jetbrains.goland # jetbrains.goland
jetbrains.clion jetbrains.clion
# jetbrains.idea jetbrains.idea-ultimate
jetbrains.pycharm jetbrains.pycharm-professional
jetbrains.webstorm jetbrains.webstorm
android-studio android-studio
rustup rustup
zed-editor zed-editor
package-version-server # for zed package-version-server # for zed
antigravity-cli
antigravity-ide-fhs
codex
# codex-acp
# github-copilot-cli
# opencode
# opencode-desktop
] ++ [ ] ++ [
# C # C
gcc gcc
@@ -175,41 +159,27 @@
poetry poetry
# Haskell # Haskell
cabal-install
haskell-language-server
# haskellPackages.hls-cabal-plugin
haskellPackages.ghc haskellPackages.ghc
haskellPackages.stack haskellPackages.stack
# Node # Node
nodejs_24 nodejs_22
pnpm pnpm
bun bun
# Nix # Nix
nil nil
nixd nixd
nixfmt nixfmt-rfc-style
# Gleam # Gleam
gleam gleam
beamMinimal28Packages.erlang beamMinimal26Packages.erlang
# Racket # Racket
racket racket
# Ruby # Ruby
ruby ruby
# Java
zulu
# spacetimedb
] ++ [
jujutsu
lazyjj
jjui
# jj-fzf
gg-jj
]; ];
} }
+1
View File
@@ -70,6 +70,7 @@
# https://github.com/flatpak/flatpak/issues/2861 # https://github.com/flatpak/flatpak/issues/2861
xdg.portal.extraPortals = [ pkgs.xdg-desktop-portal-gtk ]; xdg.portal.extraPortals = [ pkgs.xdg-desktop-portal-gtk ];
# workarounds.flatpak.enable = true;
fonts.packages = with pkgs; [ fonts.packages = with pkgs; [
noto-fonts-cjk-sans noto-fonts-cjk-sans
noto-fonts-cjk-serif noto-fonts-cjk-serif
+1
View File
@@ -1,5 +1,6 @@
{ ... }: { { ... }: {
imports = [ imports = [
./opts ./opts
./workarounds
]; ];
} }
+1 -1
View File
@@ -58,7 +58,7 @@ in
enable = true; enable = true;
package = pkgs.caddy.withPlugins { package = pkgs.caddy.withPlugins {
plugins = [ "github.com/caddy-dns/cloudflare@v0.2.1" ]; plugins = [ "github.com/caddy-dns/cloudflare@v0.2.1" ];
hash = "sha256-F7d4HwM4oCkQrFMr4SFSC0r52ONxY+PW6z5BJawW8Ok="; hash = "sha256-aRMg7R0dBAy+LJeGCMPg6HKppM6NPX2NPwtc0CeSQLg=";
}; };
virtualHosts."*.${domain}".extraConfig = '' virtualHosts."*.${domain}".extraConfig = ''
encode encode
+5
View File
@@ -0,0 +1,5 @@
{
imports = [
./flatpak.nix
];
}
+44
View File
@@ -0,0 +1,44 @@
# https://github.com/knightpp/nixos-cfg/blob/main/modules/workarounds/flatpak.nix
{
pkgs,
config,
lib,
...
}: let
cfg = config.workarounds.flatpak;
in {
options = {
workarounds.flatpak = {
enable = lib.mkEnableOption "flatpak workaround";
};
};
config = lib.mkIf cfg.enable {
system.fsPackages = [pkgs.bindfs];
fileSystems = let
mkRoSymBind = path: {
device = path;
fsType = "fuse.bindfs";
options = ["ro" "resolve-symlinks" "x-gvfs-hide"];
};
aggregated = pkgs.buildEnv {
name = "system-fonts-and-icons";
paths = builtins.attrValues {
inherit (pkgs.kdePackages) breeze;
inherit
(pkgs)
noto-fonts
noto-fonts-color-emoji
noto-fonts-cjk-sans
noto-fonts-cjk-serif
;
};
pathsToLink = ["/share/fonts" "/share/icons"];
};
in {
# Create an FHS mount to support flatpak host icons/fonts
"/usr/share/icons" = mkRoSymBind "${aggregated}/share/icons";
"/usr/share/fonts" = mkRoSymBind "${aggregated}/share/fonts";
};
};
}