Hi, just trying to setup some automated scripts that would use nvd to run remote builds on my homelab servers. I’d like the scripts to be able to print out a diff of what is being built via nvd, but whenever I do a nixos-rebuild --target-host user@host build --flake .#<profile>
I can’t seem to find the resulting “result” folder for me to use for the diff, any tips? (even if it’s an approach change)
Thank you!
Hrm… I’m not sure, but perhaps don’t provide --target-host
?
I’d like to compare what I am building and about to deploy, with what’s currently running.
For example I use this script to run local build and then print the diff between the new build and the current system.
sudo nixos-rebuild build --flake .
nvd diff /run/current-system result
So I basically want to do this, but against the remote server. Is there a way to at least query via nix-store the last copied over build?
You could get the current system of the remote with
ssh user@domain realpath /run/current-system
If you’ve built that on the local machine the resulting path in the nix store should also be available there.