KISS NixOS configuration based on Flakes & flake-parts (supports macOS too)
Nix
589
2,468 commits
updated Oct 16, 2026
This is my Nix / NixOS configuration for all of my systems. See nixos-unified—specifically nixos-unified-template—if you wish to create your own configuration from scratch.
If you are using this repository as a starting template for your own configuration, perform these initial steps:
config.nix in the repository root to set your primary user information (username, fullname, email, sshKey).secrets/secrets.nix with your own, or delete the file if you do not use agenix.configurations/ that you do not need, and create/rename files to match your hostnames.After preparing your template, to install on a new machine running:
[!TIP] For a general tutorial, see https://nixos.asia/en/nixos-install-flake
root@<ip>ssh srid@<ip>; profit!nix run. That's it. Re-open your terminal.nix run.1 That's it. Re-open your terminal.Start from flake.nix (see Flakes). flake-parts is used as the module system.
[!TIP] See
flake-module.nixfor autowiring of flake outputs based on this directory structure.
| Path | Corresponding flake output |
|---|---|
./configurations/{nixos,darwin,home}/foo.nix | {nixos,darwin,home}Configurations.foo |
./mdules/{nixos,darwin,home,flake-parts}/foo.nix | {nixos,darwin,home,flake}Modules.foo |
./secrets | N/A (agenix data) |
nix flake update
# nix run .#update
sudo nix-env -p /nix/var/nix/profiles/system --delete-generations +2
sudo nixos-rebuild boot
just lint in Nix devShell.nix run nixpkgs#omnix cihttps://github.com/srid/nixos-config/discussions
You might have to rm -rf /etc/nix/nix.conf, so our flake.nix can do its thing. ↩
(top 24 of 29)
1,114 followers · starred Aug 2022
251 followers · starred Dec 2023
456 followers · starred Dec 2022
283 followers · starred Jun 2022
KISS NixOS configuration based on Flakes & flake-parts (supports macOS too)
Nix
589
2,468 commits
updated Oct 16, 2026
This is my Nix / NixOS configuration for all of my systems. See nixos-unified—specifically nixos-unified-template—if you wish to create your own configuration from scratch.
If you are using this repository as a starting template for your own configuration, perform these initial steps:
config.nix in the repository root to set your primary user information (username, fullname, email, sshKey).secrets/secrets.nix with your own, or delete the file if you do not use agenix.configurations/ that you do not need, and create/rename files to match your hostnames.After preparing your template, to install on a new machine running:
[!TIP] For a general tutorial, see https://nixos.asia/en/nixos-install-flake
root@<ip>ssh srid@<ip>; profit!nix run. That's it. Re-open your terminal.nix run.1 That's it. Re-open your terminal.Start from flake.nix (see Flakes). flake-parts is used as the module system.
[!TIP] See
flake-module.nixfor autowiring of flake outputs based on this directory structure.
| Path | Corresponding flake output |
|---|---|
./configurations/{nixos,darwin,home}/foo.nix | {nixos,darwin,home}Configurations.foo |
./mdules/{nixos,darwin,home,flake-parts}/foo.nix | {nixos,darwin,home,flake}Modules.foo |
./secrets | N/A (agenix data) |
nix flake update
# nix run .#update
sudo nix-env -p /nix/var/nix/profiles/system --delete-generations +2
sudo nixos-rebuild boot
just lint in Nix devShell.nix run nixpkgs#omnix cihttps://github.com/srid/nixos-config/discussions
You might have to rm -rf /etc/nix/nix.conf, so our flake.nix can do its thing. ↩
(top 24 of 29)
1,114 followers · starred Aug 2022
251 followers · starred Dec 2023
456 followers · starred Dec 2022
283 followers · starred Jun 2022