Multi-datacenter consul with kubernetes

Hello I’m having difficulties to set up a multi-datacenter consul cluster where the servers are inside the cluster. I have a kind of load balancer that send requests to the servers inside the clusters but the IPs of individual servers are not exposed only the load balancer IP. How is wan join supposed to work with k8s, do I need to expose the servers as nodeports and/or using hostport? I’m asking because the consul-helm is set to have the servers as headless but not exposed externally.

BTW, I was referred here from github to ask for questions but do not seem to get any answer to my questions so far.

Thanks

1 Like

Hi Filinto,
There’s no built-in way to the helm chart to make this work (at least right now). You can either use NodePort/HostPort’s or create a LoadBalancer for each server. If you create a LoadBalancer for each server, note that there will be errors in the logs that UDP isn’t working but Consul falls back to TCP so the join will still work.

1 Like

Watching this for future.