Provide /var/run/nscd/socket in the sandbox

Otherwise sandbox builds can fail, e.g.

  $ NIX_REMOTE=local?root=/tmp/nix nix-build '<nixpkgs>' -A hello --option build-use-substitutes false
  ...
  downloading ‘http://ftpmirror.gnu.org/bash/bash-4.3-patches/bash43-047’...
  error: unable to download ‘http://ftpmirror.gnu.org/bash/bash-4.3-patches/bash43-047’: Couldn't resolve host name (6)
This commit is contained in:
Eelco Dolstra 2017-01-02 14:46:37 +01:00
parent c4f4eef915
commit b6b142b4b1
No known key found for this signature in database
GPG key ID: 8170B4726D7198DE

View file

@ -2340,6 +2340,7 @@ void DerivationGoal::runChild()
ss.push_back("/etc/nsswitch.conf");
ss.push_back("/etc/services");
ss.push_back("/etc/hosts");
ss.push_back("/var/run/nscd/socket");
}
for (auto & i : ss) dirsInChroot[i] = i;