Give each kops-controller controller unique names #16812
Merged
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
This makes progress on fixing ipv6 support.
For IPV6 clusters we enable an ipam controller in kops-controller:
kops/pkg/apis/kops/cluster.go
Lines 949 to 951 in 423b640
kops/upup/pkg/fi/cloudup/template_functions.go
Lines 774 to 776 in 423b640
kops/cmd/kops-controller/main.go
Lines 221 to 227 in 423b640
controller-runtime's manager picks "names" for each controller it manages, and defaults to the
kind
it watches:https://github.com/kubernetes-sigs/controller-runtime/blob/38546806f2faf5973e3321a7bd5bb3afdbb5767d/pkg/builder/controller.go#L247-L257
This means that alongside the node bootstrap controller, there are multiple controllers watching nodes. This results in a conflict which causes kops-controller to crash loop:
This PR gives each controller a unique name to avoid the conflict.