Hey everyone, so I’m using Snowfall Lib v2 for having a relatively structured approach to managing my nix configs.
I was wondering if there was a way to have a flake.lock
file per host. The reason I ask this is because, running nix flake update
will update the flakes for all hosts. Under normal circumstances this is not a problem. But recently I ran into an issue where nixos-rebuild switch
worked successfully on host 1, but not on host 2 after the nix flake update
. Host 2 had the cloud-init
module which was breaking for some reason. Anyways long story short if I could manage 2 flake.lock
files per host, this wouldn’t have been a problem, since after the failed updated on host 2. I would 've just reverted the flake.lock
file for host 2, thereby having a perfectly reproducible config.
Please do suggest any other ways of solving the problem as well. The simplest I thought was to manage 2 flake.locks, but if there are more, do suggest.