<p>I want my pods to receive multicast network traffic flowing from outside of my kubernetes cluster to specific ports in my nodes.</p>

<p>I'm considering two solutions:</p>

<ol>
<li>Adding <code>hostNetwork: true</code> flag to their <code>yaml</code> file along with <code>hostPort</code> configuration in order to receive the traffic directly to the pod.</li>
<li>Forwarding the traffic locally on the nodes from <code>eth0</code> interface to <code>docker0</code> interface using <code>iptables</code> command.</li>
</ol>

<p>Method 1 is an official feature in Kubernetes, but it feels like breaking a security wall that docker originally imposed, and might cause port 
collisions with host's processes, etc.  </p>

<p>Method 2 on the other hand transparently forwards the multicast network traffic to the pods.<br>
Despite the fact I can use an automation tool to spread this configuration (ansible/salt etc), anything configured 'out of the scope' of Kubernetes feels a little hacky to me.</p>

<p>Would like to hear your pros and cons, comments, and maybe other solutions to the problem of multicasting to a kubernetes cluster.</p>

<p>A cleaner way to support multicast is to add an additional interface to your PODs through <code>multus-cni</code>. Then, you could associate this new <code>multus</code> interface to your host network interface that will receive multicast traffic on the host. Summarizing, you will have two interface on your POD i.e:</p>
<ol>
<li><code>net1</code> (default) for pod-to-pod communication and other unicast traffic.</li>
<li><code>eth0</code> (multus) for multicast traffic. Then you will need to &quot;join&quot; it with a NIC in your host machine, either by using <code>bridge</code> or <code>macvlan</code></li>
</ol>
<p>See more details here: <a href="https://github.com/intel/multus-cni/blob/master/docs/quickstart.md" rel="nofollow noreferrer">https://github.com/intel/multus-cni/blob/master/docs/quickstart.md</a></p>
