diff --git a/flake.nix b/flake.nix index 61f95b8..73f011a 100644 --- a/flake.nix +++ b/flake.nix @@ -46,7 +46,7 @@ # run nixos-rebuild switch on the target system # the config will be built locally and copied over "${name}-update" = nixpkgs.legacyPackages.x86_64-linux.writeShellScriptBin "update" '' - nixos-rebuild switch --flake .#${name} --target-host root@${name}.test.htw.stura-dresden.de + nixos-rebuild switch --flake .#${name} --target-host root@${(builtins.head (nixosConfigurations.${name}.config.networking.interfaces.${builtins.head (builtins.attrNames nixosConfigurations.${name}.config.networking.interfaces)}.ipv4.addresses)).address} ''; # copy install image to testserver and deploy the specified configuration to it