It should be possible to use Cluster Federation it its current state if you just want to create a Deployment resource that spans across two clusters. However, if you want a service that spans two or more clusters and want service discovery across them, there are some caveats:
1. As of Kubernetes v1.5.x, which is the latest stable release right now, Google CloudDNS and AWS Route53 are the only two DNS providers that are supported for cross-cluster service discovery. While `kube-dns` is used for cluster local services, these DNS providers are programmed for federated (cross-cluster) services. It is important to note that it is still possible to use these DNS providers with your local clusters. However, your service DNS entries will be globally visible to all the DNS servers on the public internet. Having said all that, CoreDNS[0] DNS provider support is coming in Kubernetes v1.6. ETA March, 22nd[1]. This will let you run your own DNS server for federated service discovery. 2. Federated Services today create a separate service shard in each underlying cluster in a federation. And to create DNS records for service discovery, federation depends on the load balancer addresses allocated by the cluster service shards. If you are on an on-prem environment and don't have a load balancer implementation for your provider, federation will probably not be able to create DNS entries for these services. 3. kubefed, as it was launched in v1.5, was alpha and had problems with clusters in on-prem environments. We have fixed almost all those known issues now and kubefed should be able to build a federation control plane using on-prem clusters when it is released as beta in v1.6. However, you should be able to deploy a federation control plane by hand today using Kelsey's tutorial[2]. Just skip the cluster provisioning step in the Bootrapping Tasks list. (Federation The Hard Way ;-)) [0] https://coredns.io/ [1] https://github.com/kubernetes/features/blob/master/release-1.6/release-1.6.md#16-release-schedule [2] https://github.com/kelseyhightower/kubernetes-cluster-federation On Monday, February 27, 2017 at 5:53:15 AM UTC-8, Qian Zhang wrote: > > And will there be a problem for service discovery (kube-dns) across the > two clusters in this case? > -- You received this message because you are subscribed to the Google Groups "Kubernetes user discussion and Q&A" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. To post to this group, send email to [email protected]. Visit this group at https://groups.google.com/group/kubernetes-users. For more options, visit https://groups.google.com/d/optout.
