<p>I would like to deploy a kubernetes cluster with weave virtual network in a node that is behind a NAT. (for example, using a floating IP in openstack)</p>

<p>Here is an example:</p>

<p><em>Kube Master</em>: weave pod running here</p>

<ul>
<li>Internal IP: 192.168.0.10</li>
<li>External IP: 172.10.0.10</li>
</ul>

<p><em>Kube nodes (worker)</em></p>

<ul>
<li>Internal IP: 172.10.0.11</li>
</ul>

<p>The logs in the pod running on the kube node (worker) looks like the following:</p>

<pre><code>$ docker logs -f &lt;id-of-weaveworks/weave-kube&gt;
INFO: 2017/04/28 15:31:00.627655 Command line options: map[ipalloc-range:10.32.0.0/12 nickname:rpi3-kube status-addr:0.0.0.0:6782 docker-api: datapath:datapath http-addr:127.0.0.1:6784 ipalloc-init:consensus=3 no-dns:true port:6783 conn-limit:30]
INFO: 2017/04/28 15:31:00.628107 Communication between peers is unencrypted.
INFO: 2017/04/28 15:31:00.888331 Our name is 8e:0e:19:5d:4e:5e(rpi3-kube)
INFO: 2017/04/28 15:31:00.889315 Launch detected - using supplied peer list: [192.168.0.12 192.168.0.10 172.10.0.11]
INFO: 2017/04/28 15:31:00.890130 Checking for pre-existing addresses on weave bridge
INFO: 2017/04/28 15:31:00.903121 [allocator 8e:0e:19:5d:4e:5e] No valid persisted data
INFO: 2017/04/28 15:31:00.999661 [allocator 8e:0e:19:5d:4e:5e] Initialising via deferred consensus
INFO: 2017/04/28 15:31:01.001342 Sniffing traffic on datapath (via ODP)
INFO: 2017/04/28 15:31:01.004907 -&gt;[192.168.0.10:6783] attempting connection
INFO: 2017/04/28 15:31:01.005712 -&gt;[192.168.0.12:6783] attempting connection
INFO: 2017/04/28 15:31:01.007297 -&gt;[172.10.0.11:6783] attempting connection
INFO: 2017/04/28 15:31:01.010285 -&gt;[172.10.0.11:38918] connection accepted
INFO: 2017/04/28 15:31:01.019476 -&gt;[147.214.99.166:6783|8e:0e:19:5d:4e:5e(rpi3-kube)]: connection shutting down due to error: cannot connect to ourself
INFO: 2017/04/28 15:31:01.021265 -&gt;[147.214.99.166:38918|8e:0e:19:5d:4e:5e(rpi3-kube)]: connection shutting down due to error: cannot connect to ourself
INFO: 2017/04/28 15:31:01.042197 Listening for HTTP control messages on 127.0.0.1:6784
INFO: 2017/04/28 15:31:01.051546 Listening for metrics requests on 0.0.0.0:6782
INFO: 2017/04/28 15:33:08.225310 -&gt;[192.168.0.10:6783] error during connection attempt: dial tcp4 :0-&gt;192.168.0.10:6783: getsockopt: connection timed out
</code></pre>

<p>The kubernetes cluster is propperly configured and the advertise address is: 172.10.0.10</p>

<p>My current workaround is to fix the IPs of the nodes in the weave configuration file:</p>

<pre><code>wget https://git.io/weave-kube-1.6      
vim weave-kube-1.6  
</code></pre>

<p>and modify it with your IPs</p>

<pre><code>  containers:
    - name: weave
      env:
      - name: KUBE_PEERS
        value: "172.10.0.10 172.10.0.11"
</code></pre>
