从eth0转发到docker0 [英] forward udp multicast from eth0 to docker0
问题描述
是否有一种方法可以让码头自动拿起这些数据包并将其转发到容器?
谢谢
经过很多令人沮丧的日子,尝试了一些事情...终于有一些工作:
使用Pipework( https://github.com/jpetazzo/pipework),以下命令工作,但有一个catch -
管道eth2 $(docker run -d hipache / usr / sbin / hipache)50.19.169.157/24
只运行上述命令运行docker容器并不完全帮我。我必须在我的主机上运行 tcpdump -i eth2
来捕获eth2接口上的数据包,然后它开始将数据包转发到docker容器。
任何想法为什么工作而不只是运行命令??
I have a docker container running a java application which is listening for UDP multicast packets. I am not receiving the packets inside the container, however they appear on the host machine on eth0.
Is there a way for docker to automatically pick up these packets and forward them to the container?
Thanks
After a lot of frustrating days of trying out a number of things... finally something worked:
Using Pipework (https://github.com/jpetazzo/pipework), the following command worked but there is a catch -
pipework eth2 $(docker run -d hipache /usr/sbin/hipache) 50.19.169.157/24
running a docker container by only running the above command did not quite help me. I had to run tcpdump -i eth2
on my host to capture packets on eth2 interface, which then started to forward the packets to the docker container.
Any idea why is worked and not just running the command??
这篇关于从eth0转发到docker0的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!