diff --git a/pkgs/build-support/singularity-tools/default.nix b/pkgs/build-support/singularity-tools/default.nix index 2a67169628795..f85e9745d7824 100644 --- a/pkgs/build-support/singularity-tools/default.nix +++ b/pkgs/build-support/singularity-tools/default.nix @@ -99,7 +99,6 @@ lib.makeExtensible (final: { inherit memSize; } '' - rmdir "$out" mkdir workspace mkfs -t ext3 -b 4096 /dev/${vmTools.hd} mount /dev/${vmTools.hd} workspace diff --git a/pkgs/build-support/vm/default.nix b/pkgs/build-support/vm/default.nix index 648fea5cd0163..8e262b20b3f63 100644 --- a/pkgs/build-support/vm/default.nix +++ b/pkgs/build-support/vm/default.nix @@ -240,6 +240,10 @@ rec { vmRunCommand = qemuCommand: writeText "vm-run" '' + if [ -f "''${NIX_ATTRS_SH_FILE-}" ]; then + source "$NIX_ATTRS_SH_FILE" + fi + source $stdenv/setup export > saved-env PATH=${coreutils}/bin