----------------------------------------------------------- This is an automatically generated e-mail. To reply, visit: https://reviews.apache.org/r/60766/#review183307 -----------------------------------------------------------
src/slave/containerizer/mesos/containerizer.cpp Line 244 (original), 245 (patched) <https://reviews.apache.org/r/60766/#comment259349> So here we only count `network/cni` isolator and `network/port_mapping` isolator, either of them (but not both of them) can work with `network/ports` isolator. Can you please also update the comments accordingly? src/slave/containerizer/mesos/isolators/network/ports.cpp Lines 308-311 (original), 313-323 (patched) <https://reviews.apache.org/r/60766/#comment259352> I think we only need to do this check for top-level container, but not for nested container since nested container always share network namespace with its parent. So we may need to add `!containerId.has_parent()` into the condition of the first `if`. src/slave/containerizer/mesos/isolators/network/ports.cpp Lines 392-402 (patched) <https://reviews.apache.org/r/60766/#comment259353> Can we check `state->executor_info().container().network_infos()` rather than checking CNI container dir? - Qian Zhang On July 29, 2017, 8:01 a.m., James Peach wrote: > > ----------------------------------------------------------- > This is an automatically generated e-mail. To reply, visit: > https://reviews.apache.org/r/60766/ > ----------------------------------------------------------- > > (Updated July 29, 2017, 8:01 a.m.) > > > Review request for mesos, Qian Zhang and Jiang Yan Xu. > > > Bugs: MESOS-7675 > https://issues.apache.org/jira/browse/MESOS-7675 > > > Repository: mesos > > > Description > ------- > > Working on the assumption that containers with CNI networks will > get their own IP addresses and don't need port isolation, ignore > any containers that are joining CNI networks. > > > Diffs > ----- > > src/slave/containerizer/mesos/containerizer.cpp > 5772421c3078d36225b946a5286b8c1bf2f007e8 > src/slave/containerizer/mesos/isolators/network/ports.hpp PRE-CREATION > src/slave/containerizer/mesos/isolators/network/ports.cpp PRE-CREATION > > > Diff: https://reviews.apache.org/r/60766/diff/8/ > > > Testing > ------- > > make check (Fedora 26). > > > Thanks, > > James Peach > >
