安装前必须通过 just inject-tokens 注入两把 SOPS age 密钥,缺一即中止;仓库克隆路径需为 ~/Zero/nix-config,脚本按此路径工作;NixOS 与 Home Manager 需分别用 just host 和 just home 应用,不会一次生效。

nix-config
wimpysworldBlueOak-1.0.0活跃维护一套用 Nix Flake 统一管理 NixOS、nix-darwin 和 Home Manager 的完整配置,可跨 Linux 与 macOS 复现开发环境。
Wimpy's NixOS, nix-darwin & Home Manager Configurations ❄️
gh repo clone wimpysworld/nix-config "$HOME/Zero/nix-config"
cd "$HOME/Zero/nix-config"
just switchREADME 未说明统一硬件要求;作者自用设备覆盖 AMD 核显笔记本与桌面、Apple M2 Pro、Intel + NVIDIA T1000/RTX 3090 等,可作为参考。
用单个 Nix Flake 统一管理 NixOS、macOS 与 Home Manager 配置,靠模块自门控免去逐主机维护导入列表
一套用 Nix Flake 统一管理 NixOS、nix-darwin 和 Home Manager 的完整配置,可跨 Linux 与 macOS 复现开发环境。
核心能力
- 所有模块被每台主机统一导入,模块用 lib.mkIf 按主机元数据自门控
- 主机属性登记在 registry-systems.toml,自动派生 is.workstation、hasNvidia 等布尔量
- 新增功能只需放入自门控模块目录,无需改导入列表
- 新增主机只需加注册表条目和硬件配置,桌面与驱动自动匹配
- 提供 justfile 与 FlakeHub Cache 预构建闭包加速部署
容易踩的坑
- v26.5.20261108最新正式版2026-11-11 · 2026-11-11 00:07 UTC
What's Changed
- feat(moltis): add Matrix reaction companion and moderator wake-up by @flexiondotorg in https://github.com/wimpysworld/nix-config/pull/1156
- feat(agentic): request agent reviews on personal pull requests by @flexiondotorg in https://github.com/wimpysworld/nix-config/pull/1157
- fix(moltis): refine Matrix companion binding, notices, and tool phases by @sith-zannah in https://github.com/wimpysworld/nix-config/pull/1158
- feat(moltis): add static bee reaction, activity notice icons, and terminal notices by @sith-zannah in https://github.com/wimpysworld/nix-config/pull/1159
- fix(fence): start fenced wrappers from an empty working directory by @flexiondotorg in https://github.com/wimpysworld/nix-config/pull/1160
- feat(moltis): add GitHub companion for notifications, mentions, and alerts by @flexiondotorg in https://github.com/wimpysworld/nix-config/pull/1161
- feat(silo): package silo-server and deploy on revan by @flexiondotorg in https://github.com/wimpysworld/nix-config/pull/1162
- fix(moltis): separate turn termination from task success and dismiss skipped PRs by @sith-zannah in https://github.com/wimpysworld/nix-config/pull/1163
- fix(moltis): apply X-RateLimit-Reset backoff only when rate-limited by @sith-skrye in https://github.com/wimpysworld/nix-config/pull/1165
- feat(moltis): refine Matrix companion invitations, MM:SS ticker, and audio handling by @sith-zannah in https://github.com/wimpysworld/nix-config/pull/1164
- fix(moltis): recover interrupted read-only GitHub companion turns by @sith-zannah in https://github.com/wimpysworld/nix-config/pull/1166
- chore(wolfictl): update to 0.39.30 by @flexiondotorg in https://github.com/wimpysworld/nix-config/pull/1167
- chore(openusage): update to 0.26.3 by @flexiondotorg in https://github.com/wimpysworld/nix-config/pull/1168
- chore(chainctl): update to 0.2.394 by @flexiondotorg in https://github.com/wimpysworld/nix-config/pull/1170
- chore(manuscript): update to 1.6.2 by @flexiondotorg in https://github.com/wimpysworld/nix-config/pull/1171
- fix(moltis): exempt trusted instruction actors from coercion rules and deduplicate alerts by @sith-skrye in https://github.com/wimpysworld/nix-config/pull/1174
- docs(moltis): relax policy gates in TOOLS.md and GUIDELINES.md by @sith-zannah in https://github.com/wimpysworld/nix-config/pull/1175
- feat(moltis): share council roles and let peers speak before moderator by @sith-traya in https://github.com/wimpysworld/nix-config/pull/1176
- chore(silo-server): update to 0-unstable-2026-11-03 by @flexiondotorg in https://github.com/wimpysworld/nix-config/pull/1172
- chore(weave): update to 0.5.0 by @flexiondotorg in https://github.com/wimpysworld/nix-config/pull/1173
- fix(moltis): simplify github-companion state and 60s PR polling by @flexiondotorg in https://github.com/wimpysworld/nix-config/pull/1177
- feat(homepage): add homepage dashboard on revan and expand gatus checks by @flexiondotorg in https://github.com/wimpysworld/nix-config/pull/1178
- chore(handy): update to v0.10.0 by @flexiondotorg in https://github.com/wimpysworld/nix-config/pull/1169
- fix(moltis): simplify matrix-companion state, m.audio gating, and floor routing by @flexiondotorg in https://github.com/wimpysworld/nix-config/pull/1179
- fix(moltis): persist retry deadlines for failed github-companion sweeps by @flexiondotorg in https://github.com/wimpysworld/nix-config/pull/1181
- feat(moltis): set github-companion to 2m poll with 5-30s jitter and 2h sweep by @flexiondotorg in https://github.com/wimpysworld/nix-config/pull/1182
- fix(moltis): anchor matrix /new cutoff, parse pill mentions, and slim assessments by @flexiondotorg in https://github.com/wimpysworld/nix-config/pull/1183
- fix(moltis): include Dependabot PRs in 2-hour sweep and GraphQL trust checks by @sith-skrye in https://github.com/wimpysworld/nix-config/pull/1184
- fix(moltis): add matrix-companion to PATH, drop fenced systemctl, and strip code-span mentions by @flexiondotorg in https://git
- v26.5.202611012026-11-02 · 2026-11-02 15:01 UTC
查看更新说明
What's Changed
- feat(cloudflare): add SOPS-backed Wrangler and MCP authentication by @flexiondotorg in https://github.com/wimpysworld/nix-config/pull/1131
- feat(github): paginate pull request files in gh-bot-merge above 100 files by @sith-zannah in https://github.com/wimpysworld/nix-config/pull/1129
- fix(moltis): seed HEARTBEAT.md before daemon startup and expand PR triage by @sith-skrye in https://github.com/wimpysworld/nix-config/pull/1132
- feat(moltis): harmonise agent tooling across Linux and macOS by @flexiondotorg in https://github.com/wimpysworld/nix-config/pull/1133
- fix(moltis): repair MCP credentials and runtime tool guidance by @flexiondotorg in https://github.com/wimpysworld/nix-config/pull/1134
- feat(matrix): add private agent chat with automatic provisioning by @flexiondotorg in https://github.com/wimpysworld/nix-config/pull/1135
- feat(matrix): add Moltis council hook, avatars, DMs, and status page by @flexiondotorg in https://github.com/wimpysworld/nix-config/pull/1136
- feat(moltis): route heartbeat turns to mainModel by @sith-skrye in https://github.com/wimpysworld/nix-config/pull/1137
- style(matrix): theme the status landing page with a Sith palette by @flexiondotorg in https://github.com/wimpysworld/nix-config/pull/1138
- feat(moltis): serve qwen3-embedding-0.6b locally on all hosts by @sith-skrye in https://github.com/wimpysworld/nix-config/pull/1139
- feat(agentic): add gh-review-inline and thread-first code review workflow by @sith-zannah in https://github.com/wimpysworld/nix-config/pull/1141
- fix(llama-server): replace removed mmap flags with --load-mode none by @sith-skrye in https://github.com/wimpysworld/nix-config/pull/1142
- feat(moltis): enable Matrix tools with private_instance fork build by @flexiondotorg in https://github.com/wimpysworld/nix-config/pull/1144
- fix(moltis): await llama-swap before memory sync and trigger restart on embedding changes by @sith-zannah in https://github.com/wimpysworld/nix-config/pull/1143
- fix(network): ignore default IPv6 route on skrye by @flexiondotorg in https://github.com/wimpysworld/nix-config/pull/1146
- feat(moltis): give each agent a separate Linear app identity by @flexiondotorg in https://github.com/wimpysworld/nix-config/pull/1145
- fix(mcp): isolate mcp-proxy from devShell Python environment variables by @flexiondotorg in https://github.com/wimpysworld/nix-config/pull/1148
- fix(moltis): replace compgen in embedding readiness check by @flexiondotorg in https://github.com/wimpysworld/nix-config/pull/1149
- fix(moltis): strip SOCKS fallback proxy vars in moltis-linear-server by @sith-zannah in https://github.com/wimpysworld/nix-config/pull/1150
- fix(matrix): provision agent direct messages without group room metadata by @flexiondotorg in https://github.com/wimpysworld/nix-config/pull/1151
- feat: provision organisation repositories with clone and fetch by @sith-traya in https://github.com/wimpysworld/nix-config/pull/1153
- feat(scripts): replace repo-provision with gh-clone-orgs by @flexiondotorg in https://github.com/wimpysworld/nix-config/pull/1154
- fix(moltis): preserve queued channel tools and recover zero-token streams by @sith-zannah in https://github.com/wimpysworld/nix-config/pull/1155
Full Changelog: https://github.com/wimpysworld/nix-config/compare/v26.5.20261029...v26.5.20261101
- v26.5.202610292026-10-30 · 2026-10-30 17:27 UTC
查看更新说明
What's Changed
- refactor(agentic): share Pi extension pins and subagent config with export-agentic-dots by @sith-zannah in https://github.com/wimpysworld/nix-config/pull/1126
- fix(moltis): ignore prepended exec-event lines in heartbeat by @sith-skrye in https://github.com/wimpysworld/nix-config/pull/1128
- feat(cloudflare): add development tools and agent skills by @flexiondotorg in https://github.com/wimpysworld/nix-config/pull/1127
- fix: eliminate moltis evaluation IFD and switch-home failures by @flexiondotorg in https://github.com/wimpysworld/nix-config/pull/1130
New Contributors
- @sith-skrye made their first contribution in https://github.com/wimpysworld/nix-config/pull/1128
Full Changelog: https://github.com/wimpysworld/nix-config/compare/v26.5.20261026...v26.5.20261029
- v26.5.202610262026-10-29 · 2026-10-29 23:51 UTC
查看更新说明
What's Changed
- chore(chainctl): update to 0.2.389 by @flexiondotorg in https://github.com/wimpysworld/nix-config/pull/1120
- chore(claude-themes-catppuccin): update to 0.2.2 by @flexiondotorg in https://github.com/wimpysworld/nix-config/pull/1122
- chore(chainctl): update to 0.2.391 by @flexiondotorg in https://github.com/wimpysworld/nix-config/pull/1123
- feat(github): allow peer agents to co-merge pull requests by @sith-zannah in https://github.com/wimpysworld/nix-config/pull/1124
- feat(moltis): add reciprocal PR review workflow and notification helper by @flexiondotorg in https://github.com/wimpysworld/nix-config/pull/1125
New Contributors
- @sith-zannah made their first contribution in https://github.com/wimpysworld/nix-config/pull/1124
Full Changelog: https://github.com/wimpysworld/nix-config/compare/v26.5.20261015...v26.5.20261026
- v26.5.202610152026-10-21 · 2026-10-21 16:21 UTC
查看更新说明
What's Changed
- chore(chainctl): update to 0.2.382 by @flexiondotorg in https://github.com/wimpysworld/nix-config/pull/1096
- chore(defold): update to 1.14.0-zy2LyzzI by @flexiondotorg in https://github.com/wimpysworld/nix-config/pull/1097
- chore(hushmic): update to 0.10.3-b2af2236e162 by @flexiondotorg in https://github.com/wimpysworld/nix-config/pull/1098
- chore(yam): update to 0.2.69 by @flexiondotorg in https://github.com/wimpysworld/nix-config/pull/1099
- chore(slk): update to 0.26.2 by @flexiondotorg in https://github.com/wimpysworld/nix-config/pull/1100
- chore(weave): update to 0.3.0 by @flexiondotorg in https://github.com/wimpysworld/nix-config/pull/1101
- chore(ai-usagebar): update to 1.36.0 by @flexiondotorg in https://github.com/wimpysworld/nix-config/pull/1102
- chore(chainctl): update to 0.2.383 by @flexiondotorg in https://github.com/wimpysworld/nix-config/pull/1103
- chore(herdr-telegram-agents): update to 0.17.2 by @flexiondotorg in https://github.com/wimpysworld/nix-config/pull/1104
- chore(ai-usagebar): update to 1.38.0 by @flexiondotorg in https://github.com/wimpysworld/nix-config/pull/1105
- chore(wolfictl): update to 0.39.29 by @flexiondotorg in https://github.com/wimpysworld/nix-config/pull/1106
- chore(chainctl): update to 0.2.388 by @flexiondotorg in https://github.com/wimpysworld/nix-config/pull/1107
- chore(defold): update to 1.14.0-n9udIv5t by @flexiondotorg in https://github.com/wimpysworld/nix-config/pull/1108
- chore(concord): update to v2.6.3 by @flexiondotorg in https://github.com/wimpysworld/nix-config/pull/1109
- chore(claude-themes-catppuccin): update to 0.2.1 by @flexiondotorg in https://github.com/wimpysworld/nix-config/pull/1110
- chore(slk): update to 0.27.0 by @flexiondotorg in https://github.com/wimpysworld/nix-config/pull/1111
- chore(manuscript): update to 1.6.1 by @flexiondotorg in https://github.com/wimpysworld/nix-config/pull/1112
- chore(weave): update to 0.4.0 by @flexiondotorg in https://github.com/wimpysworld/nix-config/pull/1113
- chore(ai-usagebar): update to 1.41.0 by @flexiondotorg in https://github.com/wimpysworld/nix-config/pull/1114
- build(deps): bump rust-overlay from
404b7a5toa110337by @dependabot[bot] in https://github.com/wimpysworld/nix-config/pull/1115 - build(deps): bump flake-utils from
11707dctob7a79d3by @dependabot[bot] in https://github.com/wimpysworld/nix-config/pull/1116 - build(deps): bump home-manager from
db7d5e2toab3823bby @dependabot[bot] in https://github.com/wimpysworld/nix-config/pull/1117 - build(deps): bump nixpkgs from
6fcc160to26f4107by @dependabot[bot] in https://github.com/wimpysworld/nix-config/pull/1118 - build(deps): bump direnv-instant from
0e80153toe78b975by @dependabot[bot] in https://github.com/wimpysworld/nix-config/pull/1119
Full Changelog: https://github.com/wimpysworld/nix-config/compare/v26.5.20261010...v26.5.20261015
用户点评
登录用户的真实使用记录,可按版本和硬件筛选还没有人点评。第一个说出真实体验的人最有价值。
Wimpy's NixOS, nix-darwin & Home Manager Configurations
Made with 💝 for &
A Nix Flake managing NixOS, macOS, and Home Manager across all my systems from a single repo. The interesting bit is the architecture: every module is imported everywhere, and each module decides for itself whether to activate based on host metadata. No import lists to maintain, no per-host module selections - just drop a self-gating module in a directory and every relevant host picks it up automatically. If you're starting your own Nix configuration, I'd recommend https://github.com/Misterio77/nix-starter-configs as a foundation. 👍️ This repo is the deep end.
These computers are managed by this Nix flake ❄️
| Hostname | Board | CPU | RAM | Primary GPU | Secondary GPU | Role | OS | State |
|---|---|---|---|---|---|---|---|---|
skrye | Framework Desktop Mainboard | AMD Ryzen AI Max+ 395 | 128GB | AMD Radeon 8060S | 🖥️ | ❄️ | ✅ | |
zannah | Framework Desktop Mainboard | AMD Ryzen AI Max+ 395 | 128GB | AMD Radeon 8060S | 🖥️ | ❄️ | ✅ | |
ravi | Framework 13 | AMD Ryzen AI 9 HX 370 | 96GB | AMD Radeon 890M | 💻️ | ❄️ | ✅ | |
bane | Framework 16 | AMD Ryzen 7 7940HS | 96GB | AMD Radeon 780M | 💻️ | ❄️ | ✅ | |
tanis | ThinkPad Z13 Gen 1 | AMD Ryzen 5 PRO 6650U | 32GB | AMD Radeon 660M | 💻️ | ❄️ | ✅ | |
felkor | ThinkPad X13 Gen 2 | AMD Ryzen 5 PRO 5650U | 16GB | AMD Radeon Vega 7 | 💻️ | ❄️ | 🚧 | |
shaa | ThinkPad T14s Gen 1 | AMD Ryzen 5 PRO 4650U | 16GB | AMD Radeon RX Vega 6 | 💻️ | ❄️ | ✅ | |
nihilus | - | - | - | - | - | 💿 | ❄️ | ✅ |
traya | Mac Mini M2 Pro | Apple M2 Pro chip | 32GB | Apple M2 Pro GPU | 🖥️ | 🍏 | ✅ | |
revan | Z390-DESIGNARE | Intel Core i9-9900K | 64GB | Intel UHD Graphics 630 | NVIDIA T1000 | ☁️ | ❄️ | 🚧 |
malak | B360 HD3P-LM | Intel Core i7-8700 | 128GB | Intel UHD Graphics 630 | - | ☁️ | ❄️ | ✅ |
cognus | GandiCloud | - | - | - | - | 🐄☁️ | ❄️ | ✅ |
maul | TRX40-DESIGNARE | AMD Ryzen Threadripper 3970X | 256GB | NVIDIA RTX 3090 | NVIDIA RTX 2080Ti (22GB) | ☁️ | ❄️ | 🚧 |
Workstation and server host names are Sith Lords and the virtual machines are named after TIE fighter series. Dual boot systems have the NixOS install named a Sith Lord and the "other" OS named after their public-facing persona.
Key
- 🎭️ : Dual boot
- 🖥️ : Desktop
- 💻️ : Laptop
- 🎮️ : Games Machine
- 🐄 : Virtual Machine
- 💿 : ISO image
- ☁️ : Server
- 🧟 : Not in service
As featured on Linux Matters podcast! 🎙️ I am a presenter on Linux Matters and this configuration was featured in Episode 7 - Immutable Desktop Linux for Anyone.
How It Works 🧠
Most NixOS configurations use selective imports - each host cherry-picks which modules to include. This flake does the opposite.
Every module is imported by every host. Modules decide internally whether to activate, based on typed host metadata. I call this the "broadcast-and-gate" pattern, and it changes how you think about composing NixOS configurations.
Self-gating modules
The _mixins directories contain modules that are imported universally. Each module uses lib.mkIf with metadata from the noughty module system to decide whether it should do anything:
# This module activates itself on workstations. Servers and VMs ignore it.
{ config, lib, ... }:
lib.mkIf config.noughty.host.is.workstation {
boot.plymouth.enable = true;
}
A module whose condition is false evaluates to nothing - zero cost, zero side effects. The Nix module system handles this natively.
Conditions can be as specific as you need: workstation vs server, laptop vs desktop, GPU vendor, display layout, user identity, freeform tags. Modules can combine conditions too - "only on Martin's workstations that have an NVIDIA GPU" is a one-liner.
What noughty provides
Every host is registered in the system registry (lib/registry-systems.toml, read by flake.nix) with its properties: what kind of system it is, its platform, form factor, GPU vendors, displays, and freeform tags. The noughty module system turns this registry into typed, overridable NixOS options under config.noughty.*, with derived booleans like host.is.workstation, host.is.laptop, and host.gpu.hasNvidia computed automatically.
Why this matters
Adding a new feature = drop a directory containing a self-gating module. No import lists to edit. No other files to touch. Every host that matches the condition picks it up on next build.
Adding a new host = add a registry entry to lib/registry-systems.toml and create a hardware config. That's it. The new host automatically gets the right desktop, GPU drivers, services, shell, everything - because the modules gate themselves based on the host's properties, not its name.
Host-specific directories (nixos/skrye/, nixos/malak/, etc.) contain only hardware: disk layouts and kernel modules. All behaviour lives in the self-gating modules reacting to host properties.
The full noughty option reference, helper functions, and usage patterns are documented in lib/noughty/README.md.
Structure 📦
.
├── common
│ └── default.nix
├── darwin
│ ├── _mixins
│ │ ├── desktop
│ │ └── features
│ ├── traya
│ └── default.nix
├── home-manager
│ ├── _mixins
│ │ ├── desktop
│ │ ├── development
│ │ ├── filesync
│ │ ├── scripts
│ │ ├── services
│ │ ├── terminal
│ │ └── users
│ └── default.nix
├── lib
│ ├── noughty
│ │ └── default.nix
│ ├── default.nix
│ ├── flake-builders.nix
│ ├── noughty-helpers.nix
│ ├── registry-systems.toml
│ └── registry-users.toml
├── nixos
│ ├── _mixins
│ │ ├── console
│ │ ├── desktop
│ │ ├── hardware
│ │ ├── network
│ │ ├── policy
│ │ ├── scripts
│ │ ├── server
│ │ ├── users
│ │ └── virtualisation
│ ├── bane
│ ├── cognus
│ ├── felkor
│ ├── malak
│ ├── maul
│ ├── nihilus
│ ├── ravi
│ ├── revan
│ ├── shaa
│ ├── sidious
│ ├── skrye
│ ├── tanis
│ ├── zannah
│ └── default.nix
├── overlays
│ └── default.nix
├── pkgs
│ └── default.nix
├── secrets
│ └── secrets.yaml
├── flake.nix
└── justfile
| Directory | Purpose |
|---|---|
common/ | Shared configuration imported by both NixOS and nix-darwin: overlays, system packages, environment variables, shell settings |
darwin/ | macOS system configuration and _mixins for Darwin-specific features |
home-manager/ | Home Manager configuration and _mixins for user-level programs, dotfiles, and scripts |
nixos/ | NixOS system configuration, _mixins for self-gating modules, and per-host hardware directories |
lib/ | The noughty module system, flake-builders.nix for generating configs from the system registry, registry-systems.toml and registry-users.toml for host and user definitions, and pure helper functions |
overlays/ | Custom overlays: local packages, modified packages, and nixpkgs-unstable access |
pkgs/ | Custom local packages |
secrets/ | Encrypted secrets managed by sops-nix |
CI/CD workflows in .github are Nix ❄️ supercharged ⚡️ by Determinate Systems: Install Determinate Nix, FlakeHub Cache, Flake Checker, and Update Flake Lock.
The Shell 🐚
A fully "oxidised" 🦀 Modern Unix shell experience is provided by Fish shell 🐟️ with Starship 🚀 and a collection of tools that deliver a contemporary UX to my terminal 🧑💻
The base system has a firewall enabled and also includes OpenSSH, sops-nix for secret management, Tailscale, and a Fresh terminal editor configuration.
Useful shell scripts I used to keep in muddle of git repos are now migrated to NixOS scripts and Home Manager scripts to provide a declarative, reproducible and shellcheck validated toolbox 🧰

The Desktop 🖥️
Wayfire 🔥 and Mango 🥭 desktop options are available. The font configuration is common for all desktops using Work Sans and Fira Code. The usual creature comforts you'd expect to find in a Linux Desktop are integrated such as Pipewire, Bluetooth, Avahi, CUPS, SANE and NetworkManager.
| Desktops | NixOS | Home Manager | Theme |
|---|---|---|---|
| 🔥 Wayfire | Wayfire NixOS | Wayfire Home Manager | Catppuccin Mocha |
| 🥭 Mango | Mango NixOS | Mango Home Manager | Catppuccin Mocha |
Eye Candy 👀🍬
A Mango screenshot will follow.
Installing 💾
-
Boot off an .iso image created by this flake using
just iso(see below) 💿 -
Put the .iso image on a USB drive, I use USBImager
-
Boot the target computer from the USB drive
-
From a trusted workstation, inject tokens to the ISO host:
just inject-tokens <ip-address>This sends the SOPS age keys to the live environment. Both age keys are hard requirements - the install will abort without them. FlakeHub authentication is handled interactively during install via
determinate-nixd login. Ifdeterminate-nixdis authenticated, the installer uses FlakeHub Cache for a faster install; otherwise it builds locally. -
SSH into the ISO host and run the installer:
ssh nixos@<ip-address> install-system <hostname> [username]The install script uses Disko to partition and format the disks, installs NixOS via
nixos-install, copies the flake to~/Zero/nix-config, and chroots into the new system to activate the Home Manager configuration. -
Make a cuppa 🫖
-
Reboot 🥾
See install-system documentation for the full reference.
Installing to a remote host 🌍
Use just install for the first installation of a remote NixOS host. It wraps nixos-anywhere and uses the Disko layout declared by the host configuration.
For example, malak is a Hetzner dedicated server.
To install it, enable the Hetzner Rescue system and then run the following from one of my workstations:
just install malak <ip-address>
Optional parameters: keep_disks="true" preserves existing disk partitions, and vm_test="true" runs a local VM test instead of deploying.
When the installation is complete, the remote host will be automatically rebooted.
The just install recipe handles SOPS age keys (user and host), initrd SSH keys, and per-host SSH host keys automatically, decrypting them from sops secrets and injecting them into the target.
I keep my Home Manager configuration separate from my NixOS configuration, so after the NixOS configuration has been deployed, I SSH in to the remote host and activate the Home Manager configuration:
git clone https://github.com/wimpysworld/nix-config "$HOME/Zero/nix-config"
cd "$HOME/Zero/nix-config"
just switch-home
For later configuration changes, use the remote push recipes from the workstation instead of running the installer again.
Applying Changes ✨
I clone this repo to ~/Zero/nix-config. NixOS and Home Manager changes are applied separately because I tend to iterate on the Home Manager configuration more frequently than the NixOS configuration.
gh repo clone wimpysworld/nix-config "$HOME/Zero/nix-config"
cd "$HOME/Zero/nix-config"
This flake includes a justfile that provides convenient commands for building and applying configurations.
- ❄️ NixOS & macOS: Use
just hostto build and switch the NixOS or nix-darwin configuration.just build-hostto only build.just switch-hostto only switch.
- 🏠️ Home Manager: Use
just hometo build and switch the Home Manager configuration.just build-hometo only build.just switch-hometo only switch.
- 🌍️ All:
just buildto build both NixOS/nix-darwin and Home Manager configurations.just switchto switch to both NixOS/nix-darwin and Home Manager configurations.
For day-to-day changes on a remote NixOS host, the push recipes build on the workstation and copy the closures to the target. The target defaults to root@<hostname>; pass the target as the second argument to override it:
just push cognus
just push cognus root@<ip-address>
just push <hostname> [target]switches NixOS, then activates Home Manager.just push-host <hostname> [target]switches NixOS immediately.just push-host-boot <hostname> [target]selects the NixOS generation for the next boot without activating it on the live system.just push-home <hostname> [target]activates Home Manager only.
The fast path: FlakeHub Cache
Every push to main builds all configurations in CI and publishes them to FlakeHub Cache with full output paths. The apply commands pull these pre-built closures directly using the fh CLI, completely skipping local Nix evaluation and compilation. No flake evaluation, no derivation realisation, just fetch and activate.
- ⚡️ From FlakeHub Cache:
just applyto apply both NixOS/nix-darwin and Home Manager from FlakeHub Cache.just apply-hometo apply Home Manager only.just apply-hostto apply NixOS/nix-darwin only.
The tradeoff: you get whatever was last published from main. If you have local uncommitted changes, use just host/just home instead.
ISO 📀
Daily ISO builds are available for download from this project's Releases, built automatically via GitHub Actions.
If you'd rather build your own, just iso builds the nihilus ISO image from this flake. It includes install-system for automated installation.
Live images will be left in result/iso/ and also copied to ~/Quickemu/nihilus/nixos.iso.
Building without just
If nh, nom, and just are not available, here are the traditional ways to build and switch.
NixOS
sudo nixos-rebuild boot --flake $HOME/Zero/nix-config
sudo nixos-rebuild switch --flake $HOME/Zero/nix-config
nix build .#nixosConfigurations.{hostname}.config.system.build.toplevel
nix run github:nix-community/nixos-anywhere -- --flake '.#{hostname}' root@{ip-address}
nix-darwin
nix run nix-darwin -- switch --flake ~/Zero/nix-config
nix build .#darwinConfigurations.{hostname}.config.system.build.toplevel
Home Manager
nix build .#homeConfigurations.{username}@{hostname}.activationPackage
./result/activate
ISO
nix build .#nixosConfigurations.nihilus.config.system.build.isoImage
Post-install Checklist
Things I currently need to do manually after installation.
Secrets
- 1Password - authenticate
- LastPass - authenticate
- Run
just detsys-login - Run
gh auth login - Keybase -
keybase login
Accounts
- Atuin
atuin loginatuin sync
- Brave - enroll sync
- Google Chrome - authenticate
- Discord - authenticate
- Harper - review browser extension settings
- Maestral -
maestral_qt - Matrix - authenticate
- Slack - authenticate
- Telegram - authenticate
System
- On macOS run (optional)
- Run Docker Desktop to complete the setup.
Themes
Some applications require manual configuration to apply the correct theme.
- Enable Stylus Sync to Dropbox in Brave to get Catppuccin userstyles and Enable Patch CSP
- Discord OpenAsar
- Add Catppuccin CSS
/* mocha */
@import url("https://catppuccin.github.io/discord/dist/catppuccin-mocha.theme.css");
@import url("https://catppuccin.github.io/discord/dist/catppuccin-mocha-blue.theme.css");