[ 
https://issues.apache.org/jira/browse/MESOS-4446?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15137627#comment-15137627
 ] 

Martin Evgeniev edited comment on MESOS-4446 at 2/8/16 8:29 PM:
----------------------------------------------------------------

HI guys,

First of all i want to ask if any of this Mesos labels stuff is documented? I 
cant find anything :(

The second thing i want to know if there is anyway to make Mesos expose any 
custom value form the docker inspect command. The main problem is that right 
now it only looks for the container IPAddr by this 
"Docker.NetworkSettings.IPAddress" and the docker overlay network this changes 
a bit and if you have custom network the json looks like this:

{code}
"NetworkSettings": {
            "Bridge": "",
            "SandboxID": 
"102744ffe3f07313c0c00e5880fe825d0791a04cecd88d807f8bb40b9cc043ef",
            "HairpinMode": false,
            "LinkLocalIPv6Address": "",
            "LinkLocalIPv6PrefixLen": 0,
            "Ports": {
                "443/tcp": null,
                "80/tcp": null
            },
            "SandboxKey": "/var/run/docker/netns/102744ffe3f0",
            "SecondaryIPAddresses": null,
            "SecondaryIPv6Addresses": null,
            "EndpointID": "",
            "Gateway": "",
            "GlobalIPv6Address": "",
            "GlobalIPv6PrefixLen": 0,
            "IPAddress": "",
            "IPPrefixLen": 0,
            "IPv6Gateway": "",
            "MacAddress": "",
            "Networks": {
                "services": {
                    "IPAMConfig": null,
                    "Links": null,
                    "Aliases": null,
                    "NetworkID": 
"197fbe7b6c76141ba9284311476b363998c852b4718d548226fb9fe32a6ec0ce",
                    "EndpointID": 
"d475269e2fcdc75760ae06365c45bfa63246b0e76c5761b607c215be441674a4",
                    "Gateway": "",
                    "IPAddress": "192.168.0.3",
                    "IPPrefixLen": 16,
                    "IPv6Gateway": "",
                    "GlobalIPv6Address": "",
                    "GlobalIPv6PrefixLen": 0,
                    "MacAddress": "02:42:c0:a8:00:03"
                }
            }
        }
{code}

And basiclly in Mesos state.json the IPAddr value is empty. This value is what 
we use to register the service in Consul..
Am I doing something the wrong way? Is there anyway to rewrite this behavior?

Feel free to ask me if you need mor information.

Thanks


was (Author: suizman):
HI guys,

First of all i want to ask if any of this Mesos labels stuff is documented? I 
cant find anything :(

The second think i want to know if there is anyway to make Mesos expose any 
custom value form the docker inspect command. The main problem is that right 
now it only looks for the container IPAddr by this 
"Docker.NetworkSettings.IPAddress" and the docker overlay network this changes 
a bit and if you have custom network the json looks like this:

{code}
"NetworkSettings": {
            "Bridge": "",
            "SandboxID": 
"102744ffe3f07313c0c00e5880fe825d0791a04cecd88d807f8bb40b9cc043ef",
            "HairpinMode": false,
            "LinkLocalIPv6Address": "",
            "LinkLocalIPv6PrefixLen": 0,
            "Ports": {
                "443/tcp": null,
                "80/tcp": null
            },
            "SandboxKey": "/var/run/docker/netns/102744ffe3f0",
            "SecondaryIPAddresses": null,
            "SecondaryIPv6Addresses": null,
            "EndpointID": "",
            "Gateway": "",
            "GlobalIPv6Address": "",
            "GlobalIPv6PrefixLen": 0,
            "IPAddress": "",
            "IPPrefixLen": 0,
            "IPv6Gateway": "",
            "MacAddress": "",
            "Networks": {
                "services": {
                    "IPAMConfig": null,
                    "Links": null,
                    "Aliases": null,
                    "NetworkID": 
"197fbe7b6c76141ba9284311476b363998c852b4718d548226fb9fe32a6ec0ce",
                    "EndpointID": 
"d475269e2fcdc75760ae06365c45bfa63246b0e76c5761b607c215be441674a4",
                    "Gateway": "",
                    "IPAddress": "192.168.0.3",
                    "IPPrefixLen": 16,
                    "IPv6Gateway": "",
                    "GlobalIPv6Address": "",
                    "GlobalIPv6PrefixLen": 0,
                    "MacAddress": "02:42:c0:a8:00:03"
                }
            }
        }
{code}

And basiclly in Mesos state.json the IPAddr value is empty. This value is what 
we use to register the service in Consul..
Am I doing something the wrong way? Is there anyway to rewrite this behavior?

Feel free to ask me if you need mor information.

Thanks

> Set Docker labels based on TaskInfo labels.
> -------------------------------------------
>
>                 Key: MESOS-4446
>                 URL: https://issues.apache.org/jira/browse/MESOS-4446
>             Project: Mesos
>          Issue Type: Story
>          Components: docker
>            Reporter: Gennady Feldman
>            Assignee: Abhishek Dasgupta
>
> So looks like MESOS-3076 added support for Labels to TaskStatus. Would it be 
> possible to pass those onto the docker container?
> This would really help with doing "docker inspect" on the mesos-slave nodes 
> as well as allow us to better collect docker metrics about the 
> tasks/containers that are currently running on the slave.
> docker supports labels out of the box. See here: 
> https://docs.docker.com/engine/userguide/labels-custom-metadata/



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

Reply via email to