From 1a68710d4dff609bbaf61db3e17a2573f0aadf17 Mon Sep 17 00:00:00 2001 From: Eelco Dolstra Date: Tue, 2 May 2017 13:44:10 +0200 Subject: Add an option for specifying remote builders This is useful for one-off situations where you want to specify a builder on the command line instead of having to mess with nix.machines. E.g. $ nix-build -A hello --argstr system x86_64-darwin \ --option builders 'root@macstadium1 x86_64-darwin' will perform the specified build on "macstadium1". It also removes the need for a separate nix.machines file since you can specify builders in nix.conf directly. (In fact nix.machines is yet another hack that predates the general nix.conf configuration file, IIRC.) Note: this option is supported by the daemon for trusted users. The fact that this allows trusted users to specify paths to SSH keys to which they don't normally have access is maybe a bit too much trust... --- src/libstore/globals.hh | 3 +++ 1 file changed, 3 insertions(+) (limited to 'src/libstore/globals.hh') diff --git a/src/libstore/globals.hh b/src/libstore/globals.hh index 25cc3e068ee7..d7a0b86a0889 100644 --- a/src/libstore/globals.hh +++ b/src/libstore/globals.hh @@ -130,6 +130,9 @@ public: PathSetting buildHook{this, true, nixLibexecDir + "/nix/build-remote", "build-hook", "The path of the helper program that executes builds to remote machines."}; + Setting builders{this, "", "builders", + "A semicolon-separated list of build machines, in the format of nix.machines."}; + Setting reservedSize{this, 8 * 1024 * 1024, "gc-reserved-space", "Amount of reserved disk space for the garbage collector."}; -- cgit 1.4.1