Skip to content

Instantly share code, notes, and snippets.

What would you like to do?
RE: NixOS in production

I think Gabriel's blogpost he explains how to work around nixos-rebuild's inflexibilities. However, I think everything that is being suggested is actually possible in nixos-rebuild already

They blog is still a good exercise to understanding what nixos-rebuild does behind the scenes though.

Deploy to a target machine, from a build machine, with pinned nixpkgs, and a specific nixos config:

nixos-rebuild switch \
  --build-host=build@build.service.consul \
  --target-host=root@node1.node.consul \
  -I nixos-config=./configs/node1.nix nixpkgs=
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment