2

I have recently upgraded to Mesos mesos-0.25.0-0.2.70 on CentOS 7. In order to set the DOCKER_HOST environment variable for Mesos, I had previously configured it with a file "/etc/mesos-slave/executor_environment_variables", the contents of which read:

{"DOCKER_HOST": "localhost:12375"}

With the upgrade of Mesos, and a newer Weave version this has stopped working. The latest version of Weave listens on a Unix socket before defaulting to a TCP socket, so I have now changed the contents of the aforementioned file to read:

{"DOCKER_HOST": "unix:///var/run/weave/weave.sock"}

Yet when I create a Docker container via Marathon it gets built in the Mesos cluster without any Weave IP or DNS. I am confused - all that needs to happen is for Mesos to pick up the environment variable DOCKER_HOST, which is not happening.

I'd be happy if anyone can throw pointers my way.

Stephen K.
  • 79
  • 10
  • Did you ever figure this out? I'm having the same issue. that is, getting mesos to pick up DOCKER_HOST – Andi Jay Nov 01 '17 at 20:58

1 Answers1

0

This is an old question but in case anyone stumbles on this one. I was having a similar issue where containers started by Mesos (via Marathon) were not registering with WeaveDNS. To get this to work, when starting up the mesos agent, I used the flag "--docker_socket" and set it equal to the 'DOCKER_HOST' path outputted when you run the command "weave env".

My containers started registering with WeaveDNS after this.

Andi Jay
  • 5,882
  • 13
  • 51
  • 61