Compare commits

...
265 Commits
Author SHA1 Message Date
aaron f54798a8be Merge pull request 'fix(certificates): temporarily distrust emSign ECC Root CA - G3' (#111) from fix/distrust-emudhra-ecc-root into main
Reviewed-on: #111
2026-10-21 14:02:23 +02:00
aaronandClaude Opus 5.5 5b38fc4155 fix(certificates): temporarily distrust emSign ECC Root CA - G3
Eight eMudhra intermediates chaining to this root were generated with
trivially recoverable private keys (Mozilla bug 2083449), so anyone can
mint certificates that non-browser clients using the system bundle will
accept. Browsers already block them; the system bundle does not until
cacert 3.131.1 (nixpkgs f903b88), which has not reached nixos-unstable
yet. Drop this once the flake lock includes that commit.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-21 13:39:53 +02:00
aaron 6c1c4403c2 Merge pull request 'fix(tailscale): open Tailscale's WireGuard port in the firewall' (#109) from fix/tailscale-open-firewall into main
Reviewed-on: #109
2026-10-20 12:50:24 +02:00
aaronandClaude Opus 5.5 fb3e2864d6 fix(tailscale): open Tailscale's WireGuard port in the firewall
services.tailscale.openFirewall defaults to false while the NixOS
firewall is enabled, so argon, krypton and neon dropped unsolicited
inbound 41641/udp. Direct connections then only succeed if the other
peer accepts inbound; between two of these hosts (or a host and a
phone) traffic can fall back to a DERP relay.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-20 12:48:41 +02:00
aaron 8701507742 Merge pull request 'feature(git): enable git lfs for my user' (#108) from feature/add_tea into main
Reviewed-on: #108
2026-10-18 14:43:17 +02:00
aaron c748f22033 feature(git): enable git lfs for my user 2026-10-18 14:42:07 +02:00
aaron a9e17a8c35 Merge pull request 'feature(programs): add the tea binary to my user to communicate with my gitea server' (#107) from feature/add_tea into main
Reviewed-on: #107
2026-10-18 14:16:55 +02:00
aaron 69adfc9890 feature(programs): add the tea binary to my user to communicate with my gitea server 2026-10-18 14:15:52 +02:00
aaron c9c15addcc Merge pull request 'feature(argon): add rootless docker to argon' (#106) from feature/docker_on_argon into main
Reviewed-on: #106
2026-10-16 20:14:45 +02:00
aaron abe6fd5c18 feature(argon): add rootless docker to argon 2026-10-16 20:06:09 +02:00
aaron 49a8b574bf Merge pull request 'feature: add de_nodeadkeys to niri-greet as well' (#105) from feature/nodeadkeys into main
Reviewed-on: #105
2026-10-15 21:00:16 +02:00
aaron b07d8aefa4 feature: add de_nodeadkeys to niri-greet as well 2026-10-15 20:59:52 +02:00
aaron ff7b34fedd Merge pull request 'feature(niri): change keyboard layout to the nondeadkeys variant' (#104) from feature/nodeadkeys into main
Reviewed-on: #104
2026-10-15 18:47:29 +02:00
aaron 1030fdfd8f fix(niri): add correct nodeadkeys designator 2026-10-15 16:31:29 +02:00
aaron 186c3e971d feature(niri): change keyboard layout to the nondeadkeys variant 2026-10-14 09:40:30 +02:00
aaron 1e6d041c45 Merge pull request 'feature(greetd): add noctalia-greeter to greetd' (#103) from feature/noctialia-greeter into main
Reviewed-on: #103
2026-10-14 09:20:22 +02:00
aaron 75f7acbf2e feature(greetd): add noctalia-greeter to greetd 2026-10-14 09:19:40 +02:00
aaron 414f579ccf Merge pull request 'feature: use the local log driver insteald of journald for rootless docker' (#102) from feature/rootless_docker into main
Reviewed-on: #102
2026-10-12 19:22:42 +02:00
aaron 104e0a7cb3 feature: use the local log driver insteald of journald for rootless docker 2026-10-12 19:15:51 +02:00
aaron 3418b08772 Merge pull request 'chore: update nix flakes' (#101) from chore/update into main
Reviewed-on: #101
2026-10-12 18:24:46 +02:00
aaron a8aefcbfdd chore: update nix flakes 2026-10-12 18:10:15 +02:00
aaron 653e56f40c Merge pull request 'fix: remove contact_shadow between bar and attached panels' (#100) from fix/contact_shadow into main
Reviewed-on: #100
2026-10-10 20:52:23 +02:00
aaron 74b64368aa fix: remove contact_shadow between bar and attached panels 2026-10-10 20:50:40 +02:00
aaron 1883b6cb05 Merge pull request 'feature(docker): make changes to the rootless docker setup to support the netgame webapp which relies on k3d and traefik' (#99) from feature/rootless_docker_improvements into main
Reviewed-on: #99
2026-10-07 16:08:46 +02:00
aaron e9b3e5961c feature(docker): make changes to the rootless docker setup to support the netgame webapp which relies on k3d and traefik 2026-10-07 16:05:46 +02:00
aaron 3b961d447b Merge pull request 'chore: update nix flakes' (#98) from chore/update into main
Reviewed-on: #98
2026-10-06 17:39:53 +02:00
aaron edcc71b435 chore: update nix flakes 2026-10-06 17:39:33 +02:00
aaron 88aeea31f8 Merge pull request 'feature(theme): replace all color theme configs with stylix' (#97) from feature/add_stylix into main
Reviewed-on: #97
2026-10-06 17:32:26 +02:00
aaron 8f86bcb365 refactor(nixvim): change back mini.base16 to dedicated nord theme plugin 2026-10-05 21:23:51 +02:00
aaron 2b55ec9873 feature(theme): replace all color theme configs with stylix 2026-10-05 12:39:24 +02:00
aaron 6a5eaca649 Merge pull request 'feature(git): add kryptons ssh key as signing key' (#96) from feature/add_krypton_sk into main
Reviewed-on: #96
2026-10-04 14:43:27 +02:00
aaron 4409e2a9e6 feature(git): add kryptons ssh key as signing key 2026-10-04 14:43:11 +02:00
aaron 441d954b85 Merge pull request 'feature(software): add signal-desktop electron app' (#95) from feature/add_signal into main
Reviewed-on: #95
2026-10-04 10:56:43 +02:00
aaron e602ba9df1 feature(software): add signal-desktop electron app 2026-10-04 10:29:30 +02:00
aaron 863c496400 chore: update installation guide 2026-10-03 22:49:18 +02:00
aaron 20bf806666 Merge pull request 'feature(boot): add secure-boot and tpm-unlock to neon' (#94) from feature/neon_secureboot into main
Reviewed-on: #94
2026-10-03 16:22:29 +02:00
aaron e35311dfd5 chore: update installation guide with secure-boot setup pitfalls 2026-10-03 16:21:54 +02:00
aaron beb520a615 feature(boot): add secure-boot support and tpm-unlock to neon 2026-10-03 15:55:36 +02:00
aaron 4eb3e27f8b Merge pull request 'feature(boot): add secure-boot support and tpm-unlock to argon' (#93) from feature/argon_secureboot into main
Reviewed-on: #93
2026-10-03 15:48:06 +02:00
aaron 8c56b00247 feature(boot): add secure-boot support and tpm-unlock to argon 2026-10-03 15:07:13 +02:00
aaron ff2e4d2f69 Merge pull request 'fix: do not allow edits to the bootloader' (#92) from feature/bootloader_security into main
Reviewed-on: #92
2026-10-03 14:11:56 +02:00
aaron 318e17ac27 fix: do not allow edits to the bootloader 2026-10-03 14:11:29 +02:00
aaron c66549f3bf Merge pull request 'feature(hidpi): adapt sddm and systemd-boot to hidpi display' (#91) from feature/krypton_hidpi into main
Reviewed-on: #91
2026-10-03 13:44:31 +02:00
aaron 620c415be9 fix: adapt systemd-boot for kryptons hidpi screen by using the right console mode 2026-10-03 13:39:35 +02:00
aaron 472f359f80 fix: adapt kryptons sddm for hidpi using the qt scale factor 2026-10-03 13:35:50 +02:00
aaron ad494d1209 Merge pull request 'feature(boot): add luks unlock method using TPM+PIN' (#90) from feature/tpm_unlock into main
Reviewed-on: #90
2026-10-03 13:28:35 +02:00
aaron d26bd424cc feature(boot): add luks unlock method using TPM+PIN 2026-10-03 13:25:18 +02:00
aaron a7bba82b5b Merge pull request 'feature(lanzaboote): add support for secure-boot through lanazaboote' (#88) from feature/secure_boot into main
Reviewed-on: #88
2026-10-03 12:48:11 +02:00
aaron a5e69c043d chore: update installation guide with secure-boot setup 2026-10-03 12:47:27 +02:00
aaron b2a2e7d161 Merge remote-tracking branch 'origin/main' into feature/secure_boot 2026-10-03 11:41:27 +02:00
aaron 66a19890bd chore: remove old vm host entry since it is not used anymore (#89)
Reviewed-on: #89
Co-authored-by: aaron <aaron@0x29a.ch>
2026-10-03 11:37:40 +02:00
aaron 450559f8c6 feature: data-drives on argon and boot securty (#87)
- increase security by restricting /boot to root only
- add data-drives for encrypted drives that will get mounted through crypttab rather than the initrd

Reviewed-on: #87
Co-authored-by: aaron <aaron@0x29a.ch>
2026-10-03 10:57:34 +02:00
aaron b75f44ceab feature(lanzaboote): add support for secure-boot through lanazaboote 2026-10-03 10:39:28 +02:00
aaron b42b873eb1 fix(opencl): remove failing legacy build from t14g1 config 2026-10-02 23:47:57 +02:00
aaron 4effe953c8 Merge pull request 'feature: add new host krypton' (#86) from feature/krypton into main
Reviewed-on: #86
2026-10-02 23:28:24 +02:00
aaron 645a4163f5 feature(neon): since nixos-hardware was added, add support for the t14g1 as well 2026-10-02 23:28:05 +02:00
aaron 4845485547 fix: add proper hardware-configuration for the host 2026-10-02 22:40:37 +02:00
aaron ac74b85231 feature(krypton): add framework 13 pro to the list of hosts 2026-10-02 22:01:56 +02:00
aaron 42da578f75 Merge pull request 'Feature/update installation' (#85) from feature/update_installation into main
Reviewed-on: #85
2026-10-02 17:36:42 +02:00
aaron dd50c4b4e5 feature(disk): allow discards on cryptroot 2026-10-02 17:35:53 +02:00
aaron 8a1067b324 feature(trim): add trim support and change partuuid to disk-labels 2026-10-02 17:34:45 +02:00
aaron fc4f0afc46 chore(guide): add corrections and updates to the install guide 2026-10-02 17:33:34 +02:00
aaron 006290ef05 Merge pull request 'feature(boot): attatch /tmp to tmpfs, but keep nix build in /var/tmp' (#84) from feature/tmpfs-tmp into main
Reviewed-on: #84
2026-10-02 16:40:44 +02:00
aaron 6a080b2319 feature(boot): attatch /tmp to tmpfs, but keep nix build in /var/tmp 2026-10-02 16:39:53 +02:00
aaron 3e0e1d48f9 Merge pull request 'chore: repository cleanup and noctalia baseline' (#83) from chore/cleanup into main
Reviewed-on: #83
2026-10-02 09:51:23 +02:00
aaronandClaude Opus 5.5 3fed9c1fc8 feature(noctalia): take argon's gui overrides into the config
- idle: 300s screen-off, 600s lock, 5s fade, and explicit actions (without them the behaviours do nothing once settings.toml is gone)
- font without Mono, launcher without categories or global emoji, control-center logo from syncthing
- drop shell.ui_scale and shell.panel.launcher_compact, which v5 ignores

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-02 09:39:08 +02:00
aaronandClaude Opus 5.5 87eb1bcb72 refactor(docker): rootless only
Drops the root daemon and the root-equivalent docker group; the daemon settings now apply to the rootless daemon. compose ships with the docker package.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-02 09:25:40 +02:00
aaronandClaude Opus 5.5 06b656477b docs: move explanations into short module headers
Non-obvious context sits in a brief header at the top of a module, everything else uses single-line comments. niri binds use spawn-sh strings, so neon only overrides the command.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-02 09:25:40 +02:00
aaronandClaude Opus 5.5 8d19be9527 refactor: fold host-only modules into the hosts
- argon owns its gpu settings, calibre and the luks drives, now generated from one table
- claudecode.nix is gone, claude-code lives in packages.nix
- home-manager options live next to the home-manager wiring in flake.nix
- settings.nix: one nix block, extra-substituters instead of repeating the cache.nixos.org defaults
- README: current layout

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-02 09:25:40 +02:00
aaronandClaude Opus 5.5 1abb1ca6a1 chore: drop redundant packages and options
- packages.nix is the baseline: drop neovim (nixvim), nvd, sof-firmware (enableAllFirmware), qtmultimedia (v4 leftover); vial moves to vial.nix, wl-clipboard to noctalia.nix, claude-code becomes a plain package here
- drop packages and options already provided elsewhere: noctalia (home-manager), gnupg/pinentry-qt (agent), gtk/qt themes, sddm Theme.Current, zsh plugins (home-manager), group = users, empty firewall lists
- single-package lists without `with pkgs;`, steam package inside its block

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-02 09:25:40 +02:00
aaronandClaude Opus 5.5 4633687ccb chore: remove unused gnuradio module
It isn't imported by any host and doesn't build reliably on unstable; gnuradio moves to a devenv in the projects that need it.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-02 09:25:14 +02:00
aaron 99a910265f Merge pull request 'feature(niri): configure niri via home-manager's niri module' (#82) from feature/niri-hm into main
Reviewed-on: #82
2026-10-02 08:37:31 +02:00
aaron 5abbcb10ca feature(devenv): update devenv 2026-10-02 08:23:28 +02:00
aaron ea2682f31d feature(niri): use home-managers new niri-module to configure niri on my machines with host-specific additions 2026-10-01 18:43:48 +02:00
aaron 73e17de1a1 Merge pull request 'chore: linting' (#81) from chore/lint into main
Reviewed-on: #81
2026-10-01 11:42:15 +02:00
aaron 26473288b6 chore: ignore nixfmt reformat in git blame 2026-10-01 11:40:30 +02:00
aaron 2231d2fc3f style: format all nix files with nixfmt 2026-10-01 11:40:12 +02:00
aaron 4ec579b1fc chore(lint): add statix config and remove unused arguments 2026-10-01 11:40:03 +02:00
aaron c1d11138b3 Merge pull request 'feature: pull in the latest updates, fix some errors and add a devenv for this repository' (#80) from chore/update into main
Reviewed-on: #80
2026-10-01 11:26:12 +02:00
aaron 92b170e5e8 feature: pull in the latest updates, fix some errors and add a devenv for this repository 2026-10-01 11:20:22 +02:00
aaron 3d90a9759f Merge pull request 'feature(wl-mirror): add wl-mirror as dependency to noctalia' (#79) from feature/wl-mirror into main
Reviewed-on: #79
2026-09-29 20:29:06 +02:00
aaron 3b4f05a91c feature(wl-mirror): add wl-mirror as dependency to noctalia 2026-09-29 16:05:18 +02:00
aaron c1a7a9d085 Merge pull request 'chore(flake): update flake file' (#78) from chore/update into main
Reviewed-on: #78
2026-09-26 17:25:11 +02:00
aaron 848af4d44b chore(flake): update flake file 2026-09-26 17:23:47 +02:00
aaron e61289a26e Merge pull request 'fix(siri): add venv to the siril installation' (#77) from fix/siril into main
Reviewed-on: #77
2026-09-20 12:51:09 +02:00
aaron 28f5f4faa9 fix(siri): add venv to the siril installation 2026-09-19 18:48:20 +02:00
aaron 1007450e19 Merge pull request 'chore: update nix flake' (#76) from chore/update into main
Reviewed-on: #76
2026-09-15 12:49:26 +02:00
aaron 1be2731c53 chore: update nix flake 2026-09-15 12:34:30 +02:00
aaron b8d108f173 Merge pull request 'feature(shell): shorten the path in the agnoster prompt, if it gets too long' (#75) from feature/shorten_shell into main
Reviewed-on: #75
2026-09-14 16:47:19 +02:00
aaron 366a895a08 feature(shell): shorten the path in the agnoster prompt, if it gets too long 2026-09-14 16:46:17 +02:00
aaron 7ceef4775c Merge pull request 'feature: move from gpg-git-commit-signing to ssh-signing' (#74) from feature/ssh-git-sign into main
Reviewed-on: #74
2026-09-05 15:46:55 +02:00
aaron 1b9b584729 feature(gpg): add more signing-keys to the config to enable my laptop as well 2026-09-05 15:44:42 +02:00
aaron d9d6877714 feature(gpg): move git from gpg-signing to ssh-signing 2026-09-05 15:33:05 +02:00
aaron 6704ec389c Merge pull request 'chore(update): update flake file' (#73) from chore/update into main
Reviewed-on: #73
2026-08-31 13:52:26 +02:00
aaron aca9e5d7cc chore(update): update flake file 2026-08-30 18:46:17 +02:00
aaron 2c8fbf008d Merge pull request 'chore(update): update flake file' (#72) from chore/update into main
Reviewed-on: #72
2026-08-20 20:53:12 +02:00
aaron c4f1be8a38 chore(update): update flake file 2026-08-20 20:52:22 +02:00
aaron 6df7fcacbb Merge pull request 'fix: ship a numbered udev rule file for vial since otherwise it gets overwritten by systemd's udev file' (#71) from feature/vial into main
Reviewed-on: #71
2026-08-09 14:45:34 +02:00
aaron bc11b464a8 fix: ship a numbered udev rule file for vial since otherwise it gets overwritten by systemd's udev file 2026-08-09 14:45:08 +02:00
aaron 0ac9b45286 Merge pull request 'feature(udev): add support for vial.rocks configurable devices and add the native app as well' (#69) from feature/lily58 into main
Reviewed-on: #69
2026-08-09 14:27:03 +02:00
aaron 55e12b2226 Merge pull request 'feature/appimage' (#70) from feature/bitbox02 into main
Reviewed-on: #70
2026-08-09 14:26:54 +02:00
aaron eab8f4974e feature(appimage): add appimage squashfs support for my nixos 2026-08-09 14:13:52 +02:00
aaron 0b1190a257 feature(appimage): add appimage squashfs support for my nixos 2026-08-09 14:13:06 +02:00
aaron 62954a67b5 feature(udev): add support for vial.rocks configurable devices and add the native app as well 2026-08-09 13:49:46 +02:00
aaron 37d44b64c1 Merge pull request 'chore(flake): update flake file' (#68) from chore/update into main
Reviewed-on: #68
2026-08-06 16:50:04 +02:00
aaron cb5dd91550 chore(flake): update flake file 2026-08-06 16:38:59 +02:00
aaron fb04de1d23 Merge pull request 'feature(tmux): make tmux forward csi-u sequences thus enabling shift-enter in opencode' (#66) from feature/tmux into main
Reviewed-on: #66
2026-07-29 10:46:47 +02:00
aaron f41387e451 feature(tmux): make tmux forward csi-u sequences thus enabling shift-enter in opencode 2026-07-29 10:44:42 +02:00
aaron 2ae9d451f5 Merge pull request 'refactor(tmux): tidy up my old tmux config, use unicode for the seperators and backport augmentations from my at-work-config' (#65) from feature/tmux into main
Reviewed-on: #65
2026-07-29 10:34:05 +02:00
aaron 3feb6d2367 refactor(tmux): tidy up my old tmux config, use unicode for the seperators and backport augmentations from my at-work-config 2026-07-29 10:30:33 +02:00
aaron 41fbb67fc9 Merge pull request 'fix(sleep): revert s2sleep as it introduces crashes after the wake-up of the system' (#64) from fix/sleep into main
Reviewed-on: #64
2026-07-23 17:10:08 +02:00
aaron b15968b004 fix(sleep): revert s2sleep as it introduces crashes after the wake-up of the system 2026-07-23 16:12:50 +02:00
aaron 274c39b213 Merge pull request 'refactor(sleep): move the s2 sleep change to argon only since s2idle would cost more battery on a laptop that s3 deep sleep' (#63) from fix/sleep into main
Reviewed-on: #63
2026-07-23 15:08:41 +02:00
aaron 2a3c439993 refactor(sleep): move the s2 sleep change to argon only since s2idle would cost more battery on a laptop that s3 deep sleep 2026-07-23 15:08:24 +02:00
aaron a2e9ad6035 Merge pull request 'fix(sleep): change sleep mode from s3 deep to s2 idle sleep to prevent issues woth radeon RDNA4 cards' (#62) from fix/sleep into main
Reviewed-on: #62
2026-07-23 14:56:59 +02:00
aaron 6fdde12804 fix(sleep): change sleep mode from s3 deep to s2 idle sleep to prevent issues woth radeon RDNA4 cards 2026-07-23 14:51:55 +02:00
aaron 32291e63bb Merge pull request 'chore(update): update flake file' (#61) from feature/update into main
Reviewed-on: #61
2026-07-23 14:29:18 +02:00
aaron 0e681ec0e2 chore(update): update flake file 2026-07-20 22:51:44 +02:00
aaron 0ce944b327 Merge pull request 'chore(flake): update flake file' (#60) from feature/updates into main
Reviewed-on: #60
2026-07-06 22:12:41 +02:00
aaron 046a17374b chore(flake): update flake file 2026-07-06 21:16:24 +02:00
aaron 626015db9f Merge pull request 'feature(packages): update and add cifs and nfs utils' (#59) from feature/cifs-utils into main
Reviewed-on: #59
2026-06-27 19:07:21 +02:00
aaron dfc2a1ca3a feature(packages): add nfs-utils 2026-06-27 18:51:31 +02:00
aaron e41d02abcc chore(update): upgrade flake file 2026-06-27 18:36:19 +02:00
aaron ec79afe982 feature(packages): add cifs-utils 2026-06-27 18:35:06 +02:00
aaron 536d4df5e4 Merge pull request 'feature(noctalia): add ddcutil to adjust the screens brightness' (#58) from feature/brightnesscontrol into main
Reviewed-on: #58
2026-06-23 13:03:47 +02:00
aaron 3bd71bb5e1 feature(noctalia): add ddcutil to adjust the screens brightness 2026-06-23 13:02:19 +02:00
aaron d7ac5923ff Merge pull request 'feature: astrophotography toolkit' (#57) from feature/astro into main
Reviewed-on: #57
2026-06-23 11:21:10 +02:00
aaron dab8e42797 fix(siril): expose adwaita-qt6 style plugin for dark theme 2026-06-23 11:08:10 +02:00
aaron cd905df8b4 fix(siril): add python3 to the siril wrapper so it sees it in its runtime path 2026-06-23 10:53:21 +02:00
aaron c20c9c0601 chore(flake): update flake file 2026-06-22 23:20:40 +02:00
aaron 853a7cfb17 feature(neon): add claude code to neon 2026-06-22 21:51:11 +02:00
aaron 596b58fab4 fix: add gc and misc settings to neon as well 2026-06-21 00:01:16 +02:00
aaron a58319e08d fix: remove stellarium module from neon 2026-06-20 23:57:20 +02:00
aaron 79b24d9439 fix: add more shared objects for sirils plugins 2026-06-20 21:48:26 +02:00
aaron b295a9a330 feature(siril): make siril plugins work by exposing shared objects 2026-06-20 18:11:34 +02:00
aaron 29db6af86b feature(starnet): add starnet to siril to use ml models for star removal, this needs nix-ld to be enabled 2026-06-20 13:58:29 +02:00
aaron 9d7efb69ac feature(astro): collect astrofotography tools in one module 2026-06-20 12:18:45 +02:00
aaron bf5de3872f Merge pull request 'chore(update): update flake file' (#56) from feature/updates into main
Reviewed-on: #56
2026-06-16 14:44:10 +02:00
aaron 7577e39c88 feature(noctalia): update the noctalia config 2026-06-16 11:33:38 +02:00
aaron 47fb9e7f97 feature(nixvim): pin nixvim to nixpkgs to suppress the non-default warning 2026-06-15 10:54:35 +02:00
aaron 098b92ae45 feature(noctalia): use the noctialia flake to manage my noctalia config for version 5 2026-06-15 10:45:34 +02:00
aaron b987dcf0c6 chore(update): update flake file 2026-06-14 16:49:39 +02:00
aaron 0c6c2dd71b chore(update): update flake file 2026-06-11 16:00:09 +02:00
aaron a329e21711 Merge pull request 'chore(update): update flake file' (#55) from feature/updates into main
Reviewed-on: #55
2026-06-09 20:08:00 +02:00
aaron 91f3e0425b chore(update): update flake file 2026-06-09 20:05:11 +02:00
aaron 85fa00a2e1 Merge pull request 'add stellarium app' (#54) from feature/stellarium into main
Reviewed-on: #54
2026-06-07 18:38:32 +02:00
aaron 1d558f3f7c feature(stellarium): add new module for stellarium 2026-06-07 18:33:29 +02:00
aaron ddaeb1beff Merge pull request 'updates' (#53) from feature/updates into main
Reviewed-on: #53
2026-06-04 20:48:10 +02:00
aaron 5e3867b227 chore(update): update flake file 2026-06-04 20:47:25 +02:00
aaron 7f58c16441 Merge pull request 'omz update' (#52) from feautre/omz_update into main
Reviewed-on: #52
2026-06-04 09:22:13 +02:00
aaron 2edc62ff13 refactor(omz): move theme selection and untracked files to extraConfig 2026-06-04 09:18:33 +02:00
aaron 27fb719555 feature(omz): add option to make omz faster on large repositories 2026-06-04 08:49:53 +02:00
aaron 5ab603b726 Merge pull request 'add thunar' (#51) from feature/thunar into main
Reviewed-on: #51
2026-05-29 20:40:49 +02:00
aaron a3e09d0019 fix: remove typo 2026-05-29 19:19:10 +02:00
aaron ae895dc55f fix: tumbler is a package rather than a programm and thus must be installed with packages 2026-05-29 19:15:40 +02:00
aaron cb0645dd81 feature(thunar): add thunar and thumbler thumbnailer service 2026-05-29 19:06:02 +02:00
aaron 0daf4eec9a Merge pull request 'chore(flake): update flake file to latest state' (#50) from feautre/update into main
Reviewed-on: #50
2026-05-26 20:37:27 +02:00
aaron 59a83f550c chore(flake): update flake file to latest state 2026-05-26 20:37:02 +02:00
aaron 6ceaf560ca Merge pull request 'feature(gnuradio): add gnuradio-companion back to desktop since the compile error has been resolved upstream' (#49) from feature/add_gnuradio into main
Reviewed-on: #49
2026-05-25 18:38:59 +02:00
aaron 553d748f91 feature(gnuradio): add gnuradio-companion back to desktop since the compile error has been resolved upstream 2026-05-25 18:38:16 +02:00
aaron fac89ff665 Merge pull request 'feature/add_proton' (#48) from feature/add_proton into main
Reviewed-on: #48
2026-05-23 15:29:39 +02:00
aaron af42bdc7a3 feature(nix): add wheel and root to the list of trusted users 2026-05-21 11:14:55 +02:00
aaron 45ae50d7a5 chore: update flake 2026-05-19 22:26:49 +02:00
aaron 965de98adb feature(vpn): add protonvpn to neon 2026-05-19 22:05:42 +02:00
aaron 53c39bb8f8 Merge pull request 'feautre/add_claude_code' (#47) from feautre/add_claude_code into main
Reviewed-on: #47
2026-05-01 18:43:47 +02:00
aaron e1a06eee71 fix(firefox): get rid of the warning message for the firefox config home 2026-05-01 18:43:08 +02:00
aaron 8605bf7a6b feature(claude): add claude code as a module 2026-05-01 18:35:28 +02:00
aaron 8b275aac66 Merge pull request 'chore(flake): update flake file to latest state and remove broken packages' (#46) from feature/updates into main
Reviewed-on: #46
2026-05-01 18:33:26 +02:00
aaron 31806ca62d chore(flake): update flake file to latest state and remove broken packages 2026-05-01 18:32:59 +02:00
aaron 738dc4d8bd Merge pull request 'update flake file' (#45) from feature/updates into main
Reviewed-on: #45
2026-04-29 09:22:55 +02:00
aaron 3fd7fba7f9 chore(flake): update flake file 2026-04-29 09:20:30 +02:00
aaron 56231797cc chore(update): update flake file 2026-04-29 08:56:24 +02:00
aaron b1cf8a9d7f Merge pull request 'evaluate typst for note taking during classes' (#43) from feature/add_typst into main
Reviewed-on: #43
2026-04-28 21:10:47 +02:00
aaron 1afbb9115f fix(lsp): remove ansiblels since it isnt needed anyway 2026-04-28 21:09:15 +02:00
aaron e0e2d99951 feature(nixvim): add pyright and ruff as linter and type checker 2026-04-28 21:04:57 +02:00
aaron a6034ee47a fix(nixvim): telescope live grep needs ripgrep as dependency 2026-04-28 19:19:04 +02:00
aaron 975bccfe5f fix(nixvim): remove double definition of treesitter 2026-04-28 19:14:22 +02:00
aaron 9db2c9d76e feature(userprograms): add typst 2026-04-28 19:13:12 +02:00
aaron 8f1cc582e9 feature(nvim): add typst support with lsp and preview for note taking 2026-04-28 19:13:00 +02:00
aaron ae5276444e Merge pull request 'nvim: add markdown-render plugin' (#44) from feature/add_render_markdown into main
Reviewed-on: #44
2026-04-28 16:50:37 +02:00
aaron 393c4ccfc5 refactor: cleanup nixvim config 2026-04-28 16:21:05 +02:00
aaron 6dcbe4e7c7 Merge pull request 'add software for my new hackrf pro' (#42) from feature/add_hackrf into main
Reviewed-on: #42
2026-04-24 20:09:30 +02:00
aaron ee127abe7e chore(update): update flake file 2026-04-24 20:02:50 +02:00
aaron a14e5b5a77 feature(gqrx): add gqrx alongside gnuradio since it will be used anyways 2026-04-24 19:15:48 +02:00
aaron 69ca1dbaca feature(gnuradio): add gnuradio-companion with osmocom extension 2026-04-23 20:27:06 +02:00
aaron c38d3ec7b8 Merge pull request 'feature(calibre): add calibre ebook management' (#41) from feature/add_calibre into main
Reviewed-on: #41
2026-04-15 18:37:14 +02:00
aaron d5d6488761 chore(update): update to the latest release 2026-04-15 18:36:57 +02:00
aaron e0e282a547 feature(calibre): add calibre ebook management 2026-04-09 20:11:19 +02:00
aaron 9f0ee40cc3 Merge pull request 'chore(update): update to the latest release' (#40) from feature/updates into main
Reviewed-on: #40
2026-04-09 19:54:54 +02:00
aaron 68fc3a2df2 chore(update): update to the latest release 2026-04-09 19:54:11 +02:00
aaron 5dfc62fc83 Merge pull request 'feature/updates' (#39) from feature/updates into main
Reviewed-on: #39
2026-03-31 15:44:15 +02:00
aaron 1b82de5c92 chore(protonvpn): change name to proton-vpn due to deprication 2026-03-31 15:42:14 +02:00
aaron c1d1fb7793 chore(update): update flake file 2026-03-31 15:41:36 +02:00
aaron e6bc267161 Merge pull request 'feature/chromium' (#38) from feature/chromium into main
Reviewed-on: #38
2026-03-28 22:08:18 +01:00
aaron 212dddaffd refactor: remove qflipper since that software is not maintained anymore 2026-03-28 22:08:03 +01:00
aaron 58509367a3 refactor(browsers): move browser selection to home-manager module since it is a user choice 2026-03-27 11:32:45 +01:00
aaron fdc93aff91 chore(update): update flake file 2026-03-27 10:39:36 +01:00
aaron f9f9c72498 feature(user): add my user to the dialout group in order to access serial terminal 2026-03-27 10:39:22 +01:00
aaron 0fdada8766 refactor: move chromium to home-manager packages 2026-03-27 10:38:56 +01:00
aaron 554462128e refactor: move chromium to home-manager packages 2026-03-27 10:38:31 +01:00
aaron 7c0bbf18c8 feature(browsers): add chromium browser 2026-03-27 09:29:10 +01:00
aaron d1222fc204 Merge pull request 'feautre(ts6): add teamspeak6-client since ts3 is based on an unmaintained qtwebkit' (#37) from feature/teamspeak into main
Reviewed-on: #37
2026-03-25 21:34:12 +01:00
aaron da8fa17202 feautre(ts6): add teamspeak6-client since ts3 is based on an unmaintained qtwebkit 2026-03-25 21:31:21 +01:00
aaron e143872f25 Merge pull request 'fix(nvim): add plenary as extraPlugins' (#36) from feature/fix_nvim into main
Reviewed-on: #36
2026-03-24 18:15:35 +01:00
aaron db22935910 fix(nvim): add plenary as extraPlugins 2026-03-24 16:17:30 +01:00
aaron b62d9f7630 Merge pull request 'feature/update' (#35) from feature/update into main
Reviewed-on: #35
2026-03-23 13:17:38 +01:00
aaron 20e19bb0be fix(gtk4): adopt the new default behavior and silence a compilation warning 2026-03-23 13:15:54 +01:00
aaron c31478461e fix(sddm): add theme to system packages so the path will be symlinked 2026-03-23 13:14:20 +01:00
aaron 073d257ca8 chore(flake): update flake lock to the latest version 2026-03-23 13:13:01 +01:00
aaron 7b50d5327c chore(flake): update flake lock to the latest version 2026-03-21 19:32:56 +01:00
aaron 642e723fd6 Merge pull request 'cleanup repository' (#34) from feature/repo_cleanup into main
Reviewed-on: #34
2026-03-21 18:08:19 +01:00
aaron 9a8090dac2 refactor(wireguard): set checkReversePath to loose instead of false 2026-03-21 16:45:09 +01:00
aaron 4e9ffcf6bd refactor(unfree): move the unfree setting to the settings module 2026-03-21 16:43:43 +01:00
aaron 02a5d03d1a refactor(packages): move installed packages to their respective nix modules 2026-03-21 16:43:05 +01:00
aaron b480e8224d refactor(flake): simplify nix flake by deduplication 2026-03-21 16:41:34 +01:00
aaron 32a62aadd4 refactor(networking): drop wireless enable since it installs wpa_supplicant and rely on networkmanager instead 2026-03-21 16:40:24 +01:00
aaron 619c00e678 refactor(locales): fix internationalisation to switzerland norms 2026-03-21 16:39:30 +01:00
aaron a02da7f66d refactor(programs): uninstall screenfetch since it is unmaintained software 2026-03-21 16:38:55 +01:00
aaron 8b616b65af refactor(default): remove hardware import from default target since it is a dublicate 2026-03-21 16:38:17 +01:00
aaron 17158618ee refactor(docker): move the docker group to the respective nix module instead of adding the user per default 2026-03-21 16:37:31 +01:00
aaron 64a12d1cae Merge pull request 'feature/updates' (#33) from feature/updates into main
Reviewed-on: #33
2026-03-20 18:18:53 +01:00
aaron 2fb937b19f feature(wifi): enable more firmware to support my wifi chip 2026-03-20 18:17:43 +01:00
aaron a7c5cbad41 chore(update): update flake file 2026-03-20 17:51:08 +01:00
aaron 52a4a7aca0 Merge pull request 'chore(update): update flake file' (#32) from feature/updates into main
Reviewed-on: #32
2026-03-19 09:15:37 +00:00
aaron e420a4d8b3 chore(update): update flake file 2026-03-19 10:13:29 +01:00
aaron 5e19eb0d9a Merge pull request 'fix(backup): instruct home-manager to backup files using a timestamp to avoid collisions' (#31) from feature/backupfiles into main
Reviewed-on: #31
2026-03-16 20:19:44 +01:00
aaron b9450f1bca fix(backup): instruct home-manager to backup files using a timestamp to avoid collisions 2026-03-16 20:01:43 +01:00
aaron a61b330288 Merge pull request 'feature/copypaste' (#30) from feature/copypaste into main
Reviewed-on: #30
2026-03-16 19:47:22 +01:00
aaron 03c520923c Merge pull request 'feature(ghostty): add ssh-terminfo and ssh-env as fallback' (#29) from feature/ssh-terminfo into main
Reviewed-on: #29
2026-03-15 23:03:59 +01:00
aaron a193a08f0b feature(ghostty): add ssh-terminfo and ssh-env as fallback 2026-03-15 23:02:44 +01:00
aaron 34cad2a944 fix(omz): replace initBeforeCompInit due to deprication 2026-03-14 20:23:19 +01:00
aaron eda6cd9997 feature(tmux): fix copy-paste issues for tmux and opencode 2026-03-14 16:44:14 +01:00
aaron 0e68a12e47 Merge pull request 'feature/add_devenv' (#28) from feature/add_devenv into main
Reviewed-on: #28
2026-03-13 16:59:02 +01:00
aaron d5ce65c91d chore(flake): update flake file to latest state 2026-03-12 19:38:23 +01:00
aaron 4944f87ce9 feature(devenv): add devenv to home-manager 2026-03-12 19:32:02 +01:00
aaron 81b04a8b1c Merge pull request 'improve zsh config' (#27) from feautre/zshimprovements into main
Reviewed-on: #27
2026-03-07 21:07:50 +01:00
aaron ea30328d6b feature(zsh): only display a theme with glyphs if the terminal is able to render them 2026-03-07 21:06:33 +01:00
aaron 97f782b3d9 Merge pull request 'update and cleanup' (#26) from feature/cleanup into main
Reviewed-on: #26
2026-03-06 23:01:47 +01:00
aaron ad50c751d6 chore(update): update flake file 2026-03-06 22:28:18 +01:00
aaron 3494a85734 refactor(noctalia): remove quickshell dependency as noctalia-qs already gets pulled in by the flake 2026-03-06 22:21:11 +01:00
aaron fcb0161e83 Merge pull request 'feature/argon' (#25) from feature/argon into main
Reviewed-on: #25
2026-03-06 18:37:01 +01:00
aaron 9b02617698 refactor(drives): add disclaimer and change order 2026-03-06 18:34:15 +01:00
aaron bd6546263b refactor(greetd): rename package to omit warning 2026-03-06 18:25:28 +01:00
aaron 53c2cf1a63 refactor(graphics): add amdgpu_top to systempackages 2026-03-06 18:16:40 +01:00
aaron 80638a920b feature(greeter): replace sddm with greetd since sddm has issues with rdna4 2026-03-05 22:15:56 +01:00
aaron e4674e5828 refactor(networking): remove general hostname 2026-03-05 21:58:56 +01:00
aaron 16ea94e160 feature(graphics): add amdgpu_top to the default pkgs 2026-03-05 21:58:36 +01:00
aaron afd3113cf3 feature(graphics): add amdgpu to the initrd 2026-03-05 21:50:46 +01:00
aaron d7a08c2571 feature(protonvpn): add protonvpn nix module 2026-03-05 21:36:10 +01:00
aaron 8cdcb15618 fix(drives): remove password fallback 2026-03-05 21:23:34 +01:00
aaron a0fd1e9264 feature(drives): add encrypted drives for argon 2026-03-05 20:53:40 +01:00
aaron d60bdd1245 fix(noctalia): add quickshell since it is a dependency of noctalia 2026-03-05 20:52:51 +01:00
aaron 404868aa85 refactor(shell): remove omz config from users file and add to home-manager 2026-03-05 20:52:19 +01:00
aaron 7566d0d1ef fix(graphics): explicitly add graphics accelleration 2026-03-05 20:50:50 +01:00
aaron 6a132670e2 fix(hostnames): move hostname to configuration.nix 2026-03-05 17:38:00 +01:00
aaron f182b2418a feature(argon): add config for argon 2026-03-05 17:37:12 +01:00
aaron eb0bc149e8 Merge pull request 'chore(flake): update flake lock to the latest version' (#24) from feature/update into main
Reviewed-on: #24
2026-03-04 17:16:10 +01:00
aaron f53a2aceee chore(flake): update flake lock to the latest version 2026-03-04 17:10:18 +01:00
aaron d64f10ad3f Merge pull request 'add docker to the system' (#23) from feature/docker into main
Reviewed-on: #23
2026-02-22 18:14:40 +01:00
aaron cc44e68a2e feature(users): add docker group to the main user 2026-02-21 21:17:19 +01:00
aaron b97d6cc47d feature(neon): add docker to neon 2026-02-21 21:16:42 +01:00
aaron 0d495039ee feature(docker): add docker daemon config for nixos 2026-02-21 21:16:17 +01:00
aaron 64b76ad7fd Merge pull request 'feature(ssh): add more security to the ssh config' (#22) from feature/openssh into main
Reviewed-on: #22
2026-02-21 18:09:31 +01:00
aaron 135f2bdac9 Merge pull request 'refactor(installguide): unify device naming, add notes and correct typos' (#21) from feature/installguide into main
Reviewed-on: #21
2026-02-21 17:56:00 +01:00
aaron d288f6828f refactor(installguide): unify device naming, add notes and correct typos 2026-02-21 17:55:32 +01:00
60 changed files with 2151 additions and 599 deletions
+2
View File
@@ -0,0 +1,2 @@
# nixfmt reformat
2231d2fc3fb4dc140c5f3257523dcdb513ac4dea
+4
View File
@@ -8,3 +8,7 @@ result-*
# vim # vim
*.swp *.swp
# devenv
.devenv*
devenv.local.nix
+119 -27
View File
@@ -2,9 +2,13 @@
- The installations presented in this repository are always luks encrypted - The installations presented in this repository are always luks encrypted
- For simplicity I'm using device labels rather than uuids - For simplicity I'm using device labels rather than uuids
- Secure Boot has to be disabled in the firmware, the installer iso isn't signed
1. the partitioning layout should look somewhat like this after the installation 1. create the partitions with `cfdisk` or `fdisk` (gpt)
- `nvme0n1p1`: 2G, type `EFI System`, otherwise the firmware won't find the bootloader
- `nvme0n1p2`: the rest, type `Linux filesystem`
the layout should look somewhat like this after the installation
```bash ```bash
NAME MAJ:MIN RM SIZE RO TYPE MOUNTPOINTS NAME MAJ:MIN RM SIZE RO TYPE MOUNTPOINTS
nvme0n1 259:0 0 476.9G 0 disk nvme0n1 259:0 0 476.9G 0 disk
@@ -13,29 +17,31 @@ nvme0n1 259:0 0 476.9G 0 disk
└─cryptroot 254:0 0 474.9G 0 crypt └─cryptroot 254:0 0 474.9G 0 crypt
├─lvmroot-swap 254:1 0 20G 0 lvm [SWAP] ├─lvmroot-swap 254:1 0 20G 0 lvm [SWAP]
├─lvmroot-home 254:2 0 250G 0 lvm /home ├─lvmroot-home 254:2 0 250G 0 lvm /home
└─lvmroot-root 254:3 0 204.9G 0 lvm /nix/store └─lvmroot-root 254:3 0 204.9G 0 lvm /
``` ```
2. prepare the installation > Note: `lsblk` may additionally show `/nix/store` as a mountpoint on `lvmroot-root`. This is not a separate partition. NixOS mounts the root device a second time at `/nix/store` with `ro,nosuid,nodev` flags to enforce store immutability at runtime.
2. prepare the installation
```bash ```bash
# format the boot partition # format the boot partition
mkfs.fat -F 32 /dev/sda1 -n "nixboot" mkfs.fat -F 32 /dev/nvme0n1p1 -n "nixboot"
# create an encrypted partition # create an encrypted partition
cryptsetup luksFormat -y --label="nixcrypt" /dev/sda2 cryptsetup luksFormat -y --label="nixcrypt" /dev/nvme0n1p2
# open the encrypted partition and map it to /dev/mapper/cryptroot # open the encrypted partition and map it to /dev/mapper/cryptroot
cryptsetup luksOpen /dev/sda2 cryptroot cryptsetup luksOpen /dev/nvme0n1p2 cryptroot
# create the physical volume # create the physical volume
pvcreate /dev/mapper/cryptroot pvcreate /dev/mapper/cryptroot
# create a volume group inside # create a volume group inside
vgcreate lvmroot /dev/mapper/cryptroot vgcreate lvmroot /dev/mapper/cryptroot
# create the swap volume # create the swap volume, half the ram (no hibernation)
lvcreate --size 8G lvmroot --name nwap lvcreate --size 16G lvmroot --name swap
# if you desire, create a home volume # if you desire, create a home volume
lvcreate --size 150G lvmroot --name home lvcreate --size 150G lvmroot --name home
# create the root volume # create the root volume, leave some space in the vg to grow volumes later
lvcreate -l 100%FREE lvmroot --name root # (lvextend -r -L +50G lvmroot/home works while mounted)
lvcreate -l 90%FREE lvmroot --name root
# format as usual for root partition # format as usual for root partition
mkfs.ext4 -L "nixroot" /dev/mapper/lvmroot-root mkfs.ext4 -L "nixroot" /dev/mapper/lvmroot-root
@@ -47,7 +53,7 @@ mkswap -L "nixswap" /dev/mapper/lvmroot-swap
# mount root # mount root
mount /dev/disk/by-label/nixroot /mnt mount /dev/disk/by-label/nixroot /mnt
# mount boot # mount boot
mount --mkdir /dev/sda1 /mnt/boot mount --mkdir /dev/disk/by-label/nixboot /mnt/boot
# again, if you did the home volume # again, if you did the home volume
mount --mkdir /dev/disk/by-label/nixhome /mnt/home mount --mkdir /dev/disk/by-label/nixhome /mnt/home
# turn on swap # turn on swap
@@ -55,13 +61,11 @@ swapon /dev/disk/by-label/nixswap
``` ```
3. prepare nixos 3. prepare nixos
```bash ```bash
# generate templates and update the hardware-configuration.nix # generate templates and update the hardware-configuration.nix
sudo nixos-generate-config --root /mnt nixos-generate-config --root /mnt
# add cryptd to the kernelModules # no extra kernelModules needed, luks and lvm load dm_crypt and dm_mod themselves
boot.initrd.kernelModules = [ "dm-snapshot" "cryptd" ];
# add file systems using labels # add file systems using labels
fileSystems."/" = fileSystems."/" =
@@ -71,7 +75,7 @@ fileSystems."/" =
fileSystems."/boot" = fileSystems."/boot" =
{ device = "/dev/disk/by-label/nixboot"; { device = "/dev/disk/by-label/nixboot";
fsType = "vfat"; fsType = "vfat";
options = [ "fmask=0022" "dmask=0022" ]; options = [ "fmask=0077" "dmask=0077" ]; # only root may read /boot
}; };
fileSystems."/home" = fileSystems."/home" =
{ device = "/dev/disk/by-label/nixhome"; { device = "/dev/disk/by-label/nixhome";
@@ -82,29 +86,118 @@ swapDevices =
]; ];
# point the bootloader to the luks device # point the bootloader to the luks device
boot.initrd.luks.devices."cryptroot".device = "/dev/disk/by-label/nixcrypt"; boot.initrd.luks.devices."cryptroot" = {
device = "/dev/disk/by-label/nixcrypt";
# without this fstrim never reaches the ssd
allowDiscards = true;
# lower latency on nvme
bypassWorkqueues = true;
};
``` ```
4. install nixos 4. install nixos
```bash ```bash
cd /mnt nixos-install
sudo nixos-install
``` ```
## how to deploy the inital config ## how to deploy the initial config
- Don't forget to install the bootloader, if you changed it since `nixos-install` - Don't forget to install the bootloader, if you changed it since `nixos-install`
- The fresh install has no flakes and no git yet, a temporary shell is enough
- If the installer iso is older than the flake's nixpkgs, `--no-reexec` keeps
`nixos-rebuild` from re-executing a newer version of itself, which can fail
against the older systemd of the fresh install (only needed once)
- Set a password for the user before rebooting, `users.nix` doesn't set one
```bash ```bash
$ sudo nixos-rebuild --install-bootloader switch --flake .#host_name $ export NIX_CONFIG="experimental-features = nix-command flakes"
$ nix-shell -p git
$ sudo nixos-rebuild --install-bootloader boot --flake .#host_name --no-reexec
$ sudo passwd aaron
```
## how to enable secure boot
Secure Boot uses lanzaboote with our own keys, see `modules/nixos/lanzaboote.nix`.
Do this after the initial config is deployed and boots.
1. create the keys, before the first rebuild with the lanzaboote module
```bash
# the keys end up in /var/lib/sbctl, they never leave the host
$ sudo nix run nixpkgs#sbctl -- create-keys
```
2. import `modules/nixos/lanzaboote.nix` in the host's `configuration.nix`, rebuild and check the signatures
```bash
$ sudo nixos-rebuild switch --flake .#host_name
# EFI/Linux/*.efi and the bootloader must be signed, kernels in EFI/nixos
# are not, lanzaboote checks them by hash
$ sudo sbctl verify
```
3. reboot once with Secure Boot still disabled, to make sure the new entries boot
4. in the firmware (F2), erase all Secure Boot keys, then boot nixos again
```bash
# "Setup Mode: ✗ Enabled", the ✗ only means the state is insecure
$ sudo sbctl status
```
5. enroll the keys
```bash
# only our own keys, no microsoft keys
$ sudo sbctl enroll-keys
```
- sbctl refuses if the TPM eventlog shows option ROMs (e.g. a dedicated gpu).
Don't force it, either trust exactly those with `--tpm-eventlog` or
microsoft's keys with `--microsoft`. Without either, the firmware may not
start the device, in the worst case the machine doesn't boot at all.
- Check what sbctl found first, a real option ROM has a PCI device path:
```bash
$ sudo nix shell nixpkgs#tpm2-tools -c tpm2_eventlog /sys/kernel/security/tpm0/binary_bios_measurements | grep -A14 "EV_EFI_BOOT_SERVICES_DRIVER"
```
- Paths starting with `0407` (firmware volume) are drivers from the firmware
itself, not option ROMs (e.g. on the ThinkPad). `--tpm-eventlog` trusts
exactly those, after a firmware update they may need to be enrolled again
(disable Secure Boot, `sbctl enroll-keys --tpm-eventlog`)
- Without an integrated gpu (argon), the gpu's option ROM draws the firmware
setup too, use `--microsoft` there, a refused gpu means no picture at all
- On the Framework (krypton), keep the firmware's built-in OEM certificates
with `--firmware-builtin`, vendor firmware updates may need them. If an
update fails or the keys were enrolled without them, erase the keys in the
firmware again (Setup Mode) and re-enroll:
```bash
$ sudo sbctl enroll-keys --firmware-builtin
```
6. enable Secure Boot in the firmware and set a firmware password, then check
```bash
$ bootctl status | grep "Secure Boot" # enabled (user)
$ sudo sbctl status # Secure Boot: ✓ Enabled
```
- If it doesn't boot anymore, disabling Secure Boot in the firmware boots as before
- Losing the keys isn't fatal: erase the keys in the firmware and start over at step 1
## how to unlock the disk with the tpm (laptops)
Needs Secure Boot first. The TPM releases the key only with the PIN and while
the Secure Boot state (PCR 7) is unchanged. The passphrase stays as fallback.
1. enroll the TPM with a PIN as an additional key slot
```bash
# asks for the current passphrase, then the new PIN
$ sudo systemd-cryptenroll --tpm2-device=auto --tpm2-pcrs=7 --tpm2-with-pin=yes /dev/disk/by-label/nixcrypt
```
2. import `modules/nixos/tpm-unlock.nix` in the host's `configuration.nix`, rebuild and reboot
- If the passphrase is suddenly asked for instead of the PIN, the Secure Boot
state changed. After a firmware update that's expected, otherwise investigate
before typing the passphrase. To re-enroll:
```bash
$ sudo systemd-cryptenroll --wipe-slot=tpm2 --tpm2-device=auto --tpm2-pcrs=7 --tpm2-with-pin=yes /dev/disk/by-label/nixcrypt
``` ```
## how to upgrade the system ## how to upgrade the system
```bash ```bash
$ cd /path/to/repo $ cd /path/to/repo
$ sudo nix flake update $ nix flake update
$ sudo nixos-rebuild switch --flake .#host_name $ sudo nixos-rebuild switch --flake .#host_name
$ sudo nix-collect-garbage $ sudo nix-collect-garbage
``` ```
@@ -114,7 +207,6 @@ $ sudo nix-collect-garbage
The tool nix-helper is installed by this configuration. It simplifies administrating nixos and adds more output to the rebuild command. It also features a diff after a successful build. The command uses the `NH_FLAKE` environment variable to be able to run from whatever directory. The tool nix-helper is installed by this configuration. It simplifies administrating nixos and adds more output to the rebuild command. It also features a diff after a successful build. The command uses the `NH_FLAKE` environment variable to be able to run from whatever directory.
Basic commands with a set `NH_FLAKE` variable are: Basic commands with a set `NH_FLAKE` variable are:
```bash ```bash
$ nh os switch $ nh os switch
$ nh os build $ nh os build
+10 -10
View File
@@ -6,20 +6,20 @@ My personal NixOS configurations.
```bash ```bash
. .
├── flake.lock ├── flake.nix # hosts and home-manager wiring
├── flake.nix # flake definition
├── hosts ├── hosts
│   └── neon │ ├── argon # desktop
│   ├── configuration.nix # import nix-modules for specific host │ ├── neon # laptop
│   └── hardware-configuration.nix # hardware configs for specific host │ └── krypton # second laptop
│ ├── configuration.nix # host-specific settings and module imports
│ ├── hardware-configuration.nix # generated by nixos-generate-config
│ └── niri.nix # host-specific niri settings (outputs, input)
├── modules ├── modules
│   ├── home-manager │ ├── home-manager # user modules, imported by users/aaron/home.nix
│   │   ├── xyz_module.nix │ └── nixos # system modules, imported by the hosts
│   └── nixos
│   └── xyz_module.nix
└── users └── users
└── aaron └── aaron
└── home.nix # import home-manager modules for specific user └── home.nix # imports home-manager modules
``` ```
## installation ## installation
+65
View File
@@ -0,0 +1,65 @@
{
"nodes": {
"devenv": {
"locked": {
"dir": "src/modules",
"lastModified": 1790701375,
"narHash": "sha256-0FpLHIRDYiyo3EMTnMQSobZQknZaa3JuWo6vmMCK76o=",
"owner": "cachix",
"repo": "devenv",
"rev": "fe20b5cba7ab5e93ae73f956a8d3efc50e1753f4",
"type": "github"
},
"original": {
"dir": "src/modules",
"owner": "cachix",
"repo": "devenv",
"type": "github"
}
},
"nixpkgs": {
"inputs": {
"nixpkgs-src": "nixpkgs-src"
},
"locked": {
"lastModified": 1789506231,
"narHash": "sha256-vNkJbtmqyBfFhn/HnzQo4ROuoyYWuy/allqTfJb4kMY=",
"owner": "cachix",
"repo": "devenv-nixpkgs",
"rev": "c2f38fe7f9e04d9aadd354d380f2bd40531d9737",
"type": "github"
},
"original": {
"owner": "cachix",
"ref": "rolling",
"repo": "devenv-nixpkgs",
"type": "github"
}
},
"nixpkgs-src": {
"flake": false,
"locked": {
"lastModified": 1789370336,
"narHash": "sha256-6RSEDHIWQtesQKWSu5qRai8L2h4KgCgMEfJHstW99G4=",
"owner": "NixOS",
"repo": "nixpkgs",
"rev": "c7def046b9a883d46974757852106483d741586f",
"type": "github"
},
"original": {
"owner": "NixOS",
"ref": "nixpkgs-unstable",
"repo": "nixpkgs",
"type": "github"
}
},
"root": {
"inputs": {
"devenv": "devenv",
"nixpkgs": "nixpkgs"
}
}
},
"root": "root",
"version": 7
}
+29
View File
@@ -0,0 +1,29 @@
{ pkgs, ... }:
{
packages = with pkgs; [
# gitea (git.0x29a.ch)
tea
# nix tooling
nixfmt # official formatter (RFC 166 style)
statix # lints for nix anti-patterns
deadnix # finds unused bindings and arguments
nixd # language server
nvd # diff system generations
];
scripts = {
lint.exec = ''
set -e
statix check .
deadnix --fail --exclude hosts/*/hardware-configuration.nix -- .
'';
fmt.exec = ''
nixfmt $(git ls-files '*.nix')
'';
};
enterShell = ''
echo "nixconfig devenv: tea, lint, fmt"
'';
}
+3
View File
@@ -0,0 +1,3 @@
inputs:
nixpkgs:
url: github:cachix/devenv-nixpkgs/rolling
Generated
+420 -19
View File
@@ -1,5 +1,120 @@
{ {
"nodes": { "nodes": {
"base16": {
"inputs": {
"fromYaml": "fromYaml"
},
"locked": {
"lastModified": 1755819240,
"narHash": "sha256-qcMhnL7aGAuFuutH4rq9fvAhCpJWVHLcHVZLtPctPlo=",
"owner": "SenchoPens",
"repo": "base16.nix",
"rev": "75ed5e5e3fce37df22e49125181fa37899c3ccd6",
"type": "github"
},
"original": {
"owner": "SenchoPens",
"repo": "base16.nix",
"type": "github"
}
},
"base16-fish": {
"flake": false,
"locked": {
"lastModified": 1765809053,
"narHash": "sha256-XCUQLoLfBJ8saWms2HCIj4NEN+xNsWBlU1NrEPcQG4s=",
"owner": "tomyun",
"repo": "base16-fish",
"rev": "86cbea4dca62e08fb7fd83a70e96472f92574782",
"type": "github"
},
"original": {
"owner": "tomyun",
"repo": "base16-fish",
"rev": "86cbea4dca62e08fb7fd83a70e96472f92574782",
"type": "github"
}
},
"base16-helix": {
"flake": false,
"locked": {
"lastModified": 1776754714,
"narHash": "sha256-E3OAK27smtATTmX45uoTSRsVD+Y+ZiVVfgM/tjpbtYg=",
"owner": "tinted-theming",
"repo": "base16-helix",
"rev": "4d508123037e7851ad36ebf7d9c48b0e9e1eb581",
"type": "github"
},
"original": {
"owner": "tinted-theming",
"repo": "base16-helix",
"type": "github"
}
},
"base16-vim": {
"flake": false,
"locked": {
"lastModified": 1732806396,
"narHash": "sha256-e0bpPySdJf0F68Ndanwm+KWHgQiZ0s7liLhvJSWDNsA=",
"owner": "tinted-theming",
"repo": "base16-vim",
"rev": "577fe8125d74ff456cf942c733a85d769afe58b7",
"type": "github"
},
"original": {
"owner": "tinted-theming",
"repo": "base16-vim",
"rev": "577fe8125d74ff456cf942c733a85d769afe58b7",
"type": "github"
}
},
"crane": {
"locked": {
"lastModified": 1789760033,
"narHash": "sha256-jtT4yxZpR8seYnlCMMWSSPlFN92zO6ICuZ8pJrmi86k=",
"owner": "ipetkov",
"repo": "crane",
"rev": "73b980519cefc727a5f6cc8e5c0947a2f9be6edd",
"type": "github"
},
"original": {
"owner": "ipetkov",
"repo": "crane",
"type": "github"
}
},
"firefox-gnome-theme": {
"flake": false,
"locked": {
"lastModified": 1783570805,
"narHash": "sha256-ptl5aRlCv9/uRSv2u8Hq8UFVFeZ6Q/bT049bpqNgc3w=",
"owner": "rafaelmardojai",
"repo": "firefox-gnome-theme",
"rev": "5602ed62d638142c1ab31dccd01dfbfb28841225",
"type": "github"
},
"original": {
"owner": "rafaelmardojai",
"repo": "firefox-gnome-theme",
"type": "github"
}
},
"flake-compat": {
"flake": false,
"locked": {
"lastModified": 1767039857,
"narHash": "sha256-vNpUSpF5Nuw8xvDLj2KCwwksIbjua2LZCqhV1LNRDns=",
"owner": "NixOS",
"repo": "flake-compat",
"rev": "5edf11c44bc78a0d334f6334cdaf7d60d732daab",
"type": "github"
},
"original": {
"owner": "NixOS",
"repo": "flake-compat",
"type": "github"
}
},
"flake-parts": { "flake-parts": {
"inputs": { "inputs": {
"nixpkgs-lib": [ "nixpkgs-lib": [
@@ -8,11 +123,11 @@
] ]
}, },
"locked": { "locked": {
"lastModified": 1769996383, "lastModified": 1790898470,
"narHash": "sha256-AnYjnFWgS49RlqX7LrC4uA+sCCDBj0Ry/WOJ5XWAsa0=", "narHash": "sha256-zTwuwezD0w3hpga6a6P8emidzAZFyWqlNeRBlpWOOl8=",
"owner": "hercules-ci", "owner": "hercules-ci",
"repo": "flake-parts", "repo": "flake-parts",
"rev": "57928607ea566b5db3ad13af0e57e921e6b12381", "rev": "024633cd702b10285db5cb19b40ad48d2399ba60",
"type": "github" "type": "github"
}, },
"original": { "original": {
@@ -21,6 +136,62 @@
"type": "github" "type": "github"
} }
}, },
"flake-parts_2": {
"inputs": {
"nixpkgs-lib": [
"stylix",
"nixpkgs"
]
},
"locked": {
"lastModified": 1782949081,
"narHash": "sha256-vp6Y/Grm98ESt6ceOkWiHWyZRDV3J1RID4w+6NWK9yA=",
"owner": "hercules-ci",
"repo": "flake-parts",
"rev": "17c9d6cdfc60c64f4ee8d306f9bc0b4ccb51481e",
"type": "github"
},
"original": {
"owner": "hercules-ci",
"repo": "flake-parts",
"type": "github"
}
},
"fromYaml": {
"flake": false,
"locked": {
"lastModified": 1731966426,
"narHash": "sha256-lq95WydhbUTWig/JpqiB7oViTcHFP8Lv41IGtayokA8=",
"owner": "SenchoPens",
"repo": "fromYaml",
"rev": "106af9e2f715e2d828df706c386a685698f3223b",
"type": "github"
},
"original": {
"owner": "SenchoPens",
"repo": "fromYaml",
"type": "github"
}
},
"gnome-shell": {
"flake": false,
"locked": {
"host": "gitlab.gnome.org",
"lastModified": 1776175984,
"narHash": "sha256-RJFlFW8GiMei6oqUGrMkGEvVqOH8U7Q8abc1yK4VKD8=",
"owner": "GNOME",
"repo": "gnome-shell",
"rev": "e0fdc4c13250e9a9b8ea9594c83925274f4a5dca",
"type": "gitlab"
},
"original": {
"host": "gitlab.gnome.org",
"owner": "GNOME",
"ref": "50.1",
"repo": "gnome-shell",
"type": "gitlab"
}
},
"home-manager": { "home-manager": {
"inputs": { "inputs": {
"nixpkgs": [ "nixpkgs": [
@@ -28,11 +199,11 @@
] ]
}, },
"locked": { "locked": {
"lastModified": 1771519029, "lastModified": 1791642191,
"narHash": "sha256-H59Qf82wv5kBXVoyXsmUKW+9J3o8FqgY4uKaLdsLdLg=", "narHash": "sha256-0bK0A59rVUn1SRZzo4cNi4VSqAe7vR1gL2/MZl53Frw=",
"owner": "nix-community", "owner": "nix-community",
"repo": "home-manager", "repo": "home-manager",
"rev": "167e0b6837115e672ec5f58e2b0ea39093abe807", "rev": "c58f54c733a7894d84fa2fdff26cc12088c4b78c",
"type": "github" "type": "github"
}, },
"original": { "original": {
@@ -41,13 +212,57 @@
"type": "github" "type": "github"
} }
}, },
"lanzaboote": {
"inputs": {
"crane": "crane",
"nixpkgs": [
"nixpkgs"
],
"pre-commit": "pre-commit",
"rust-overlay": "rust-overlay"
},
"locked": {
"lastModified": 1790423250,
"narHash": "sha256-sr4Kfp6yaXUeyKL6n0Y8/ElcR3momIRC20HFc+LF22s=",
"owner": "nix-community",
"repo": "lanzaboote",
"rev": "c1c5edd31802d181c8aa2c71588995d93425d650",
"type": "github"
},
"original": {
"owner": "nix-community",
"ref": "v1.2.0",
"repo": "lanzaboote",
"type": "github"
}
},
"nixos-hardware": {
"inputs": {
"nixpkgs": [
"nixpkgs"
]
},
"locked": {
"lastModified": 1791721963,
"narHash": "sha256-BYhx89XJltnRyQeuDKHVL5eSqbbfAcOKuDts7QRsrxQ=",
"owner": "NixOS",
"repo": "nixos-hardware",
"rev": "60a624466c08787ee8303393b7d4752d1826f14f",
"type": "github"
},
"original": {
"owner": "NixOS",
"repo": "nixos-hardware",
"type": "github"
}
},
"nixpkgs": { "nixpkgs": {
"locked": { "locked": {
"lastModified": 1771369470, "lastModified": 1791594108,
"narHash": "sha256-0NBlEBKkN3lufyvFegY4TYv5mCNHbi5OmBDrzihbBMQ=", "narHash": "sha256-XK4KceonkwD8LuMAt/vNrz982mXJM5jeHAxMwsUXXAQ=",
"owner": "nixos", "owner": "nixos",
"repo": "nixpkgs", "repo": "nixpkgs",
"rev": "0182a361324364ae3f436a63005877674cf45efb", "rev": "6510408d147d8c5e6d76043e899e9251756f6a75",
"type": "github" "type": "github"
}, },
"original": { "original": {
@@ -66,11 +281,11 @@
"systems": "systems" "systems": "systems"
}, },
"locked": { "locked": {
"lastModified": 1771135771, "lastModified": 1791769517,
"narHash": "sha256-wyvBIhDuyCRyjB3yPg77qoyxrlgQtBR1rVW3c9knV3E=", "narHash": "sha256-OVx8OKPdW1fLfDi1oemFkfSvF354UwU5I0GXnNAGygw=",
"owner": "nix-community", "owner": "nix-community",
"repo": "nixvim", "repo": "nixvim",
"rev": "ed0424f0b08d303a7348f52f7850ad1b2704f9ba", "rev": "84e901ee80e6523068dc3baf86cbf7cdcbf16902",
"type": "github" "type": "github"
}, },
"original": { "original": {
@@ -86,11 +301,11 @@
] ]
}, },
"locked": { "locked": {
"lastModified": 1771513929, "lastModified": 1791817518,
"narHash": "sha256-dPeHevAT1Cb2w/Wrfz/d5i6RfO8bvbGl/KrTPxU2l3w=", "narHash": "sha256-DGVFzc0YXy38vCuS43PZPIkTVKaKxpNgzkNmJsHouP8=",
"owner": "noctalia-dev", "owner": "noctalia-dev",
"repo": "noctalia-shell", "repo": "noctalia-shell",
"rev": "9c47ce03f200e0b8fc515d973440d5bc3e359785", "rev": "02cb10745d6274e4a696a00308c8ef4cefa7416d",
"type": "github" "type": "github"
}, },
"original": { "original": {
@@ -99,28 +314,214 @@
"type": "github" "type": "github"
} }
}, },
"nur": {
"inputs": {
"flake-parts": [
"stylix",
"flake-parts"
],
"nixpkgs": [
"stylix",
"nixpkgs"
]
},
"locked": {
"lastModified": 1785549842,
"narHash": "sha256-DCwBZmGsySF7oKGTRgEv2HvpxVXkHT+38VhTM76k0B4=",
"owner": "nix-community",
"repo": "NUR",
"rev": "a9f987b57594e845e3e5cdd423b9a70846d70308",
"type": "github"
},
"original": {
"owner": "nix-community",
"repo": "NUR",
"type": "github"
}
},
"pre-commit": {
"inputs": {
"flake-compat": "flake-compat",
"nixpkgs": [
"lanzaboote",
"nixpkgs"
]
},
"locked": {
"lastModified": 1789514889,
"narHash": "sha256-PFD1nxptCXJyJoiYO1gf/5Vv43yqGpHtMC6LUhl9/pQ=",
"owner": "cachix",
"repo": "git-hooks.nix",
"rev": "59f4ca0d063a1a3ec722c88b51a33004862e5379",
"type": "github"
},
"original": {
"owner": "cachix",
"repo": "git-hooks.nix",
"type": "github"
}
},
"root": { "root": {
"inputs": { "inputs": {
"home-manager": "home-manager", "home-manager": "home-manager",
"lanzaboote": "lanzaboote",
"nixos-hardware": "nixos-hardware",
"nixpkgs": "nixpkgs", "nixpkgs": "nixpkgs",
"nixvim": "nixvim", "nixvim": "nixvim",
"noctalia": "noctalia" "noctalia": "noctalia",
"stylix": "stylix"
}
},
"rust-overlay": {
"inputs": {
"nixpkgs": [
"lanzaboote",
"nixpkgs"
]
},
"locked": {
"lastModified": 1789889921,
"narHash": "sha256-aL/ogiN7qZCGeNovS1f9hX73jwYIKb4Pcq6AZm57WtY=",
"owner": "oxalica",
"repo": "rust-overlay",
"rev": "1fb104a12a8667045559b2575d6d448ae2fbd99b",
"type": "github"
},
"original": {
"owner": "oxalica",
"repo": "rust-overlay",
"type": "github"
}
},
"stylix": {
"inputs": {
"base16": "base16",
"base16-fish": "base16-fish",
"base16-helix": "base16-helix",
"base16-vim": "base16-vim",
"firefox-gnome-theme": "firefox-gnome-theme",
"flake-parts": "flake-parts_2",
"gnome-shell": "gnome-shell",
"nixpkgs": [
"nixpkgs"
],
"nur": "nur",
"systems": "systems_2",
"tinted-kitty": "tinted-kitty",
"tinted-schemes": "tinted-schemes",
"tinted-tmux": "tinted-tmux",
"tinted-zed": "tinted-zed"
},
"locked": {
"lastModified": 1791574276,
"narHash": "sha256-UMnLnZ3JlA7UTBNNNx1rNsXYoPP/cirXLCKGiQ/yDx8=",
"owner": "nix-community",
"repo": "stylix",
"rev": "2856c4c6a845b9bec98828ef197abe176e4806bb",
"type": "github"
},
"original": {
"owner": "nix-community",
"repo": "stylix",
"type": "github"
} }
}, },
"systems": { "systems": {
"flake": false,
"locked": { "locked": {
"lastModified": 1681028828, "lastModified": 1791244623,
"narHash": "sha256-Vy1rq5AaRuLzOxct8nz4T6wlgyUR7zLU309k9mBC768=", "narHash": "sha256-uuanbkFk8a313Zfrxdcz8Us/yQtaxNnKJtX8v0ZPpd8=",
"owner": "nix-systems", "owner": "nix-systems",
"repo": "default", "repo": "default",
"rev": "da67096a3b9bf56a91d16901293e51ba5b49a27e", "rev": "d36eeed142f88b5a636f2e3856a53c61654cf29b",
"type": "github" "type": "github"
}, },
"original": { "original": {
"owner": "nix-systems", "owner": "nix-systems",
"ref": "future-26.11",
"repo": "default", "repo": "default",
"type": "github" "type": "github"
} }
},
"systems_2": {
"locked": {
"lastModified": 1774449309,
"narHash": "sha256-brhZ8DmuGtzkCYHJg4HEd602amKm89Y9ytsFZ5uWD1w=",
"owner": "nix-systems",
"repo": "default",
"rev": "c29398b59d2048c4ab79345812849c9bd15e9150",
"type": "github"
},
"original": {
"owner": "nix-systems",
"ref": "future-26.11",
"repo": "default",
"type": "github"
}
},
"tinted-kitty": {
"flake": false,
"locked": {
"lastModified": 1735730497,
"narHash": "sha256-4KtB+FiUzIeK/4aHCKce3V9HwRvYaxX+F1edUrfgzb8=",
"owner": "tinted-theming",
"repo": "tinted-kitty",
"rev": "de6f888497f2c6b2279361bfc790f164bfd0f3fa",
"type": "github"
},
"original": {
"owner": "tinted-theming",
"repo": "tinted-kitty",
"type": "github"
}
},
"tinted-schemes": {
"flake": false,
"locked": {
"lastModified": 1785153830,
"narHash": "sha256-fNdfCTeCXU3tZG3TMincd+u68qBHQgCr2Ljr/M1mWP0=",
"owner": "tinted-theming",
"repo": "schemes",
"rev": "9bd28ed313560db3c5b605c63bc4e309e78e3fc8",
"type": "github"
},
"original": {
"owner": "tinted-theming",
"repo": "schemes",
"type": "github"
}
},
"tinted-tmux": {
"flake": false,
"locked": {
"lastModified": 1785031658,
"narHash": "sha256-mZp9O2LjzdMzlqQF3l3fjqsuPBzXy+1qTfBEUGjTlpk=",
"owner": "tinted-theming",
"repo": "tinted-tmux",
"rev": "5d2c67f61ea7af36f16865ab6d541cdba41dc257",
"type": "github"
},
"original": {
"owner": "tinted-theming",
"repo": "tinted-tmux",
"type": "github"
}
},
"tinted-zed": {
"flake": false,
"locked": {
"lastModified": 1785030526,
"narHash": "sha256-klZf8UviewRkxuu74Bhbq6tqy7oxebQC7UVRWbbtQxU=",
"owner": "tinted-theming",
"repo": "base16-zed",
"rev": "16f5a8adf4a6b1310d0a61ab172de963e8f76a02",
"type": "github"
},
"original": {
"owner": "tinted-theming",
"repo": "base16-zed",
"type": "github"
}
} }
}, },
"root": "root", "root": "root",
+51 -38
View File
@@ -11,48 +11,61 @@
url = "github:noctalia-dev/noctalia-shell"; url = "github:noctalia-dev/noctalia-shell";
inputs.nixpkgs.follows = "nixpkgs"; inputs.nixpkgs.follows = "nixpkgs";
}; };
lanzaboote = {
url = "github:nix-community/lanzaboote/v1.2.0";
inputs.nixpkgs.follows = "nixpkgs";
};
nixos-hardware = {
url = "github:NixOS/nixos-hardware";
inputs.nixpkgs.follows = "nixpkgs";
};
nixvim = { nixvim = {
url = "github:nix-community/nixvim"; url = "github:nix-community/nixvim";
inputs.nixpkgs.follows = "nixpkgs"; inputs.nixpkgs.follows = "nixpkgs";
}; };
}; stylix = {
url = "github:nix-community/stylix";
outputs = { self, nixpkgs, home-manager, nixvim, ... }@inputs: { inputs.nixpkgs.follows = "nixpkgs";
nixosConfigurations = {
default = nixpkgs.lib.nixosSystem {
system = "x86_64-linux";
specialArgs = { inherit inputs; };
modules = [
./hosts/default/hardware-configuration.nix
./hosts/default/configuration.nix
home-manager.nixosModules.home-manager
{
home-manager.extraSpecialArgs = { inherit inputs; };
home-manager.users.aaron.imports = [
nixvim.homeModules.nixvim
./users/aaron/home.nix
];
}
];
};
neon = nixpkgs.lib.nixosSystem {
system = "x86_64-linux";
specialArgs = { inherit inputs; };
modules = [
./hosts/neon/hardware-configuration.nix
./hosts/neon/configuration.nix
home-manager.nixosModules.home-manager
{
home-manager.extraSpecialArgs = { inherit inputs; };
home-manager.users.aaron.imports = [
nixvim.homeModules.nixvim
./users/aaron/home.nix
];
}
];
};
}; };
}; };
outputs =
{
nixpkgs,
home-manager,
nixvim,
stylix,
...
}@inputs:
let
mkHost =
hostName:
nixpkgs.lib.nixosSystem {
system = "x86_64-linux";
specialArgs = { inherit inputs; };
modules = [
./hosts/${hostName}/hardware-configuration.nix
./hosts/${hostName}/configuration.nix
home-manager.nixosModules.home-manager
{
home-manager.useGlobalPkgs = true;
home-manager.useUserPackages = true;
home-manager.backupCommand = "mv -f {file} {file}.hm-bak-$(date +%Y%m%d%H%M%S)";
home-manager.extraSpecialArgs = { inherit inputs; };
home-manager.users.aaron.imports = [
nixvim.homeModules.nixvim
stylix.homeModules.stylix
./users/aaron/home.nix
];
}
];
};
in
{
nixosConfigurations = {
neon = mkHost "neon";
argon = mkHost "argon";
krypton = mkHost "krypton";
};
};
} }
+57
View File
@@ -0,0 +1,57 @@
# argon: desktop with an amd gpu and three luks-encrypted data drives.
{ pkgs, ... }:
{
imports = [
../../modules/nixos/appimage.nix
../../modules/nixos/astro.nix
../../modules/nixos/audio.nix
../../modules/nixos/bootloader.nix
../../modules/nixos/certificates.nix
../../modules/nixos/data-drives.nix
../../modules/nixos/docker.nix
../../modules/nixos/gnupg.nix
../../modules/nixos/lanzaboote.nix
../../modules/nixos/locales.nix
../../modules/nixos/networking.nix
../../modules/nixos/niri.nix
../../modules/nixos/noctalia-greeter.nix
../../modules/nixos/noctalia.nix
../../modules/nixos/openssh.nix
../../modules/nixos/packages.nix
../../modules/nixos/protonvpn.nix
../../modules/nixos/services.nix
../../modules/nixos/settings.nix
../../modules/nixos/steam.nix
../../modules/nixos/thunar.nix
../../modules/nixos/tpm-unlock.nix
../../modules/nixos/users.nix
../../modules/nixos/vial.nix
];
# host-specific niri config (outputs, input devices)
home-manager.users.aaron.imports = [ ./niri.nix ];
# amd gpu: mesa/vulkan, and amdgpu in the initrd for plymouth
hardware.graphics = {
enable = true;
enable32Bit = true;
};
hardware.amdgpu.initrd.enable = true;
# encrypted data drives, see data-drives.nix
local.dataDrives = {
data1 = "dfae62cc-bad1-4879-bf9a-461bde833625";
data2 = "8312edae-9247-481b-a313-52a7f848f027";
nvmecache = "2352250e-4ebe-4f9a-bf66-0d4aaa961bd8";
};
environment.systemPackages = with pkgs; [
amdgpu_top
calibre # ebook management and kobo syncing
];
networking.hostName = "argon";
system.stateVersion = "25.11"; # don't change
}
+58
View File
@@ -0,0 +1,58 @@
# Do not modify this file! It was generated by ‘nixos-generate-config’
# and may be overwritten by future invocations. Please make changes
# to /etc/nixos/configuration.nix instead.
{
config,
lib,
pkgs,
modulesPath,
...
}:
{
imports = [
(modulesPath + "/installer/scan/not-detected.nix")
];
boot.initrd.availableKernelModules = [
"nvme"
"xhci_pci"
"ahci"
"usbhid"
"usb_storage"
"sd_mod"
];
boot.initrd.luks.devices."cryptroot" = {
device = "/dev/disk/by-label/nixcrypt";
allowDiscards = true;
bypassWorkqueues = true;
};
boot.kernelModules = [ ];
boot.extraModulePackages = [ ];
fileSystems."/" = {
device = "/dev/disk/by-label/nixroot";
fsType = "ext4";
};
fileSystems."/boot" = {
device = "/dev/disk/by-label/nixboot";
fsType = "vfat";
options = [
"fmask=0077"
"dmask=0077"
];
};
fileSystems."/home" = {
device = "/dev/disk/by-label/nixhome";
fsType = "ext4";
};
swapDevices = [
{ device = "/dev/disk/by-label/nixswap"; }
];
nixpkgs.hostPlatform = lib.mkDefault "x86_64-linux";
hardware.cpu.amd.updateMicrocode = lib.mkDefault config.hardware.enableRedistributableFirmware;
}
+37
View File
@@ -0,0 +1,37 @@
# argon: desktop with two 1440p monitors side by side
{
wayland.windowManager.niri.settings = {
input = {
touchpad.off = { };
trackpoint.off = { };
};
_children = [
{
output = {
_args = [ "DP-1" ];
mode = "2560x1440@165.000";
scale = 1;
transform = "normal";
position._props = {
x = 0;
y = 0;
};
};
}
{
output = {
_args = [ "DP-2" ];
mode = "2560x1440@143.912";
scale = 1;
transform = "normal";
position._props = {
x = 2560;
y = 0;
};
};
}
];
};
}
-138
View File
@@ -1,138 +0,0 @@
# 0x29a nixos conifg
{ pkgs, lib, ... }:
{
imports =
[
./hardware-configuration.nix
];
# use flakes
nix.settings.experimental-features = [ "nix-command" "flakes" ];
# configure bootloader
boot.loader.systemd-boot.enable = false;
boot.loader.grub = {
enable = true;
device = "nodev";
efiSupport = true;
};
boot.loader.efi.canTouchEfiVariables = true;
boot.kernelParams = [
"quiet"
"console.ttyS0,115200n8" # allow terminals on serial console
];
# plymouth boot eye candy
boot.initrd.systemd.enable = true;
boot.plymouth.enable = true;
boot.plymouth.theme = "spinner";
# use latest kernel
boot.kernelPackages = pkgs.linuxPackages_latest;
# guest agent for proxmox
services.qemuGuest.enable = true;
# networking
networking.hostName = "nixos";
networking.networkmanager.enable = true;
# time zone.
time.timeZone = "Europe/Amsterdam";
# select internationalisation properties
i18n.defaultLocale = "en_US.UTF-8";
i18n.extraLocaleSettings = {
LC_ADDRESS = "en_US.UTF-8";
LC_IDENTIFICATION = "en_US.UTF-8";
LC_MEASUREMENT = "en_US.UTF-8";
LC_MONETARY = "en_US.UTF-8";
LC_NAME = "en_US.UTF-8";
LC_NUMERIC = "en_US.UTF-8";
LC_PAPER = "en_US.UTF-8";
LC_TELEPHONE = "en_US.UTF-8";
LC_TIME = "en_US.UTF-8";
};
console = {
font = "Lat2-Terminus16";
keyMap = "de_CH-latin1";
};
# window manager configs
services.xserver = {
enable = true;
xkb.layout = "ch";
xkb.options = "eurosign:e,caps:escape";
windowManager.qtile = {
enable = true;
extraPackages = python3Packages: with python3Packages; [
qtile-extras
];
};
};
environment.pathsToLink = [ "/libexec" ];
environment.variables.EDITOR = "vim";
# enable sound
services.pipewire = {
enable = true;
pulse.enable = true;
};
# define a user account
users.users.aaron = {
isNormalUser = true;
group = "users";
extraGroups = [ "wheel" ];
shell = pkgs.zsh;
packages = with pkgs; [
tree
fastfetch
];
};
# browser
programs.firefox.enable = true;
# zsh config
programs.zsh = {
enable = true;
enableCompletion = true;
autosuggestions.enable = true;
ohMyZsh = {
enable = true;
plugins = [ "git" "sudo" ];
theme = "agnoster";
};
};
# system packages
environment.systemPackages = with pkgs; [
vim
neovim
git
ghostty
kitty
wget
gnupg
];
# Some programs need SUID wrappers
programs.mtr.enable = true;
programs.gnupg.agent = {
enable = true;
enableSSHSupport = true;
};
# enable the OpenSSH daemon
services.openssh.enable = true;
# firewall configs
networking.firewall.allowedTCPPorts = [ 22 ];
# networking.firewall.allowedUDPPorts = [ ... ];
# install state version
system.stateVersion = "25.05"; # Don't change
}
-40
View File
@@ -1,40 +0,0 @@
# 0x29a nixos hardware configuration
{ config, lib, pkgs, modulesPath, ... }:
{
imports =
[ (modulesPath + "/profiles/qemu-guest.nix")
];
# boot and initrd configs
boot.initrd.availableKernelModules = [ "uhci_hcd" "ehci_pci" "ahci" "virtio_pci" "virtio_scsi" "sd_mod" "sr_mod" ];
boot.initrd.kernelModules = [ "dm-snapshot" "cryptd" ];
boot.kernelModules = [ ];
boot.extraModulePackages = [ ];
boot.initrd.luks.devices."cryptroot".device = "/dev/disk/by-label/nixcrypt";
# file systems
fileSystems."/" =
{ device = "/dev/disk/by-label/nixroot";
fsType = "ext4";
};
fileSystems."/boot" =
{ device = "/dev/disk/by-label/nixboot";
fsType = "vfat";
options = [ "fmask=0022" "dmask=0022" ];
};
fileSystems."/home" =
{ device = "/dev/disk/by-label/nixhome";
fsType = "ext4";
};
swapDevices =
[ { device = "/dev/disk/by-label/nixswap"; }
];
# enable dhcp on all interfaces
networking.useDHCP = lib.mkDefault true;
# set host arch
nixpkgs.hostPlatform = lib.mkDefault "x86_64-linux";
}
-76
View File
@@ -1,76 +0,0 @@
{ config, pkgs, ... }:
{
# user config
home.username = "aaron";
home.homeDirectory = "/home/aaron";
# packages
home.packages = with pkgs; [
fastfetch
zip
xz
unzip
p7zip
jq
mtr
iperf3
dnsutils
ldns
socat
nmap
cowsay
file
which
tree
zstd
gnupg
btop
iotop
iftop
strace
ltrace
lsof
sysstat
lm_sensors
ethtool
pciutils
usbutils
];
# configure git
programs.git.settings = {
enable = true;
userName = "aaron";
userEmail = "aaron@0x29a.ch";
};
programs.zsh = {
enable = true;
autosuggestion.enable = true;
syntaxHighlighting.enable = true;
oh-my-zsh = {
enable = true;
plugins = [ "git" "sudo" "python" "ansible" ];
theme = "agnoster";
};
};
## deploy qtile config
#home.file."qtile-config" = {
# target = ".config/qtile/config.py";
# source = "${inputs.qtile-config}/qtile_config/config.py";
# force = true;
#};
home.sessionVariables = {
EDITOR = "vim";
};
# enable home manager
programs.home-manager.enable = true;
# don't change
home.stateVersion = "25.05";
}
+44
View File
@@ -0,0 +1,44 @@
# krypton: framework 13 pro, intel core ultra x7 358H
{ inputs, ... }:
{
imports = [
inputs.nixos-hardware.nixosModules.framework-intel-core-ultra-series3
../../modules/nixos/appimage.nix
../../modules/nixos/astro.nix
../../modules/nixos/audio.nix
../../modules/nixos/bootloader.nix
../../modules/nixos/certificates.nix
../../modules/nixos/docker.nix
../../modules/nixos/gnupg.nix
../../modules/nixos/lanzaboote.nix
../../modules/nixos/locales.nix
../../modules/nixos/networking.nix
../../modules/nixos/niri.nix
../../modules/nixos/noctalia.nix
../../modules/nixos/openssh.nix
../../modules/nixos/packages.nix
../../modules/nixos/protonvpn.nix
../../modules/nixos/sddm.nix
../../modules/nixos/services.nix
../../modules/nixos/settings.nix
../../modules/nixos/steam.nix
../../modules/nixos/tpm-unlock.nix
../../modules/nixos/users.nix
../../modules/nixos/vial.nix
];
# host-specific niri config (input devices, laptop binds)
home-manager.users.aaron.imports = [ ./niri.nix ];
# hidpi panel (2880x1920): the sddm greeter runs in weston, which doesn't scale
services.displayManager.sddm.settings.General.GreeterEnvironment = "QT_SCALE_FACTOR=2";
# bigger boot menu font, mode found with "r" in the menu; mode 6 is beyond
# what boot.loader.systemd-boot.consoleMode accepts, so set via lanzaboote
boot.lanzaboote.settings.console-mode = "6";
networking.hostName = "krypton";
system.stateVersion = "26.05"; # don't change
}
+60
View File
@@ -0,0 +1,60 @@
# Do not modify this file! It was generated by ‘nixos-generate-config’
# and may be overwritten by future invocations. Please make changes
# to /etc/nixos/configuration.nix instead.
{
config,
lib,
pkgs,
modulesPath,
...
}:
{
imports = [
(modulesPath + "/installer/scan/not-detected.nix")
];
boot.initrd.availableKernelModules = [
"xhci_pci"
"thunderbolt"
"nvme"
"usb_storage"
"sd_mod"
];
boot.initrd.kernelModules = [ "dm-snapshot" ];
boot.initrd.luks.devices."cryptroot" = {
device = "/dev/disk/by-label/nixcrypt";
allowDiscards = true;
bypassWorkqueues = true;
};
boot.kernelModules = [ "kvm-intel" ];
boot.extraModulePackages = [ ];
fileSystems."/" = {
device = "/dev/disk/by-label/nixroot";
fsType = "ext4";
};
fileSystems."/boot" = {
device = "/dev/disk/by-label/nixboot";
fsType = "vfat";
options = [
"fmask=0077"
"dmask=0077"
];
};
fileSystems."/home" = {
device = "/dev/disk/by-label/nixhome";
fsType = "ext4";
};
swapDevices = [
{ device = "/dev/disk/by-label/nixswap"; }
];
nixpkgs.hostPlatform = lib.mkDefault "x86_64-linux";
hardware.cpu.intel.updateMicrocode = lib.mkDefault config.hardware.enableRedistributableFirmware;
hardware.cpu.intel.npu.enable = true;
}
+24
View File
@@ -0,0 +1,24 @@
# krypton: framework 13 laptop, the built-in display is auto-configured by niri
{ lib, ... }:
{
wayland.windowManager.niri.settings = {
input.touchpad = {
tap = { };
natural-scroll = { };
};
layout.gaps = lib.mkForce 10;
binds = {
"Print".screenshot = { };
"Ctrl+Print".screenshot-screen = { };
"Mod+Shift+P".power-off-monitors = { };
# finer brightness steps
"XF86MonBrightnessUp".spawn-sh = lib.mkForce "brightnessctl --class=backlight set +1%";
"XF86MonBrightnessDown".spawn-sh = lib.mkForce "brightnessctl --class=backlight set 1%-";
};
};
}
+31 -4
View File
@@ -1,25 +1,52 @@
{ config, pkgs, inputs, ... }: # neon: thinkpad t14 gen1 (intel)
{
inputs,
lib,
pkgs,
...
}:
{ {
imports = [ imports = [
inputs.nixos-hardware.nixosModules.lenovo-thinkpad-t14-intel-gen1
../../modules/nixos/appimage.nix
../../modules/nixos/astro.nix
../../modules/nixos/audio.nix ../../modules/nixos/audio.nix
../../modules/nixos/bootloader.nix ../../modules/nixos/bootloader.nix
../../modules/nixos/certificates.nix ../../modules/nixos/certificates.nix
../../modules/nixos/docker.nix
../../modules/nixos/gnupg.nix ../../modules/nixos/gnupg.nix
../../modules/nixos/lanzaboote.nix
../../modules/nixos/locales.nix ../../modules/nixos/locales.nix
../../modules/nixos/networking.nix ../../modules/nixos/networking.nix
../../modules/nixos/niri.nix ../../modules/nixos/niri.nix
../../modules/nixos/noctalia.nix ../../modules/nixos/noctalia.nix
../../modules/nixos/openssh.nix ../../modules/nixos/openssh.nix
../../modules/nixos/packages.nix ../../modules/nixos/packages.nix
../../modules/nixos/protonvpn.nix
../../modules/nixos/sddm.nix ../../modules/nixos/sddm.nix
../../modules/nixos/services.nix ../../modules/nixos/services.nix
../../modules/nixos/settings.nix ../../modules/nixos/settings.nix
../../modules/nixos/steam.nix ../../modules/nixos/steam.nix
../../modules/nixos/tpm-unlock.nix
../../modules/nixos/users.nix ../../modules/nixos/users.nix
../../modules/nixos/vial.nix
]; ];
# install state version # host-specific niri config (input devices, laptop binds)
system.stateVersion = "25.11"; # Don't change home-manager.users.aaron.imports = [ ./niri.nix ];
}
# nixos-hardware's intel module adds intel-compute-runtime-legacy1 (opencl),
# which isn't cached and currently fails to build; not needed on neon
hardware.graphics.extraPackages = lib.mkForce (
with pkgs;
[
intel-media-driver
vpl-gpu-rt
]
);
networking.hostName = "neon";
system.stateVersion = "25.11"; # don't change
}
+46 -24
View File
@@ -1,39 +1,61 @@
# Do not modify this file! It was generated by ‘nixos-generate-config’ # Do not modify this file! It was generated by ‘nixos-generate-config’
# and may be overwritten by future invocations. Please make changes # and may be overwritten by future invocations. Please make changes
# to /etc/nixos/configuration.nix instead. # to /etc/nixos/configuration.nix instead.
{ config, lib, pkgs, modulesPath, ... }: {
config,
lib,
pkgs,
modulesPath,
...
}:
{ {
imports = imports = [
[ (modulesPath + "/installer/scan/not-detected.nix") (modulesPath + "/installer/scan/not-detected.nix")
]; ];
boot.initrd.availableKernelModules = [ "xhci_pci" "nvme" "usb_storage" "sd_mod" "rtsx_pci_sdmmc" ]; boot.initrd.availableKernelModules = [
boot.initrd.kernelModules = [ "dm-snapshot" "cryptd" ]; "xhci_pci"
boot.initrd.luks.devices."cryptroot".device = "/dev/disk/by-label/nixcrypt"; "nvme"
"usb_storage"
"sd_mod"
"rtsx_pci_sdmmc"
];
boot.initrd.kernelModules = [
"dm-snapshot"
"cryptd"
];
boot.initrd.luks.devices."cryptroot" = {
device = "/dev/disk/by-label/nixcrypt";
allowDiscards = true;
bypassWorkqueues = true;
};
boot.kernelModules = [ "kvm-intel" ]; boot.kernelModules = [ "kvm-intel" ];
boot.extraModulePackages = [ ]; boot.extraModulePackages = [ ];
fileSystems."/" = fileSystems."/" = {
{ device = "/dev/disk/by-label/nixroot"; device = "/dev/disk/by-label/nixroot";
fsType = "ext4"; fsType = "ext4";
}; };
fileSystems."/boot" = fileSystems."/boot" = {
{ device = "/dev/disk/by-label/nixboot"; device = "/dev/disk/by-label/nixboot";
fsType = "vfat"; fsType = "vfat";
options = [ "fmask=0022" "dmask=0022" ]; options = [
}; "fmask=0077"
"dmask=0077"
fileSystems."/home" =
{ device = "/dev/disk/by-label/nixhome";
fsType = "ext4";
};
swapDevices =
[ { device = "/dev/disk/by-label/nixswap"; }
]; ];
};
fileSystems."/home" = {
device = "/dev/disk/by-label/nixhome";
fsType = "ext4";
};
swapDevices = [
{ device = "/dev/disk/by-label/nixswap"; }
];
networking.useDHCP = lib.mkDefault true; networking.useDHCP = lib.mkDefault true;
nixpkgs.hostPlatform = lib.mkDefault "x86_64-linux"; nixpkgs.hostPlatform = lib.mkDefault "x86_64-linux";
+24
View File
@@ -0,0 +1,24 @@
# neon: laptop, the built-in display is auto-configured by niri
{ lib, ... }:
{
wayland.windowManager.niri.settings = {
input.touchpad = {
tap = { };
natural-scroll = { };
};
layout.gaps = lib.mkForce 10;
binds = {
"Print".screenshot = { };
"Ctrl+Print".screenshot-screen = { };
"Mod+Shift+P".power-off-monitors = { };
# finer brightness steps
"XF86MonBrightnessUp".spawn-sh = lib.mkForce "brightnessctl --class=backlight set +1%";
"XF86MonBrightnessDown".spawn-sh = lib.mkForce "brightnessctl --class=backlight set 1%-";
};
};
}
+1 -1
View File
@@ -1,4 +1,4 @@
{ config, pkgs, inputs, ... }: { pkgs, ... }:
{ {
# user fonts # user fonts
+2 -6
View File
@@ -1,17 +1,13 @@
{ config, pkgs, inputs, ... }:
{ {
programs.ghostty = { programs.ghostty = {
enable = true; enable = true;
settings = { settings = {
clipboard-paste-protection = false; clipboard-paste-protection = false;
clipboard-read = "allow"; clipboard-read = "allow";
font-family = "0xProto Nerd Font Mono";
font-size = 9;
gtk-titlebar = false; gtk-titlebar = false;
scrollback-limit = 10000; scrollback-limit = 100000;
shell-integration = "zsh"; shell-integration = "zsh";
theme = "noctalia"; # generated by noctalia-shell shell-integration-features = "ssh-env,ssh-terminfo";
window-decoration = "auto"; window-decoration = "auto";
window-padding-x = 10; window-padding-x = 10;
window-padding-y = 10; window-padding-y = 10;
+31 -5
View File
@@ -1,17 +1,43 @@
{ config, pkgs, inputs, ... }: # Commits are signed with each machine's ~/.ssh/id_ed25519 through the ssh
# agent. gitea verifies them against the account keys; allowed_signers gives
# the local git the same trust, so `git log --show-signature` resolves too.
{ {
config,
lib,
pkgs,
...
}:
let
email = "aaron@0x29a.ch";
signingKeys = [
"ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIHRhwzo1oxaT3fEySSmILKNnu9v30cfjx5G7FKpmfqeX aaron@argon"
"ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIGDkhvvTUcBSQdtXjX+Mw2Bp8HHhtiBm8aJi4ZxiBgZR aaron@neon"
"ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIB5BI+rirjPHZwqgBzO3xOi3m0+07zY0uEou7NSCFh0+ aaron@krypton"
];
in
{
xdg.configFile."git/allowed_signers".text = lib.concatMapStrings (
key: "${email} ${key}\n"
) signingKeys;
programs.git = { programs.git = {
enable = true; enable = true;
lfs.enable = true;
settings = { settings = {
push = { autoSetupRemote = true; }; push.autoSetupRemote = true;
user = { user = {
name = "aaron"; name = "aaron";
email = "aaron@0x29a.ch"; inherit email;
}; };
gpg.ssh.allowedSignersFile = "${config.xdg.configHome}/git/allowed_signers";
}; };
signing = { signing = {
key = "7A830180A05DAC59CDE43B0677D2F5DB48184456"; format = "ssh";
# the public key makes ssh-keygen sign through the agent
key = "${config.home.homeDirectory}/.ssh/id_ed25519.pub";
signer = "${pkgs.openssh}/bin/ssh-keygen";
signByDefault = true; signByDefault = true;
}; };
}; };
+279
View File
@@ -0,0 +1,279 @@
# Only renders ~/.config/niri/config.kdl; niri itself, its session and portals
# come from modules/nixos/niri.nix. Outputs and input devices that differ
# per machine live in hosts/<host>/niri.nix.
{
config,
lib,
osConfig,
...
}:
let
# Mod+1..9 focus a workspace, Mod+Ctrl+1..9 move the column there
workspaceBinds = lib.mergeAttrsList (
map (n: {
"Mod+${toString n}".focus-workspace = n;
"Mod+Ctrl+${toString n}".move-column-to-workspace = n;
}) (lib.range 1 9)
);
# shell command that also works on the lock screen
lockedSh = cmd: {
_props.allow-when-locked = true;
spawn-sh = cmd;
};
# niri has no stylix target, so the colors are picked here
colors = config.lib.stylix.colors.withHashtag;
in
{
wayland.windowManager.niri = {
# only on hosts that run niri
enable = osConfig.programs.niri.enable;
# validate the config against the installed niri
package = osConfig.programs.niri.package;
systemd.enable = false;
portalPackage = null;
xwaylandSatellitePackage = null; # installed system-wide
settings = {
input = {
keyboard = {
xkb.layout = "ch";
xkb.variant = "de_nodeadkeys";
numlock = { };
};
mouse = {
natural-scroll = { };
accel-speed = 0.5;
scroll-method = "no-scroll";
};
};
environment.GTK_IM_MODULE = "simple";
layout = {
gaps = 16;
center-focused-column = "never";
preset-column-widths._children = [
{ proportion = 0.33333; }
{ proportion = 0.5; }
{ proportion = 0.66667; }
{ fixed = 2560; }
];
default-column-width.proportion = 0.5;
focus-ring = {
on = { };
width = 2;
active-color = colors.base03;
inactive-color = colors.base00;
urgent-color = colors.base0B;
};
border.off = { };
shadow = {
on = { };
draw-behind-window = true;
softness = 30;
spread = 10;
offset._props = {
x = 0;
y = 5;
};
color = "#0007";
};
};
spawn-at-startup = "noctalia";
hotkey-overlay.skip-at-startup = { };
screenshot-path = "~/Pictures/Screenshots/Screenshot from %Y-%m-%d %H-%M-%S.png";
_children = [
# Open the Firefox picture-in-picture player as floating by default.
{
window-rule._children = [
{
match._props = {
app-id = "firefox$";
title = "^Picture-in-Picture$";
};
}
{ open-floating = true; }
];
}
# Block out the password manager from screen capture.
{
window-rule._children = [
{ match._props.app-id = "^org\\.keepassxc\\.KeePassXC$"; }
{ block-out-from = "screen-capture"; }
];
}
{
window-rule = {
geometry-corner-radius = 12;
clip-to-geometry = true;
};
}
];
binds = workspaceBinds // {
# programs: terminal, app launcher, screen locker
"Mod+Return" = {
_props.hotkey-overlay-title = "Open a Terminal";
spawn = "ghostty";
};
"Mod+D" = {
_props.hotkey-overlay-title = "Run an Application";
spawn-sh = "noctalia msg panel-toggle launcher";
};
"Super+Alt+L" = {
_props.hotkey-overlay-title = "Lock the Screen";
spawn-sh = "noctalia msg session lock";
};
# media keys (PipeWire / WirePlumber)
"XF86AudioRaiseVolume" = lockedSh "wpctl set-volume @DEFAULT_SINK@ 0.01+ -l 1.0";
"XF86AudioLowerVolume" = lockedSh "wpctl set-volume @DEFAULT_SINK@ 0.01-";
"XF86AudioMute" = lockedSh "wpctl set-mute @DEFAULT_SINK@ toggle";
"XF86AudioMicMute" = lockedSh "wpctl set-mute @DEFAULT_SOURCE@ toggle";
"XF86AudioPlay" = lockedSh "playerctl play-pause";
"XF86AudioStop" = lockedSh "playerctl stop";
"XF86AudioPrev" = lockedSh "playerctl previous";
"XF86AudioNext" = lockedSh "playerctl next";
"XF86MonBrightnessUp" = lockedSh "brightnessctl --class=backlight set +10%";
"XF86MonBrightnessDown" = lockedSh "brightnessctl --class=backlight set 10%-";
"Mod+O" = {
_props.repeat = false;
toggle-overview = { };
};
"Mod+Q" = {
_props.repeat = false;
close-window = { };
};
# focus / move columns and windows
"Mod+Left".focus-column-left = { };
"Mod+Down".focus-window-down = { };
"Mod+Up".focus-window-up = { };
"Mod+Right".focus-column-right = { };
"Mod+H".focus-column-left = { };
"Mod+J".focus-window-down = { };
"Mod+K".focus-window-up = { };
"Mod+L".focus-column-right = { };
"Mod+Shift+Left".move-column-left = { };
"Mod+Shift+Down".move-window-down = { };
"Mod+Shift+Up".move-window-up = { };
"Mod+Shift+Right".move-column-right = { };
"Mod+Shift+H".move-column-left = { };
"Mod+Shift+J".move-window-down = { };
"Mod+Shift+K".move-window-up = { };
"Mod+Shift+L".move-column-right = { };
"Mod+Home".focus-column-first = { };
"Mod+End".focus-column-last = { };
"Mod+Ctrl+Home".move-column-to-first = { };
"Mod+Ctrl+End".move-column-to-last = { };
# move columns between monitors
"Mod+Ctrl+Left".move-column-to-monitor-left = { };
"Mod+Ctrl+Down".move-column-to-monitor-down = { };
"Mod+Ctrl+Up".move-column-to-monitor-up = { };
"Mod+Ctrl+Right".move-column-to-monitor-right = { };
"Mod+Ctrl+H".move-column-to-monitor-left = { };
"Mod+Ctrl+J".move-column-to-monitor-down = { };
"Mod+Ctrl+K".move-column-to-monitor-up = { };
"Mod+Ctrl+L".move-column-to-monitor-right = { };
# workspaces
"Mod+Page_Down".focus-workspace-down = { };
"Mod+Page_Up".focus-workspace-up = { };
"Mod+U".focus-workspace-down = { };
"Mod+I".focus-workspace-up = { };
"Mod+Ctrl+Page_Down".move-column-to-workspace-down = { };
"Mod+Ctrl+Page_Up".move-column-to-workspace-up = { };
"Mod+Ctrl+U".move-column-to-workspace-down = { };
"Mod+Ctrl+I".move-column-to-workspace-up = { };
"Mod+Shift+Page_Down".move-workspace-down = { };
"Mod+Shift+Page_Up".move-workspace-up = { };
"Mod+Shift+U".move-workspace-down = { };
"Mod+Shift+I".move-workspace-up = { };
# mouse wheel
"Mod+WheelScrollDown" = {
_props.cooldown-ms = 150;
focus-workspace-down = { };
};
"Mod+WheelScrollUp" = {
_props.cooldown-ms = 150;
focus-workspace-up = { };
};
"Mod+Ctrl+WheelScrollDown" = {
_props.cooldown-ms = 150;
move-column-to-workspace-down = { };
};
"Mod+Ctrl+WheelScrollUp" = {
_props.cooldown-ms = 150;
move-column-to-workspace-up = { };
};
"Mod+WheelScrollRight".focus-column-right = { };
"Mod+WheelScrollLeft".focus-column-left = { };
"Mod+Ctrl+WheelScrollRight".move-column-right = { };
"Mod+Ctrl+WheelScrollLeft".move-column-left = { };
"Mod+Shift+WheelScrollDown".focus-column-right = { };
"Mod+Shift+WheelScrollUp".focus-column-left = { };
"Mod+Ctrl+Shift+WheelScrollDown".move-column-right = { };
"Mod+Ctrl+Shift+WheelScrollUp".move-column-left = { };
# columns
"Mod+BracketLeft".consume-or-expel-window-left = { };
"Mod+BracketRight".consume-or-expel-window-right = { };
"Mod+Comma".consume-window-into-column = { };
"Mod+Period".expel-window-from-column = { };
"Mod+R".switch-preset-column-width = { };
"Mod+Shift+R".switch-preset-window-height = { };
"Mod+Ctrl+R".reset-window-height = { };
"Mod+F".maximize-column = { };
"Mod+Shift+F".fullscreen-window = { };
"Mod+Ctrl+F".expand-column-to-available-width = { };
"Mod+C".center-column = { };
"Mod+Ctrl+C".center-visible-columns = { };
"Mod+Minus".set-column-width = "-10%";
"Mod+Equal".set-column-width = "+10%";
"Mod+Shift+Minus".set-window-height = "-10%";
"Mod+Shift+Equal".set-window-height = "+10%";
"Mod+Space".toggle-window-floating = { };
"Mod+Shift+Space".switch-focus-between-floating-and-tiling = { };
"Mod+W".toggle-column-tabbed-display = { };
# screenshots
"Mod+P".screenshot = { };
"Alt+Print".screenshot-window = { };
# escape hatch for apps that inhibit keyboard shortcuts
"Mod+Escape" = {
_props.allow-inhibiting = false;
toggle-keyboard-shortcuts-inhibit = { };
};
"Mod+Shift+E".quit = { };
};
};
};
}
+86 -6
View File
@@ -1,11 +1,17 @@
{ config, pkgs, inputs, ... }: { pkgs, inputs, ... }:
{ {
programs.nixvim = { programs.nixvim = {
globals.mapleader = " ";
enable = true; enable = true;
viAlias = false;
# same nixpkgs as the flake's `follows`, silences nixvim's pin warning
nixpkgs.source = inputs.nixpkgs;
# set aliases
viAlias = true;
vimAlias = true; vimAlias = true;
# default vim options
opts = { opts = {
number = true; number = true;
relativenumber = true; relativenumber = true;
@@ -14,13 +20,87 @@
expandtab = true; expandtab = true;
incsearch = true; incsearch = true;
}; };
# nvim mapleader for all command below
globals.mapleader = " ";
# set colorscheme to nord, stylix's base16 version is disabled in stylix.nix
colorschemes.nord.enable = true; colorschemes.nord.enable = true;
# nvim plugins
plugins.indent-blankline.enable = true;
plugins.lualine.enable = true; plugins.lualine.enable = true;
plugins.nix.enable = true; plugins.nix.enable = true;
plugins.nvim-tree.enable = true; plugins.nvim-tree.enable = true;
plugins.treesitter.enable = true;
plugins.telescope.enable = true;
plugins.web-devicons.enable = true; plugins.web-devicons.enable = true;
plugins.indent-blankline.enable = true; plugins.telescope = {
enable = true;
keymaps = {
"<leader>ff" = "find_files";
"<leader>fg" = "live_grep";
"<leader>fb" = "buffers";
"<leader>fh" = "help_tags";
};
};
plugins.lsp = {
enable = true;
servers.tinymist = {
enable = true;
settings = {
formatterMode = "typstyle";
exportPdf = "onSave";
semanticTokens = "disable"; # treesitter handles highlighting better
};
};
servers.pyright.enable = true;
servers.ruff.enable = true;
keymaps.lspBuf = {
"<leader>K" = "hover";
"<leader>gd" = "definition";
"<leader>gr" = "references";
"<leader>f" = "format";
"<leader>rn" = "rename";
"<leader>ca" = "code_action";
};
};
plugins.treesitter = {
enable = true;
settings.ensure_installed = [
"markdown"
"markdown_inline"
"typst"
];
};
plugins.typst-preview = {
enable = true;
settings = {
open_cmd = "firefox %s";
dependencies_bin = {
tinymist = "tinymist";
websocat = null;
};
};
};
plugins.typst-vim = {
enable = true;
settings.pdf_viewer = "zathura";
};
plugins.render-markdown = {
enable = true;
settings = {
# render in normal mode, raw source in insert
render_modes = [
"n"
"c"
"t"
];
pipe_table.preset = "round";
heading.width = "block";
file_types = [ "markdown" ];
completions.lsp.enabled = true;
};
};
}; };
# telescope live_grep
home.packages = [ pkgs.ripgrep ];
} }
+144
View File
@@ -0,0 +1,144 @@
{ pkgs, inputs, ... }:
{
# Noctalia v5 shell, managed via home-manager's built-in programs.noctalia module.
# The noctalia flake's homeModules.default is not imported: it redeclares the same
# options and its disabledModules path ("programs/noctalia.nix") doesn't match HM's.
# See https://docs.noctalia.dev/v5/getting-started/nixos/
programs.noctalia = {
enable = true;
# Use the package from the noctalia flake rather than nixpkgs.
package = inputs.noctalia.packages.${pkgs.stdenv.hostPlatform.system}.default;
# settings is rendered to ~/.config/noctalia/config.toml
settings = {
# theme / colors come from stylix, see stylix.nix
# general
shell = {
font_family = "0xProto Nerd Font";
avatar_path = "/home/aaron/syncthing/pictures/Logo-Aaron-Totenkopf-rund-schwarz.png";
telemetry_enabled = false;
clipboard_enabled = true;
password_style = "random";
launcher = {
categories = false;
providers.emoji.global = false;
};
panel = {
open_near_click_control_center = true;
open_near_click_session = true;
open_near_click_wallpaper = true;
transparency_mode = "glass";
};
screen_corners = {
enabled = true;
size = 10;
};
};
# location / weather
location.address = "Bern";
weather = {
enabled = true;
unit = "metric";
};
# wallpaper
wallpaper = {
enabled = true;
directory = "/home/aaron/Pictures/Wallpapers";
fill_mode = "crop";
default.path = "/home/aaron/Pictures/Wallpapers/nord-theme-tower.png";
};
# bar layout
bar = {
order = [ "default" ];
default = {
position = "top";
background_opacity = 0.93;
font_weight = 400;
margin_edge = 0;
margin_ends = 0;
radius = 0;
scale = 1.2;
widget_spacing = 20;
# no dark gradient on the seam between the bar and attached panels (e.g. control center)
contact_shadow = false;
start = [
"control-center"
"cpu"
"ram"
"temp"
"active_window"
];
center = [ "workspaces" ];
end = [
"tray"
"bluetooth"
"notifications"
"volume"
"network"
"clock"
];
};
};
# per-widget styling
widget = {
bluetooth.capsule = true;
control-center = {
capsule_radius = 8;
custom_image = "/home/aaron/syncthing/pictures/nix_flake_logo.png";
scale = 1.4;
};
cpu.capsule = true;
network = {
capsule = true;
show_label = false;
};
notifications.capsule = true;
ram.capsule = true;
temp.capsule = true;
volume = {
capsule = true;
show_label = false;
};
};
# idle behavior
idle = {
pre_action_fade_seconds = 5;
behavior_order = [
"screen-off"
"lock"
"lock-and-suspend"
];
behavior = {
"screen-off" = {
action = "screen_off";
enabled = true;
timeout = 300;
};
"lock" = {
action = "lock";
enabled = true;
timeout = 600;
};
"lock-and-suspend" = {
action = "lock_and_suspend";
enabled = true;
timeout = 1800;
};
};
};
};
};
}
+14 -2
View File
@@ -1,15 +1,27 @@
{ config, pkgs, inputs, ... }: { config, pkgs, ... }:
{ {
# user packages # user packages
home.packages = with pkgs; [ home.packages = with pkgs; [
devenv
discord discord
fastfetch fastfetch
keepassxc keepassxc
screenfetch signal-desktop
tea
teamspeak6-client
typst
zathura
]; ];
# services and other software # services and other software
services.syncthing.enable = true; services.syncthing.enable = true;
programs.home-manager.enable = true; programs.home-manager.enable = true;
# browsers
programs.chromium.enable = true;
programs.firefox = {
enable = true;
configPath = "${config.xdg.configHome}/mozilla/firefox";
};
} }
+34 -4
View File
@@ -1,4 +1,8 @@
{ config, pkgs, inputs, ... }: # zsh with oh-my-zsh: agnoster where glyphs render, gentoo on the console.
# Deep paths are shortened to `…/last/two` so the prompt stays on one line:
# `%(4~|…/%2~|%~)` shows the last two components from four levels down.
{ lib, ... }:
{ {
programs.zsh = { programs.zsh = {
@@ -7,12 +11,38 @@
syntaxHighlighting.enable = true; syntaxHighlighting.enable = true;
oh-my-zsh = { oh-my-zsh = {
enable = true; enable = true;
theme = "agnoster"; plugins = [
#plugins = [ "git" "ssh-agent" ]; "git"
"ssh-agent"
"gpg-agent"
];
# runs before oh-my-zsh is sourced
extraConfig = ''
# faster git status on large repositories
DISABLE_UNTRACKED_FILES_DIRTY=true
if [[ "$TERM" == "linux" || "$TERM" == "screen" ]]; then
ZSH_THEME="gentoo"
else
ZSH_THEME="agnoster"
fi
'';
}; };
# runs after oh-my-zsh, once the theme's prompt exists
initContent = lib.mkAfter ''
if [[ "$ZSH_THEME" == "agnoster" ]]; then
# agnoster renders prompt_dir on every prompt, so override it
prompt_dir() {
prompt_segment "$AGNOSTER_DIR_BG" "$AGNOSTER_DIR_FG" '%(4~|…/%2~|%~)'
}
else
# gentoo builds PROMPT once; ascii dots, the console font lacks …
PROMPT="''${PROMPT/\%~/%(4~|.../%2~|%~)}"
fi
'';
}; };
# set important env vars
home.sessionVariables = { home.sessionVariables = {
EDITOR = "vim"; EDITOR = "vim";
NH_FLAKE = "/home/aaron/git/nixconfig"; NH_FLAKE = "/home/aaron/git/nixconfig";
-30
View File
@@ -1,30 +0,0 @@
{ config, pkgs, inputs, ... }:
{
# set gtk theme
gtk = {
enable = true;
theme = {
name = "Adwaita-dark";
package = pkgs.gnome-themes-extra;
};
gtk3.extraConfig.gtk-application-prefer-dark-theme = 1;
gtk4.extraConfig.gtk-application-prefer-dark-theme = 1;
};
# set qt theme
qt = {
enable = true;
platformTheme.name = "qt6";
style = {
name = "adwaita-dark";
package = pkgs.adwaita-qt;
};
};
# ensure packages are installed
home.packages = with pkgs; [
gnome-themes-extra
adwaita-qt
];
}
+41
View File
@@ -0,0 +1,41 @@
# One Nord palette for everything stylix has a target for: gtk, qt,
# noctalia, ghostty. Niri has no target and reads the colors in niri.nix.
# Only the home-manager module is used, so boot, console and sddm are left alone.
{ pkgs, ... }:
{
stylix = {
enable = true;
base16Scheme = "${pkgs.base16-schemes}/share/themes/nord.yaml";
polarity = "dark";
fonts = {
monospace = {
name = "0xProto Nerd Font Mono";
package = pkgs.nerd-fonts._0xproto;
};
sizes.terminal = 12;
};
# its overlays (nixos-icons, gtksourceview) clash with useGlobalPkgs
overlays.enable = false;
targets = {
# profiles aren't managed by home-manager, declaring one here would
# take over the existing profile
firefox.enable = false;
# the bar keeps 0xProto instead of the sans-serif font
noctalia.fonts.enable = false;
# nord.nvim is calmer than the base16 palette, e.g. no line number
# background, see nixvim.nix
nixvim.enable = false;
# the hand-built status line in tmux.nix uses ANSI color names, which
# already follow the terminal palette
tmux.enable = false;
# rofi isn't used, and the target still sets the renamed
# programs.rofi.font, which warns on every evaluation
rofi.enable = false;
};
};
}
+64 -24
View File
@@ -1,55 +1,95 @@
{ config, pkgs, inputs, ... }: # Nord-style status line built natively, no theme plugin.
# The powerline separators (U+E0B0..U+E0B3) are written as escapes via
# fromJSON: literal private-use glyphs get stripped silently on copy/paste.
# Commas inside #{?...} separate arguments, hence the escaped `#,` below.
let
sep = builtins.fromJSON ''
{
"right": "",
"rightThin": "",
"left": "",
"leftThin": ""
}
'';
in
{ {
programs.tmux = { programs.tmux = {
enable = true; enable = true;
prefix = "C-a"; prefix = "C-a";
keyMode = "vi"; keyMode = "vi";
mouse = true; mouse = true;
terminal = "screen-256color"; terminal = "tmux-256color"; # truecolor, italics and undercurl in nvim
escapeTime = 10; # the 500ms default lags leaving insert mode in nvim
focusEvents = true; # nvim autoread
historyLimit = 50000;
baseIndex = 1; # window numbers match the number row
extraConfig = '' extraConfig = ''
# Status keys
set -g status-keys vi set -g status-keys vi
# outer terminal does 24-bit colour
set -sa terminal-features ",*:RGB"
# forward Shift+Enter and other extended keys as CSI-u (tmux >= 3.5)
set -s extended-keys always
set -s extended-keys-format csi-u
set -as terminal-features '*:extkeys'
# Status bar options # Status bar options
set -g status-interval 1 set -g status-interval 5
set -g status on
set -g status-justify left set -g status-justify left
# Clock mode # Clock mode
setw -g clock-mode-colour cyan setw -g clock-mode-colour cyan
# Colors # Colors
set -g status-bg black set -g status-bg black
set -g status-fg white set -g status-fg white
# Key bindings # Key bindings
# Reload configuration bind r source-file ~/.config/tmux/tmux.conf \; display-message "tmux.conf reloaded"
bind r source-file ~/.config/tmux/tmux.conf
# Panel split and selection # Panel split and selection, new panes/windows inherit the cwd
unbind % unbind %
unbind '"' unbind '"'
bind v split-window -v bind v split-window -v -c "#{pane_current_path}"
bind c split-window -h bind c split-window -h -c "#{pane_current_path}"
bind i new-window bind i new-window -c "#{pane_current_path}"
bind b previous-window bind -r b previous-window
bind n next-window bind -r n next-window
# Move around panes with hjkl # Move around panes with hjkl
bind h select-pane -L bind h select-pane -L
bind j select-pane -D bind j select-pane -D
bind k select-pane -U bind k select-pane -U
bind l select-pane -R bind l select-pane -R
# Resize panes # Resize panes
bind H resize-pane -L 5 bind -r H resize-pane -L 5
bind J resize-pane -D 5 bind -r J resize-pane -D 5
bind K resize-pane -U 5 bind -r K resize-pane -U 5
bind L resize-pane -R 5 bind -r L resize-pane -R 5
# copy to both the clipboard and primary selection
bind -T copy-mode-vi v send-keys -X begin-selection
bind -T copy-mode-vi C-v send-keys -X rectangle-toggle
bind -T copy-mode-vi y send-keys -X copy-pipe-and-cancel "wl-copy && wl-copy --primary"
bind -T copy-mode-vi Enter send-keys -X copy-pipe-and-cancel "wl-copy && wl-copy --primary"
bind -T copy-mode-vi MouseDragEnd1Pane send-keys -X copy-pipe-and-cancel "wl-copy && wl-copy --primary"
# Kill commands # Kill commands
bind q kill-window bind q confirm-before -p "kill window #W? (y/n)" kill-window
bind Q kill-session bind Q confirm-before -p "kill session #S? (y/n)" kill-session
# Bars # Bars
set -g status-left "#[fg=black,bg=blue,bold] #S#[fg=blue,bg=black,nobold,noitalics,nounderscore]" set -g status-left-length 24
set -g status-left "#[fg=black,bg=blue,bold] #S #[fg=blue,bg=black,nobold,noitalics,nounderscore]" set -g status-left "#[fg=black,bg=blue,bold] #{=20:session_name} #[fg=blue,bg=black,nobold,noitalics,nounderscore]${sep.right}"
set -g status-right "#{prefix_highlight}#[fg=brightblack,bg=black,nobold,noitalics,nounderscore]#[fg=white,bg=brightblack] %Y-%m-%d #[fg=white,bg=brightblack,nobold,noitalics,nounderscore]#[fg=white,bg=brightblack] %H:%M #[fg=cyan,bg=brightblack,nobold,noitalics,nounderscore]#[fg=black,bg=cyan,bold] #H " set -g status-right "#{?client_prefix,#[fg=black#,bg=yellow#,bold] ^A ,}#[fg=brightblack,bg=black,nobold,noitalics,nounderscore]${sep.left}#[fg=white,bg=brightblack] %Y-%m-%d #[fg=white,bg=brightblack,nobold,noitalics,nounderscore]${sep.leftThin}#[fg=white,bg=brightblack] %H:%M #[fg=cyan,bg=brightblack,nobold,noitalics,nounderscore]${sep.left}#[fg=black,bg=cyan,bold] #H "
# Windows # Windows
set -g window-status-format "#[fg=black,bg=brightblack,nobold,noitalics,nounderscore] #[fg=white,bg=brightblack]#I #[fg=white,bg=brightblack,nobold,noitalics,nounderscore] #[fg=white,bg=brightblack]#W #F #[fg=brightblack,bg=black,nobold,noitalics,nounderscore]" set -g window-status-format "#[fg=black,bg=brightblack,nobold,noitalics,nounderscore]${sep.right} #[fg=white,bg=brightblack]#I #[fg=white,bg=brightblack,nobold,noitalics,nounderscore]${sep.rightThin} #[fg=white,bg=brightblack]#W #F #[fg=brightblack,bg=black,nobold,noitalics,nounderscore]${sep.right}"
set -g window-status-current-format "#[fg=black,bg=cyan,nobold,noitalics,nounderscore] #[fg=black,bg=cyan]#I #[fg=black,bg=cyan,nobold,noitalics,nounderscore] #[fg=black,bg=cyan]#W #F #[fg=cyan,bg=black,nobold,noitalics,nounderscore]" set -g window-status-current-format "#[fg=black,bg=cyan,nobold,noitalics,nounderscore]${sep.right} #[fg=black,bg=cyan]#I #[fg=black,bg=cyan,nobold,noitalics,nounderscore]${sep.rightThin} #[fg=black,bg=cyan]#W #F #[fg=cyan,bg=black,nobold,noitalics,nounderscore]${sep.right}"
set -g window-status-separator "" set -g window-status-separator ""
''; '';
}; };
+10
View File
@@ -0,0 +1,10 @@
# Running an AppImage directly fails on NixOS: its runtime dlopens
# libfuse.so.2, which nix-ld doesn't cover. appimage-run unpacks the image
# into an FHS sandbox instead. Used for the BitBox02 wallet from bitbox.swiss.
{
programs.appimage = {
enable = true;
binfmt = true; # ./Something.AppImage runs without the appimage-run prefix
};
}
+72
View File
@@ -0,0 +1,72 @@
# Stellarium for target finding, Siril for stacking.
#
# Siril's python plugins run in a venv of foreign manylinux wheels (numpy,
# PyQt6, ...), dlopened by nixpkgs python, so nix-ld doesn't help. The wrapper
# puts their libs on LD_LIBRARY_PATH, a python on PATH to bootstrap the venv,
# and adwaita-qt6 on QT_PLUGIN_PATH so the dark style override resolves.
# The python comes from /etc/siril/bin, a stable symlink: a /nix/store path
# would leave the venv dangling after the next python bump and gc.
#
# StarNet++ has no package: unzip the v2 ORT cli build from starnetastro.com
# to ~/.local/share/siril/starnet/ and point Siril's preferences at ./starnet2.
# It runs through nix-ld and finds its own libs in the bundled ./lib.
{ lib, pkgs, ... }:
let
sirilWithPlugins = pkgs.symlinkJoin {
name = "siril-with-plugins";
paths = [ pkgs.siril ];
nativeBuildInputs = [ pkgs.makeWrapper ];
postBuild = ''
wrapProgram $out/bin/siril \
--prefix PATH : /etc/siril/bin \
--prefix QT_PLUGIN_PATH : ${pkgs.adwaita-qt6}/lib/qt-6/plugins \
--prefix LD_LIBRARY_PATH : ${
lib.makeLibraryPath (
with pkgs;
[
stdenv.cc.cc.lib # libstdc++, libgcc_s, libgomp (numpy)
zlib
zstd # PyQt6
libGL # PyQt6
# Qt needs these even on wayland
glib
fontconfig
freetype
dbus
libxkbcommon
# Qt platform plugins: wayland, and the xcb fallback
wayland
libxcb-cursor
libx11
libxcb
libxcb-util
libxcb-wm
libxcb-image
libxcb-keysyms
libxcb-render-util
]
)
}
'';
};
in
{
environment.systemPackages = [
pkgs.stellarium
sirilWithPlugins
];
# same python siril propagates, so sirilpy's abi matches
environment.etc."siril/bin/python3".source = "${pkgs.python3}/bin/python3";
# for StarNet++
programs.nix-ld = {
enable = true;
libraries = with pkgs; [
stdenv.cc.cc.lib
zlib
];
};
}
+2 -4
View File
@@ -1,9 +1,7 @@
{ config, lib, pkgs, ... }:
{ {
# enable sound through pipewire # enable sound through pipewire
services.pipewire = { services.pipewire = {
enable = true; enable = true;
pulse.enable = true; pulse.enable = true;
}; };
} }
+13 -2
View File
@@ -1,9 +1,11 @@
{ config, lib, pkgs, ... }: { pkgs, ... }:
{ {
# set bootloader to systemd # set bootloader to systemd
boot.loader = { boot.loader = {
systemd-boot.enable = true; systemd-boot.enable = true;
# no kernel command line editing at the boot menu (e.g. init=/bin/sh)
systemd-boot.editor = false;
efi.canTouchEfiVariables = true; efi.canTouchEfiVariables = true;
}; };
@@ -17,10 +19,19 @@
}; };
# kernel options # kernel options
boot.kernelParams = [ "quiet" "acpi.debug_level=0"]; boot.kernelParams = [
"quiet"
"acpi.debug_level=0"
];
boot.kernelPackages = pkgs.linuxPackages_latest; boot.kernelPackages = pkgs.linuxPackages_latest;
boot.consoleLogLevel = 2; boot.consoleLogLevel = 2;
# /tmp in RAM, nix builds go to /var/tmp instead (see settings.nix)
boot.tmp = {
useTmpfs = true;
tmpfsSize = "50%";
};
# Add boot-related packages # Add boot-related packages
environment.systemPackages = with pkgs; [ environment.systemPackages = with pkgs; [
efibootmgr efibootmgr
+5 -2
View File
@@ -1,5 +1,3 @@
{ config, lib, pkgs, ... }:
let let
caddyRootCA = '' caddyRootCA = ''
-----BEGIN CERTIFICATE----- -----BEGIN CERTIFICATE-----
@@ -19,4 +17,9 @@ in
security.pki.certificates = [ security.pki.certificates = [
caddyRootCA # self-signed pki ca for my home-lab caddyRootCA # self-signed pki ca for my home-lab
]; ];
# Temporary: eMudhra intermediates under this root have recoverable private
# keys (https://bugzilla.mozilla.org/show_bug.cgi?id=2083449). Remove once
# nixos-unstable ships cacert >= 3.131.1 (nixpkgs f903b88).
security.pki.caCertificateBlacklist = [ "emSign ECC Root CA - G3" ];
} }
+37
View File
@@ -0,0 +1,37 @@
# luks-encrypted data drives, unlocked after boot via /etc/crypttab with
# keyfiles from /etc/nixos/keys/<name>.key on the encrypted root.
# Not in boot.initrd.luks on purpose: keyfiles there end up in the initrd
# on the unencrypted /boot.
{ config, lib, ... }:
let
drives = config.local.dataDrives;
in
{
options.local.dataDrives = lib.mkOption {
type = lib.types.attrsOf lib.types.str;
default = { };
example = {
data1 = "dfae62cc-bad1-4879-bf9a-461bde833625";
};
description = "luks name -> luks partition uuid, mounted at /mnt/<name>";
};
config = lib.mkIf (drives != { }) {
environment.etc.crypttab.text = lib.concatStrings (
lib.mapAttrsToList (
name: uuid: "${name} /dev/disk/by-uuid/${uuid} /etc/nixos/keys/${name}.key luks,discard,nofail\n"
) drives
);
fileSystems = lib.mapAttrs' (
name: _:
lib.nameValuePair "/mnt/${name}" {
device = "/dev/mapper/${name}";
fsType = "ext4";
options = [ "nofail" ];
}
) drives;
};
}
+21
View File
@@ -0,0 +1,21 @@
{
# rootless only: no root daemon and no root-equivalent docker group
virtualisation.docker.rootless = {
enable = true;
setSocketVariable = true;
daemon.settings = {
dns = [
"1.1.1.1"
"8.8.8.8"
];
log-driver = "local";
registry-mirrors = [ "https://mirror.gcr.io" ];
};
};
# k3s/k3d in rootless docker needs the cpuset controller delegated to the user session
systemd.services."user@".serviceConfig.Delegate = "cpu cpuset io memory pids";
# let rootless docker publish ports 80/443 (e.g. k3d traefik ingress)
boot.kernel.sysctl."net.ipv4.ip_unprivileged_port_start" = 80;
}
+18 -7
View File
@@ -1,15 +1,26 @@
{ config, lib, pkgs, ... }: # A graphical pinentry never grabs the tty, so a passphrase prompt can't take
# over a terminal driven by a coding agent. The cache lasts a working day, and
# an unattended signature fails after two minutes instead of blocking forever.
{ config, pkgs, ... }:
{ {
# enable gnupg agent
programs.gnupg.agent = { programs.gnupg.agent = {
enable = true; enable = true;
enableSSHSupport = true; pinentryPackage = pkgs.pinentry-qt;
pinentryPackage = pkgs.pinentry-curses; settings = {
default-cache-ttl = 86400;
max-cache-ttl = 86400;
pinentry-timeout = 120;
};
}; };
environment.systemPackages = with pkgs; [ environment.systemPackages = [
gnupg pkgs.pinentry-curses # fallback for sessions without a display
pinentry-curses # prime the passphrase cache on demand, e.g. before an agent session
(pkgs.writeShellScriptBin "gpg-unlock" ''
echo | ${config.programs.gnupg.package}/bin/gpg --clearsign --output /dev/null
echo "gpg key unlocked"
'')
]; ];
} }
+14
View File
@@ -0,0 +1,14 @@
{ pkgs, ... }:
{
# greetd display manager with tuigreet
services.greetd = {
enable = true;
settings = {
default_session = {
command = "${pkgs.tuigreet}/bin/tuigreet --time --cmd niri-session";
user = "greeter";
};
};
};
}
+25
View File
@@ -0,0 +1,25 @@
# Secure Boot with lanzaboote. systemd-boot stays the bootloader, but lanzaboote
# installs it signed and writes signed boot entries instead of the nixos module.
# The keys are created once per host with `sudo sbctl create-keys` before the
# first rebuild, and enrolled into the firmware with `sbctl enroll-keys`.
{
inputs,
lib,
pkgs,
...
}:
{
imports = [ inputs.lanzaboote.nixosModules.lanzaboote ];
boot.loader.systemd-boot.enable = lib.mkForce false;
boot.lanzaboote = {
enable = true;
pkiBundle = "/var/lib/sbctl";
};
# key management and verification
environment.systemPackages = [ pkgs.sbctl ];
}
+10 -12
View File
@@ -1,21 +1,19 @@
{ config, lib, pkgs, ... }:
{ {
# set the time zone # set the time zone
time.timeZone = "Europe/Zurich"; time.timeZone = "Europe/Zurich";
# set internationalisation properties # keep system language in english, but use swiss locale for formatting
i18n.defaultLocale = "en_US.UTF-8"; i18n.defaultLocale = "en_US.UTF-8";
i18n.extraLocaleSettings = { i18n.extraLocaleSettings = {
LC_ADDRESS = "en_US.UTF-8"; LC_ADDRESS = "de_CH.UTF-8";
LC_IDENTIFICATION = "en_US.UTF-8"; LC_IDENTIFICATION = "de_CH.UTF-8";
LC_MEASUREMENT = "en_US.UTF-8"; LC_MEASUREMENT = "de_CH.UTF-8";
LC_MONETARY = "en_US.UTF-8"; LC_MONETARY = "de_CH.UTF-8";
LC_NAME = "en_US.UTF-8"; LC_NAME = "de_CH.UTF-8";
LC_NUMERIC = "en_US.UTF-8"; LC_NUMERIC = "de_CH.UTF-8";
LC_PAPER = "en_US.UTF-8"; LC_PAPER = "de_CH.UTF-8";
LC_TELEPHONE = "en_US.UTF-8"; LC_TELEPHONE = "de_CH.UTF-8";
LC_TIME = "en_US.UTF-8"; LC_TIME = "de_CH.UTF-8";
}; };
# set console font and keymap # set console font and keymap
+3 -11
View File
@@ -1,20 +1,12 @@
{ config, lib, pkgs, ... }: { pkgs, ... }:
{ {
# set hostnname
networking.hostName = "neon";
# user networkmanager
networking.networkmanager.enable = true; networking.networkmanager.enable = true;
# firewall default configs # wifi firmware and bluetooth
networking.firewall.allowedTCPPorts = [ ]; hardware.enableAllFirmware = true;
networking.firewall.allowedUDPPorts = [ ];
# enable bluetooth
hardware.bluetooth.enable = true; hardware.bluetooth.enable = true;
# Add network-related packages
environment.systemPackages = with pkgs; [ environment.systemPackages = with pkgs; [
wireguard-tools wireguard-tools
update-systemd-resolved update-systemd-resolved
+3 -7
View File
@@ -1,11 +1,7 @@
{ config, lib, pkgs, ... }: { pkgs, ... }:
{ {
# just enable and install niri # compositor and session; the config itself lives in home-manager
programs.niri.enable = true; programs.niri.enable = true;
environment.systemPackages = [ pkgs.xwayland-satellite ];
# Add compositor-related packages
environment.systemPackages = with pkgs; [
xwayland-satellite
];
} }
+22
View File
@@ -0,0 +1,22 @@
{
# greetd display manager with the graphical noctalia greeter, replaces greetd.nix.
# The nixpkgs module enables greetd, accountsservice (avatars) and polkit, and
# launches noctalia-greeter-session. Sessions (niri) are discovered from
# wayland-sessions, the last one picked is remembered.
# See https://docs.noctalia.dev/greeter/
services.displayManager.noctalia-greeter = {
enable = true;
# lets the shell's "Sync Now" / auto-sync copy wallpaper, palette and monitor
# layout to the greeter without an admin prompt (appearance only)
passwordlessSyncUsers = [ "aaron" ];
# rendered to /var/lib/noctalia-greeter/greeter.toml, wins over synced values
settings = {
user.default = "aaron";
# same layout as niri, otherwise the password is typed on a us keymap
keyboard.layout = "ch";
keyboard.variant = "de_nodeadkeys";
};
};
}
+6 -4
View File
@@ -1,12 +1,14 @@
{ config, lib, pkgs, inputs, ... }: { pkgs, ... }:
{ {
# install noctalia and helper packages # helpers for the noctalia shell (the shell itself comes from home-manager)
environment.systemPackages = with pkgs; [ environment.systemPackages = with pkgs; [
inputs.noctalia.packages.${pkgs.stdenv.hostPlatform.system}.default
adw-gtk3 adw-gtk3
adwaita-qt
adwaita-qt6 adwaita-qt6
brightnessctl brightnessctl
ddcutil
playerctl playerctl
wl-clipboard
wl-mirror
]; ];
} }
-2
View File
@@ -1,5 +1,3 @@
{ config, lib, pkgs, ... }:
{ {
# enable the openssh daemon # enable the openssh daemon
services.openssh = { services.openssh = {
+5 -17
View File
@@ -1,42 +1,33 @@
{ config, lib, pkgs, ... }: { pkgs, ... }:
{ {
# system packges # baseline tools for every host
environment.systemPackages = with pkgs; [ environment.systemPackages = with pkgs; [
alacritty
btop btop
cifs-utils
claude-code
cowsay cowsay
dnsutils dnsutils
ethtool ethtool
file file
fwupd
fwupd-efi
ghostty
git git
imagemagick imagemagick
imv imv
iperf3 iperf3
jq jq
kdePackages.qtmultimedia
kitty
ldns ldns
lm_sensors lm_sensors
lsof lsof
ltrace
mtr mtr
neovim nfs-utils
nh nh
nix-output-monitor nix-output-monitor
nmap nmap
nvd
p7zip p7zip
pciutils pciutils
sddm-astronaut
socat socat
sof-firmware
strace strace
sysstat sysstat
terminus_font
tree tree
unzip unzip
usbutils usbutils
@@ -47,7 +38,4 @@
zip zip
zstd zstd
]; ];
# browser
programs.firefox.enable = true;
} }
+8
View File
@@ -0,0 +1,8 @@
{ pkgs, ... }:
{
# wireguard replies may leave on another interface, so strict rpfilter drops them
networking.firewall.checkReversePath = "loose";
environment.systemPackages = [ pkgs.proton-vpn ];
}
+5 -10
View File
@@ -1,20 +1,15 @@
{ config, lib, pkgs, ... }: { pkgs, ... }:
{ {
# enable sddm and use astronaut theme
services.displayManager.sddm = { services.displayManager.sddm = {
enable = true; enable = true;
wayland.enable = true; wayland.enable = true;
autoNumlock = true; autoNumlock = true;
enableHidpi = true; enableHidpi = true;
theme = "sddm-astronaut-theme"; theme = "sddm-astronaut-theme";
settings = { extraPackages = [ pkgs.sddm-astronaut ]; # theme's qml dependencies
Theme = {
Current = "sddm-astronaut-theme";
};
};
extraPackages = with pkgs; [
sddm-astronaut
];
}; };
# sddm looks for themes in the system path
environment.systemPackages = [ pkgs.sddm-astronaut ];
} }
+5 -3
View File
@@ -1,11 +1,13 @@
{ config, lib, pkgs, ... }:
{ {
# list of enabled services on the system # list of enabled services on the system
services = { services = {
tuned.enable = true; tuned.enable = true;
upower.enable = true; upower.enable = true;
fwupd.enable = true; fwupd.enable = true;
tailscale.enable = true; tailscale = {
enable = true;
# inbound 41641/udp so peers can connect directly instead of via DERP
openFirewall = true;
};
}; };
} }
+20 -26
View File
@@ -1,30 +1,25 @@
{ config, lib, pkgs, ... }:
{ {
nix = { nix = {
# nix settings
settings = { settings = {
# enable flakes and nix-command experimental-features = [
experimental-features = [ "nix-command" "flakes" ]; "nix-command"
# auto-optimize my nix-store "flakes"
auto-optimise-store = true;
# use all cores
max-jobs = "auto";
# use all available cores per job
cores = 0;
# add trusted substituters (binary caches)
substituters = [
"https://cache.nixos.org"
"https://nix-community.cachix.org"
]; ];
# add keys auto-optimise-store = true;
trusted-public-keys = [ # parallel builds, each using all cores
"cache.nixos.org-1:6NCHdD59X431o0gWypbMrAURkbJ16ZPMQFGspcDShjY=" max-jobs = "auto";
cores = 0;
# cache.nixos.org is the default, these come on top
extra-substituters = [ "https://nix-community.cachix.org" ];
extra-trusted-public-keys = [
"nix-community.cachix.org-1:mB9FSh9qf2dCimDSUo8Zy7bkq5CX+/rkCWyvRCYg3Fs=" "nix-community.cachix.org-1:mB9FSh9qf2dCimDSUo8Zy7bkq5CX+/rkCWyvRCYg3Fs="
]; ];
trusted-users = [
"root"
"@wheel"
];
}; };
# enable automatic garbage collection
gc = { gc = {
automatic = true; automatic = true;
dates = "weekly"; dates = "weekly";
@@ -32,13 +27,12 @@
}; };
}; };
# build on disk, big builds would fill the /tmp tmpfs
systemd.services.nix-daemon.environment.TMPDIR = "/var/tmp";
# steam, protonvpn, discord, etc.
nixpkgs.config.allowUnfree = true;
# links /libexec from derivations to /run/current-system/sw # links /libexec from derivations to /run/current-system/sw
environment.pathsToLink = [ "/libexec" ]; environment.pathsToLink = [ "/libexec" ];
# set the default editor to vim
environment.variables.EDITOR = "vim";
# enable home-manager globally
home-manager.useGlobalPkgs = true;
home-manager.useUserPackages = true;
home-manager.backupFileExtension = "backup";
} }
+4 -14
View File
@@ -1,23 +1,13 @@
{ config, lib, pkgs, ... }: { pkgs, ... }:
{ {
# allow unfree to install steam
nixpkgs.config.allowUnfree = true;
# enable steam and open firewall
programs.steam = { programs.steam = {
enable = true; enable = true;
# fix black screen when running under xwayland-satellite
package = pkgs.steam.override { extraArgs = "-system-composer"; };
remotePlay.openFirewall = true; remotePlay.openFirewall = true;
dedicatedServer.openFirewall = true; dedicatedServer.openFirewall = true;
localNetworkGameTransfers.openFirewall = true; localNetworkGameTransfers.openFirewall = true;
# add proton-glorious-eggroll extraCompatPackages = [ pkgs.proton-ge-bin ];
extraCompatPackages = with pkgs; [
proton-ge-bin
];
};
# fix black screen in steam when using xwayland-satellite
programs.steam.package = pkgs.steam.override {
extraArgs = "-system-composer";
}; };
} }
+9
View File
@@ -0,0 +1,9 @@
{ pkgs, ... }:
{
programs.thunar.enable = true;
# thumbnails: tumbler service plus the path it loads extensions from
environment.systemPackages = [ pkgs.tumbler ];
environment.pathsToLink = [ "share/thumbnailers" ];
}
+8
View File
@@ -0,0 +1,8 @@
# Unlock cryptroot with the TPM and a PIN, the passphrase stays as fallback.
# The TPM only releases the key while PCR 7 (the Secure Boot state) matches,
# so this needs lanzaboote.nix. Enrolled once per host with
# `systemd-cryptenroll`, see INSTALLATION.md.
{
boot.initrd.luks.devices."cryptroot".crypttabExtraOpts = [ "tpm2-device=auto" ];
}
+8 -15
View File
@@ -1,23 +1,16 @@
{ config, lib, pkgs, ... }: { pkgs, ... }:
{ {
# create users
users.users.aaron = { users.users.aaron = {
isNormalUser = true; isNormalUser = true;
group = "users"; extraGroups = [
extraGroups = [ "wheel" "networkmanager" ]; "wheel"
"networkmanager"
"dialout"
];
shell = pkgs.zsh; shell = pkgs.zsh;
}; };
# add default zsh config # login shell; plugins and prompt are configured in home-manager
programs.zsh = { programs.zsh.enable = true;
enable = true;
enableCompletion = true;
autosuggestions.enable = true;
ohMyZsh = {
enable = true;
plugins = [ "git" "sudo" ];
theme = "gentoo";
};
};
} }
+21
View File
@@ -0,0 +1,21 @@
# Vial keyboards (lily58 pro r2g) expose a raw HID interface that vial.rocks
# drives over WebHID; its /dev/hidraw* node is root-only by default.
# The rule ships as 60-vial.rules because uaccess is only applied by
# 73-seat-late.rules, and services.udev.extraRules lands at 99, too late.
{ pkgs, ... }:
{
services.udev.packages = [
(pkgs.writeTextFile {
name = "vial-udev-rules";
destination = "/lib/udev/rules.d/60-vial.rules";
# the magic serial matches any vial board; uaccess grants the seat owner
text = ''
KERNEL=="hidraw*", SUBSYSTEM=="hidraw", ATTRS{serial}=="*vial:f64c2b3c*", TAG+="uaccess"
'';
})
];
environment.systemPackages = [ pkgs.vial ];
}
+8
View File
@@ -0,0 +1,8 @@
# statix configuration (run via `lint` in the devenv)
# Flat assignments like `boot.loader = ...; boot.plymouth = ...;` are the
# preferred style in this repo, so don't ask for them to be merged.
disabled = [ "repeated_keys" ]
# Generated by nixos-generate-config, not maintained by hand.
ignore = [ "hosts/*/hardware-configuration.nix" ]
+3 -3
View File
@@ -1,14 +1,14 @@
{ config, pkgs, ... }:
{ {
imports = [ imports = [
../../modules/home-manager/fonts.nix ../../modules/home-manager/fonts.nix
../../modules/home-manager/git.nix ../../modules/home-manager/git.nix
../../modules/home-manager/ghostty.nix ../../modules/home-manager/ghostty.nix
../../modules/home-manager/nixvim.nix ../../modules/home-manager/nixvim.nix
../../modules/home-manager/niri.nix
../../modules/home-manager/noctalia.nix
../../modules/home-manager/programs.nix ../../modules/home-manager/programs.nix
../../modules/home-manager/shell.nix ../../modules/home-manager/shell.nix
../../modules/home-manager/styling.nix ../../modules/home-manager/stylix.nix
../../modules/home-manager/tmux.nix ../../modules/home-manager/tmux.nix
]; ];