mesos-reviews mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Avinash sridharan <avin...@mesosphere.io>
Subject Re: Review Request 60500: Introduced `--default_container_dns` agent flag.
Date Tue, 18 Jul 2017 13:19:27 GMT


> On July 17, 2017, 11:12 p.m., Avinash sridharan wrote:
> > src/messages/flags.proto
> > Lines 56 (patched)
> > <https://reviews.apache.org/r/60500/diff/2/?file=1769366#file1769366line56>
> >
> >     Had an internal discussion on this with Jie, and seems like having different
DNS options for CNI and CNM is not something we need to worry about, so we should merge the
fields into one.
> 
> Qian Zhang wrote:
>     OK, so the protobuf message should be like the below, right?
>     ```
>     message ContainerDNS {
>       message DNSInfo {
>         // Specify CNI network name or CNM network name as the value of
>         // of this field. For CNM host network, its name is `host`, for
>         // CNM default bridge network, its name is `bridge`, for a CNM
>         // user-defined network, its name is specified by:
>         // `ContainerInfo.network_infos(0).name`.
>         required string network = 1;
>     
>         // For CNI network, all four fields in `slave.cni.spec.DNS` are
>         // supported, but for CNM network, we only support three fields:
>         // `nameservers`, `search` and `options` but not `domain` since
>         // Docker only has `--dns`, `--dns-search`, `--dns-option` options.
>         required slave.cni.spec.DNS dns = 2;
>       }
>     
>       repeated DNSInfo dns = 1;
>     }
>     ```

That looks about right. Another thing that came out of the discussion is that we should probably
make the `network` field optional. This would then follow the semantic of the `network/cni`
isolator for missing `network` field implying host networks. That said, currently, we should
not be supporting setting DNS for the host networking since the behavior is different for
CNI and CNM. Also, changing DNS for host networking doesn't make that much sense. To protect
against host networking we can add a validation check as a lambda in the `--default_container_dns`
flag? 

For any unsupported DNS options (`domain` in CNM) we should throw a `LOG(WARNING)` while configuring
the container's DNS.


- Avinash


-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/60500/#review180764
-----------------------------------------------------------


On July 5, 2017, 7:03 a.m., Qian Zhang wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/60500/
> -----------------------------------------------------------
> 
> (Updated July 5, 2017, 7:03 a.m.)
> 
> 
> Review request for mesos, Avinash sridharan and Jie Yu.
> 
> 
> Bugs: MESOS-7709
>     https://issues.apache.org/jira/browse/MESOS-7709
> 
> 
> Repository: mesos
> 
> 
> Description
> -------
> 
> Introduced `--default_container_dns` agent flag.
> 
> 
> Diffs
> -----
> 
>   docs/configuration.md 007d0f556375f331148c9ad09be8b301ab31a01c 
>   src/messages/flags.hpp 70ad58c33067a0b058deafdcc4ffc5f554b6ca72 
>   src/messages/flags.proto e87075f19714739b93d9f4aa33ea8686a1bb5613 
>   src/slave/flags.hpp c6803eb54e09a5497755e1e5fef2872193eacba6 
>   src/slave/flags.cpp 398768656b5fa3b7c85474de2b4b008bf7b85cb3 
> 
> 
> Diff: https://reviews.apache.org/r/60500/diff/2/
> 
> 
> Testing
> -------
> 
> 
> Thanks,
> 
> Qian Zhang
> 
>


Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message