docs:nixos

NixOS

Nix is and means multiple things – there is:

  • Nix the language
  • Nix the package-manager
  • NixOS the distribution
  • Nix the german slang for “nichts”

There are some offical guides to NixOS that you can find on nixos.org, an other source of information is the unoffical user wiki and for a general introduction you can look at zero-to-nix.

Our Nix configuration lives at https://forgejo.c3voc.de/voc/cm/src/branch/master/nixos and one three configuration_managment tools in use, scoped for all new data center related systems.

Each NixOS managed host has a set of default options (flake.nix, outputs.colmena.default) and all host specific options, which should be placed under hosts/<hostname>/.

You need to have the nix packet manager installed on your local system.

We use colemena to deploy configs to our nix-based hosts.

To get a shell with colmena installed run in this directory:

  nix develop

… TBD

To get a shell with colmena installed run in this directory:

  nix develop

To deploy a specific host simply run

  colmena apply switch --on "<name from host.nix>"

When you are on a non x86_64-linux platform you want to use a nix remote builder.

In case you don't have a remote-builder available you can do --build-on-target to use the target machine as builder.

  • docs/nixos.txt
  • Last modified: 2026/03/29 19:27
  • by andi