ekesken / docker-rabbitmq Goto Github PK
View Code? Open in Web Editor NEWdocker image to deploy rabbitmq cluster on mesos with one marathon app
Home Page: https://hub.docker.com/r/ekesken/rabbitmq/
docker image to deploy rabbitmq cluster on mesos with one marathon app
Home Page: https://hub.docker.com/r/ekesken/rabbitmq/
When the method get_cluster_node_ips()
queries marathon for running tasks, it gets the host names in the following kind of format:
"id": "rabbitmq.d7ce8331-e07c-11e5-b2f1-024221d383f1",
"host": "agent-1",
"ipAddresses": [],
"ports": [
31224
],
These names are then used in method configure_name_resolving()
like they would be IP addresses. The end result is, that HOSTS file gets illegal entries and RabbitMQ master is never found. Here is the log file describing the above sequence:
2016-03-02 14:23:36,367 [INFO] Discovering configuration from http://marathon.mesos:8080 for app /rabbitmq
2016-03-02 14:23:36,368 [INFO] Starting new HTTP connection (1): marathon.mesos
2016-03-02 14:23:36,376 [INFO] Found 2 tasks for /rabbitmq
2016-03-02 14:23:36,377 [INFO] Adding extra entries to /etc/hosts...
2016-03-02 14:23:36,377 [INFO] Adding current node entries
2016-03-02 14:23:36,377 [INFO] +127.0.0.1 agent-1
2016-03-02 14:23:36,377 [INFO] +127.0.0.1 agent-1
2016-03-02 14:23:36,377 [INFO] Adding other node entries
2016-03-02 14:23:36,377 [INFO] +%sagent-0 agent-0
2016-03-02 14:23:36,377 [INFO] Changing hostname as agent-1...
2016-03-02 14:23:36,383 [INFO] Found /var/lib/rabbitmq/.erlang.cookie
2016-03-02 14:23:36,383 [INFO] Existing erlang cookie is r89sedkflri2s00q
2016-03-02 14:23:36,383 [INFO] Creating /etc/rabbitmq/rabbitmq.config
2016-03-02 14:23:36,383 [INFO] Found master node agent-0
2016-03-02 14:23:36,384 [INFO] Master node agent-0 detected, connecting to master...
use an environment variable to pass the marathon endpoint address to rabbitmq_cluster, now leader.mesos:8080 is hardcoded that makes image mesos-dns dependent.
Hey!
Thanks for this project, I have a small improvement suggestion, if some node in cluster will go down, it will remain in cluster status as not running, and if there will be huge number of nodes which from time to time scale up/scale down, there will be a lot of them. So I guess it would be useful to make some functionality which will be triggered on node startup to remove dead nodes. From rabbitmq docs I only see one possible way to do this with: rabbitmqctl forget_cluster_node rabbit@rabbit1
Currently the bootstrapper file rabbitmq-cluster.py searches for other nodes by queruing Marathon tasks whose createdAt is not null. This does not work correctly when the service is pushed to Marathon, as both nodes are in staging state and thus don't find each others.
Hi !
Using your script, we encountered issues: zombie processes are spawned until the nproc ulimit is exceeded.
Maybe this is a docker issue: https://github.com/habitat-sh/core-plans/issues/1099
to deal with partitioning problems.
I had first tried this image with pre-existing /var/lib/rabbitmq volumes.
Then I realized, it does not work with empty /var/lib/rabbitmq folders, but I didn't investigate what causing problem yet, please send a pull request if you act faster then me.
I am just diving into Mesos/Marathon/Docker and your docker image is great. I would love to see the app's json mesos configuration if possible.
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.