about summary refs log tree commit diff
path: root/src
diff options
context:
space:
mode:
authorEelco Dolstra <edolstra@gmail.com>2018-08-31T09·12+0200
committerEelco Dolstra <edolstra@gmail.com>2018-08-31T09·12+0200
commitc0c31b58a43dc46c5f2a4f7f1880387db449711b (patch)
tree3dcc85c3a3550197583868f4cdf1da6bb2e1c9aa /src
parentadab8b916a45067c044658c4158d81878f9ed1c3 (diff)
Add localhost alias for ::1 to the sandbox
Diffstat (limited to 'src')
-rw-r--r--src/libstore/build.cc2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/libstore/build.cc b/src/libstore/build.cc
index d75ca0be86ef..cd37f7a3fc08 100644
--- a/src/libstore/build.cc
+++ b/src/libstore/build.cc
@@ -2007,7 +2007,7 @@ void DerivationGoal::startBuilder()
 
         /* Create /etc/hosts with localhost entry. */
         if (!fixedOutput)
-            writeFile(chrootRootDir + "/etc/hosts", "127.0.0.1 localhost\n");
+            writeFile(chrootRootDir + "/etc/hosts", "127.0.0.1 localhost\n::1 localhost\n");
 
         /* Make the closure of the inputs available in the chroot,
            rather than the whole Nix store.  This prevents any access