working remotely I would feel safer with a nixos-rebuild interactive mode: after nixos-rebuild test or nixos-rebuild switch the user is asked for confirmation, the user failing to confirm would cause a rollback to the previous working configuration.
I’ve been unable to find a similar feature in the nixos documentation.
That’s a great idea. The user would have to commit the changes after the switch.
LumiGuide is doing something similar for their servers, a revert service is started and has to be cancelled by putting a file at a specific location in the filesystem. In their case it happens over SSH but I imagine that it could be generalized to also a UI. This is not part of nixpkgs yet but would be a welcome addition.