From 3bbe4c322a5bff9b7d69899c341b4d59a25fa56c Mon Sep 17 00:00:00 2001 From: Cole Helbling Date: Sat, 3 Oct 2020 10:03:55 -0700 Subject: [PATCH] nixos-install: use mountpoint as store Otherwise, it's possible building a flake may cause the live CD to run out of memory. --- nixos/modules/installer/tools/nixos-install.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/nixos/modules/installer/tools/nixos-install.sh b/nixos/modules/installer/tools/nixos-install.sh index a180d1bc4c1..90555f14580 100644 --- a/nixos/modules/installer/tools/nixos-install.sh +++ b/nixos/modules/installer/tools/nixos-install.sh @@ -153,7 +153,7 @@ if [[ -z $system ]]; then else echo "building the flake in $flake..." nix "${flakeFlags[@]}" build "$flake#$flakeAttr.config.system.build.toplevel" \ - --extra-substituters "$sub" "${verbosity[@]}" \ + --store "$mountPoint" --extra-substituters "$sub" "${verbosity[@]}" \ "${extraBuildFlags[@]}" "${lockFlags[@]}" --out-link "$outLink" fi system=$(readlink -f "$outLink")