summaryrefslogtreecommitdiffstats
path: root/nixos/modules/profiles
diff options
context:
space:
mode:
authorRobert Hensing <robert@roberthensing.nl>2023-11-19 20:56:15 +0100
committerRobert Hensing <robert@roberthensing.nl>2023-11-19 21:06:32 +0100
commit66b29137978dcca809ffdfba8d9d7d7f7f6a114b (patch)
treea2c99dbaea4f17d5108b9c39c78cd878ffa56c51 /nixos/modules/profiles
parentb4cd4df055e6af72abbea00ecee704e6b3149f1a (diff)
darwin.linux-builder: Disable evaluation
A remote builder does not need to evaluate anything, so let's trim it down to (eventually) save some space, and make the purpose of the builder clear. Users should evaluate on the host instead.
Diffstat (limited to 'nixos/modules/profiles')
-rw-r--r--nixos/modules/profiles/macos-builder.nix10
1 files changed, 10 insertions, 0 deletions
diff --git a/nixos/modules/profiles/macos-builder.nix b/nixos/modules/profiles/macos-builder.nix
index d48afed18f7e..5454b29f2eb9 100644
--- a/nixos/modules/profiles/macos-builder.nix
+++ b/nixos/modules/profiles/macos-builder.nix
@@ -103,6 +103,16 @@ in
# server that QEMU provides (normally 10.0.2.3)
networking.nameservers = [ "8.8.8.8" ];
+ # The linux builder is a lightweight VM for remote building; not evaluation.
+ nix.channel.enable = false;
+ # remote builder uses `nix-daemon` (ssh-ng:) or `nix-store --serve` (ssh:)
+ # --force: do not complain when missing
+ # TODO: install a store-only nix
+ # https://github.com/NixOS/rfcs/blob/master/rfcs/0134-nix-store-layer.md#detailed-design
+ environment.extraSetup = ''
+ rm --force $out/bin/{nix-instantiate,nix-build,nix-shell,nix-prefetch*,nix}
+ '';
+
nix.settings = {
auto-optimise-store = true;