jail: include /etc/nsswitch.conf in jail for glibc.
[project/procd.git] / jail / jail.c
index ca8b832ea219880f40f8076c8286cc103727e896..5a1c05b939729b42ea00213bfb17ae6f0842ce61 100644 (file)
@@ -790,6 +790,11 @@ int main(int argc, char **argv)
                                add_mount("/etc/group", 0, -1);
                        }
 
+#if defined(__GLIBC__)
+                       if (!opts.extroot)
+                               add_mount("/etc/nsswitch.conf", 0, -1);
+#endif
+
                        if (!(opts.namespace & CLONE_NEWNET)) {
                                add_mount("/etc/resolv.conf", 0, -1);
                        }