EMQX在Docker上的多设备集群

huangapple go评论73阅读模式
英文:

EMQX on docker-multiple device cluster

问题

我正在尝试在许多不同的机器上运行EQMX Docker镜像并建立一个集群。我已经尝试过使用静态列表方法和DNS发现方法。他们在同一个网络下,但由于Docker创建了自己的网络,它们无法看到彼此。如何在不在机器上安装EQMX的情况下组建一个集群?如何让Docker不将容器连接到虚拟网络?我是否应该发布某个特定端口,以使容器彼此可见?

英文:

I'm trying to run EQMX docker image on many different machines and build a cluster with them. I have tried using the static list method and the dns discovery method.

They are under the same network but because docker creates its own network they dont see each other. How can I make a cluster out of them without installing EQMX on the machine itself? How can I make docker not attach the container to a virtual network? Should I publish a certain port so that the containers are visible to each other?

答案1

得分: 1

以下是要翻译的部分:

The solution ended up being to expose the container to the host network --network="host" and defining EMQX auto clustering to use mcast.
After that got an error similar to Cannot get connection id for node that ended up being related to the node name that did not have the proper format <name>@<IP address>

英文:

The solution ended up being to expose the container to the host network --network=&quot;host&quot; and defining EMQX auto clustering to use mcast.
After that got an error similar to Cannot get connection id for node that ended up being related to the node name that did not have the proper format &lt;name&gt;@&lt;IP address&gt;

huangapple
  • 本文由 发表于 2023年4月11日 03:05:09
  • 转载请务必保留本文链接:https://go.coder-hub.com/75979924.html
匿名

发表评论

匿名网友

:?: :razz: :sad: :evil: :!: :smile: :oops: :grin: :eek: :shock: :???: :cool: :lol: :mad: :twisted: :roll: :wink: :idea: :arrow: :neutral: :cry: :mrgreen:

确定