----------------------------------------------------------- This is an automatically generated e-mail. To reply, visit: https://reviews.apache.org/r/61237/#review181781 -----------------------------------------------------------
Fix it, then Ship it! src/docker/docker.hpp Lines 112-113 (original), 112-113 (patched) <https://reviews.apache.org/r/61237/#comment257501> Not yours, the word `no IP has been not assigned` seems incorrect, should it be `no IP has been assigned`? src/docker/docker.cpp Line 342 (original), 345 (patched) <https://reviews.apache.org/r/61237/#comment257502> Not yours, should `failback` be `fallback`? src/docker/docker.cpp Lines 361 (patched) <https://reviews.apache.org/r/61237/#comment257503> It seems we need one more space here for indent. src/docker/executor.cpp Lines 236-238 (patched) <https://reviews.apache.org/r/61237/#comment257504> I think these 3 lines can be merged into 2 lines, like: ``` // NOTE: By default the protocol is set to IPv4 and therefore // we explicitly set the protocol only for an IPv6 address. ``` - Qian Zhang On July 29, 2017, 8:51 a.m., Avinash sridharan wrote: > > ----------------------------------------------------------- > This is an automatically generated e-mail. To reply, visit: > https://reviews.apache.org/r/61237/ > ----------------------------------------------------------- > > (Updated July 29, 2017, 8:51 a.m.) > > > Review request for mesos, Jie Yu and Qian Zhang. > > > Bugs: MESOS-7807 > https://issues.apache.org/jira/browse/MESOS-7807 > > > Repository: mesos > > > Description > ------- > > A docker container can have a v4 and a v6 address. Currently the docker > executor was returning only the IPv4 address. This changes allows the > executor to return the IPv4 and IPv6 address of the container. > > > Diffs > ----- > > src/docker/docker.hpp 5593cb635e073334c6c2566be3d803cd7febb1c3 > src/docker/docker.cpp 8081c0203bf62cf62aa3b93d745f0e829ad65509 > src/docker/executor.cpp e03f24461ec7b19cacae79c020406f0a475f2d19 > > > Diff: https://reviews.apache.org/r/61237/diff/1/ > > > Testing > ------- > > Start agent: > sudo ./bin/mesos-agent.sh --ip=10.0.2.15 --master=10.0.2.15:5050 > --work_dir=/tmp/mesos --containerizers=mesos,docker > > Start master: > sudo ./bin/mesos-master.sh --ip=10.0.2.15 --work_dir=/tmp/mesos-master > > Use mesos-execute to launch a docker container on an IPv6 network: > sudo src/mesos-execute --master=10.0.2.15:5050 > --task=file:///home/vagrant/dev/mesos_tasks/docker.json 2> log.txt > > cat /home/vagrant/dev/mesos_tasks/docker.json > { > "name": "test", > "task_id": {"value" : "test"}, > "agent_id": {"value" : ""}, > "resources": [ > { > "name": "cpus", > "type": "SCALAR", > "scalar": { > "value": 0.1 > } > }, > { > "name": "mem", > "type": "SCALAR", > "scalar": { > "value": 32 > } > } > ], > "command": { > "shell": false > }, > "container": { > "type": "DOCKER", > "docker": { > "image": "nginx", > "network": "USER" > }, > "network_infos": [ > { > "name": "ipv6" > } > ] > } > } > > > Curl the Mesos state to make sure that the right IPv6 addresses are reflected > for the container: > curl http://10.0.2.15:5051/state | jq > > "role": "*", > "statuses": [ > { > "state": "TASK_RUNNING", > "timestamp": 1501288232.79384, > "container_status": { > "container_id": { > "value": "59319a5b-a28b-46bf-a20f-8472e6598abd" > }, > "network_infos": [ > { > "ip_addresses": [ > { > "protocol": "IPv4", > "ip_address": "172.19.0.2" > }, > { > "protocol": "IPv6", > "ip_address": "fd00:0:0:1::2" > } > ], > "name": "ipv6" > } > ] > } > } > ], > "container": { > "type": "DOCKER", > "docker": { > "image": "nginx", > "network": "USER", > "privileged": false > }, > "network_infos": [ > { > "name": "ipv6" > } > ] > } > } > ], > > > Thanks, > > Avinash sridharan > >
