Skip to content
This repository has been archived by the owner on Apr 25, 2019. It is now read-only.

Public subnets as variable #15

Open
edahlseng opened this issue Dec 27, 2017 · 3 comments
Open

Public subnets as variable #15

edahlseng opened this issue Dec 27, 2017 · 3 comments

Comments

@edahlseng
Copy link

It appears that there's no way to specify public subnets for reuse with the cluster -- only new subnets can be created. It would be awesome if public subnets could be specified directly, overriding the creation of new resources.

@FutureSharks
Copy link
Owner

Hi Eric!
This is by design. Public subnets cannot be shared between clusters and must be created per cluster. This is because when Kubernetes creates ELBs for a Loadbalancer services, it looks for subnets that have the KubernetesCluster tag containing the cluster FQDN.

Make sense?

Thanks,
Max

@edahlseng
Copy link
Author

edahlseng commented Dec 28, 2017

Hi Max,

Thanks for the information. I'm still getting up to speed with all of the details and nuances of Kubernetes and kops.

Looking at Kubernetes documentation for running in existing VPCs, however, it appears that there's an option to specify the utility (public) subnets for the cluster? Though maybe this is only available in kops 1.8?

@FutureSharks
Copy link
Owner

So that is interesting, they have changed the behaviour in version 1.8:

This is important, for example, if your utility subnets are shared, you will not be able to launch any services that create Elastic Load Balancers (ELBs). Prior to kops 1.8 KubernetesCluster tag was used for this. This lead to several problems if there were more than one Kubernetes Cluster in a subnet. After you upgraded to kops 1.8 remove KubernetesCluster Tag from subnets otherwise kubernetes.io/cluster/<clustername> won't have any effect!

I'll have to rewrite the subnet stuff for this. Basically the subnets would have to be removed from the module, created outside the module and then tags added for each k8s cluster that would use the shared subnets.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants