Closed seberm closed 2 years ago
sure, you can for example use populate (which is the part to put everything into /var/src on the target system):
...
pkgs.populate "deploy" {
source = source;
target = "root@YOUR_IP_ADDRESS_OR_HOST_NAME_HERE";
}
to run other commands than nixos-rebuild switch you can use writeComamnd:
pkgs.krops.writeCommand "deploy-boot" {
command = targetPath: ''
nixos-rebuild -I ${targetPath} boot
'';
source = source;
target = "root@YOUR_IP_ADDRESS_OR_HOST_NAME_HERE";
}
Thank you Lassulus for you help! It seems it's finally working as expected :).
Hello, I am still very new to NixOS and krops. I just want to ask if there is a possibility to configure krops to do a deploy without switching to the new configuration on a target host.
What I basically need is to just make the sources available on the target machine in
/var/src
. That's all. There are some cases where I need to run thenixos-build boot
instead of anixos-build switch
. Is this possible with current implementation?Thank you! Ota