-
Notifications
You must be signed in to change notification settings - Fork 613
Docker 1.12 Swarm Mode #207
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Comments
Confirming I am also seeing the same results with spinning up an ELK Stack deployment using
Below is my
Thoughts! Link to my GitHub repo with the above config as well under branch |
i'm using nginx reverse proxy, and i have 2 node of docker swarm, when i create the container with the environment VIRTUAL_HOST and the network "overlay" the docker-gen doesn't take the ip, i recieve only: upstream pluto3.com { |
@giammy2290 you may find a solution in #169
|
@vincentfretin yes this works for me, but if i use 2 or more docker node (swarm cluster) docker-gen doesn't work (i have set the endpoint to the docker master node api) |
@giammy2290 for that reason i use socat on manager nodes and run docker-gen container attached to it not to var/run/docker.sock. It's a good idea to secure such socat endpoint. then docker-gen work regardles of where it is run. |
@s4s0l Appreciate if you can please provide a socat example to make it work with multi-node swarm cluster |
I'm working on it at the moment. What I've got so far is a sockat running on manager node host OS. I'm working on some docker image so this socat can be run in 'global' mode in swarm. I'll put it somewhere in github. It'll probably take me some time to do it, but it is something like (first part is in groovy but i think its reverse engeneerable):
I'll make it more portable later, the point is generate certs and keys for the server (socat) and client (docker-gen), see http://www.dest-unreach.org/socat/doc/socat-openssltunnel.html and https://youremindmeofmymother.com/2015/08/21/socat-ssl-ssl-routinesssl3_check_cert_and_algorithmdh-key-too-small/ then:
The whole point is to start socat like this:
As I said I'm working on some more shareable form of it, but decided to paste it here as maybe you guys would have some comments and save me from doing something wrong;) |
Ok, the most important is #239 anyway. Forgot the obvious. |
@lvnilesh In my fork is full working example https://github.com/s4s0l/docker-gen. I don't like it because it pulls for changes constantly (as swarm mode events are not included in /events docker api). I also dont like docker-gen is crushing when socat endpoint is unavailable and swarm restarts it until it becomes...but i works and in some circumstances may be the only way to hack around docker. I've closed my PR as it generally is workaround for docker-gen which itself is kid of workaround so I convinced myself that it would do harm to docker-gen codebase;) But if @jwilder thins its ok, I can prepare it once again. |
Thanks @s4s0l |
There is a working solution: |
Checkout my image. It's written in javascript and will be developed easily. Pull requests are welcome 🙂 |
The new swarm mode doesn't appear to expose running containers/services like Docker Swarm previous did. For that reason, it would seem that this project is not available to me. Are there any plans to account for that?
The text was updated successfully, but these errors were encountered: