diff options
author | Eelco Dolstra <edolstra@gmail.com> | 2017-05-01T13·46+0200 |
---|---|---|
committer | Eelco Dolstra <edolstra@gmail.com> | 2017-05-01T15·30+0200 |
commit | d7653dfc6dea076ecbe00520c6137977e0fced35 (patch) | |
tree | 79d59cdf8385c8e36bee4cf04cd2364b9e267629 /src/build-remote/build-remote.cc | |
parent | ca9f589a93309ca548d772f1634169007568d6a0 (diff) |
Remove $NIX_BUILD_HOOK and $NIX_CURRENT_LOAD
This is to simplify remote build configuration. These environment variables predate nix.conf. The build hook now has a sensible default (namely build-remote). The current load is kept in the Nix state directory now.
Diffstat (limited to 'src/build-remote/build-remote.cc')
-rw-r--r-- | src/build-remote/build-remote.cc | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/src/build-remote/build-remote.cc b/src/build-remote/build-remote.cc index 1ee8a625b6bc..c41383bcf27d 100644 --- a/src/build-remote/build-remote.cc +++ b/src/build-remote/build-remote.cc @@ -140,7 +140,9 @@ int main (int argc, char * * argv) settings.buildTimeout = std::stoll(argv[3]); verbosity = (Verbosity) std::stoll(argv[4]); - currentLoad = getEnv("NIX_CURRENT_LOAD", "/run/nix/current-load"); + /* It would be more appropriate to use $XDG_RUNTIME_DIR, since + that gets cleared on reboot, but it wouldn't work on OS X. */ + currentLoad = settings.nixStateDir + "/current-load"; std::shared_ptr<Store> sshStore; AutoCloseFD bestSlotLock; |