Github user jieyu commented on a diff in the pull request:
https://github.com/apache/mesos/pull/263#discussion_r168652532
--- Diff: src/slave/containerizer/mesos/isolators/network/cni/cni.cpp ---
@@ -751,10 +751,11 @@ Future<Option<ContainerLaunchInfo>>
NetworkCniIsolatorProcess::prepare(
launchInfo.add_clone_namespaces(CLONE_NEWNET);
launchInfo.add_clone_namespaces(CLONE_NEWNS);
launchInfo.add_clone_namespaces(CLONE_NEWUTS);
+ infos[containerId]->needsSeparateNs = needsSeparateNs;
}
} else {
- // This is a nested container. This shares the parent's network
- // and UTS namespace. For non-DEBUG containers it also needs a
+ // This is a nested container and wants to share parent's network
+ // and UTS namespace. For non-DEBUG containers, it also needs a
--- End diff --
```
launchInfo.add_enter_namespaces(CLONE_NEWNET);
launchInfo.add_enter_namespaces(CLONE_NEWUTS);
if (!isDebugContainer) {
launchInfo.add_clone_namespaces(CLONE_NEWNS);
}
---