Open danbst opened 7 years ago
You specify a new backend (virtualbox) for example. You deploy there the current configuration, mount new LVM and deploy again. Not much NixOps can do here.
That is an option too, but if I can reboot machine remotely (in my case, Hetzner machine), I could have used nixos-rebuild test
functionality.
For example, here is suggested to use nixos-rebuild test
, but nixops deploy
can't do that.
As an ugly workaround, you may mount something over /boot, so that the old grub config file isn't overwritten.
A less ugly manner would be to use the --copy-only
option to nixops deploy
to prevent the new configuration from being activated, and then run /nix/store/<path-to-the-new-configuration>/bin/switch-to-configuration test
by hand on the target machine.
I'd like to perform a
nixops deploy
of a dangerous operation (mounting new LVM volumes). I didn't find in --help an equivalent ofnixos-rebuild test
.I can't rely on
nixops rollback
because my dangerous operation can kill sshd.