> On 三月 8, 2016, 1:22 a.m., Jie Yu wrote: > > src/slave/containerizer/mesos/isolators/network/port_mapping.hpp, lines > > 66-72 > > <https://reviews.apache.org/r/44454/diff/1/?file=1283144#file1283144line66> > > > > This is not the reliable solution. What if /var/run points to some > > other place? > > > > I think we should make this a field member (instead of a constant), and > > call realpath when creating the isolator.
@yujie, what about the following? inline std::string PORT_MAPPING_BIND_MOUNT_ROOT() { return path::join( os::realpath("/var/run").get(), "netns"); } - Guangya ----------------------------------------------------------- This is an automatically generated e-mail. To reply, visit: https://reviews.apache.org/r/44454/#review122446 ----------------------------------------------------------- On 三月 7, 2016, 3:42 p.m., Guangya Liu wrote: > > ----------------------------------------------------------- > This is an automatically generated e-mail. To reply, visit: > https://reviews.apache.org/r/44454/ > ----------------------------------------------------------- > > (Updated 三月 7, 2016, 3:42 p.m.) > > > Review request for mesos and Jie Yu. > > > Bugs: MESOS-4662 > https://issues.apache.org/jira/browse/MESOS-4662 > > > Repository: mesos > > > Description > ------- > > Returned real path for PORT_MAPPING_BIND_MOUNT_ROOT. > > > Diffs > ----- > > src/slave/containerizer/mesos/isolators/network/port_mapping.hpp > 0fe2f486eb733acf738c1c61fc44f820d7401afc > src/slave/containerizer/mesos/isolators/network/port_mapping.cpp > 134b6c759b769cf335539e49eff817973c7f96a4 > > Diff: https://reviews.apache.org/r/44454/diff/ > > > Testing > ------- > > make > make check > > > Thanks, > > Guangya Liu > >