diff --git a/packages.nix b/packages.nix index 7c48e325..3d2eedde 100644 --- a/packages.nix +++ b/packages.nix @@ -97,6 +97,7 @@ lib.attrsets.mapAttrs rebuildArg = "--flake ${self}#${name} ${overrideInputsArgs} --accept-flake-config"; hostConfig = self.nixosConfigurations."${name}".config; declaredRunnerDrvPath = discardStringCtx hostConfig.microvm.declaredRunner.drvPath; + declaredRunnerOutPath = discardStringCtx hostConfig.microvm.declaredRunner.outPath; toplevelDrvPath = discardStringCtx hostConfig.system.build.toplevel.drvPath; toplevelOutPath = discardStringCtx hostConfig.system.build.toplevel.outPath; # let /var/lib/microvm/*/flake point to the flake-update branch so that @@ -254,21 +255,15 @@ lib.attrsets.mapAttrs exit 2 ''} - ${hostConfig.system.build.copyToServer} ${declaredRunnerDrvPath} + nix build -L --no-link ${declaredRunnerDrvPath}^* + ${hostConfig.system.build.copyToServer} ${declaredRunnerOutPath} ${hostConfig.system.build.runOnServer} bash -e < flake - ${createSymlinks name} systemctl restart microvm@${name}.service