-
Notifications
You must be signed in to change notification settings - Fork 30
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Make control plane endpoint default registration method #418
Make control plane endpoint default registration method #418
Conversation
e6f28a0
to
91a895d
Compare
This needs an update as discussed offline with @Danil-Grigorev, please hold off merging it manually. |
Signed-off-by: Danil-Grigorev <danil.grigorev@suse.com>
cfc1e1c
cfc1e1c
to
081d34a
Compare
Signed-off-by: Danil-Grigorev <danil.grigorev@suse.com>
533d7c7
to
137e293
Compare
Upon checking crust-gather archive after test run, it seems the field is emptied, as expected. Just added e2e tests after all, leaving the rest of the logic unchanged. Should be good to merge now @furkatgofurov7 @salasberryfin, as this addressed my concern. spec:
agentConfig:
additionalUserData: {}
format: cloud-config
nodeAnnotations:
test: 'true'
infrastructureRef:
apiVersion: infrastructure.cluster.x-k8s.io/v1beta1
kind: DockerMachineTemplate
name: caprke2-e2e-yqwygg-control-plane
machineTemplate:
infrastructureRef: {}
metadata: {}
manifestsConfigMapReference: {}
nodeDrainTimeout: 30s
privateRegistriesConfig: {}
replicas: 1
rolloutStrategy:
rollingUpdate:
maxSurge: 1
type: RollingUpdate
serverConfig:
disableComponents:
kubernetesComponents:
- cloudController
etcd:
backupConfig: {}
version: v1.28.12+rke2r1
status:
… |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
If I read this correctly, an empty registrationMethod
value is now equivalent to control-plane-endpoint
, but it allows replacement, which should solve indeed my original issue.
I still wonder however if this is going to create race conditions, what if I don't want to use the control-plane-endpoint
as registration method, but I want to directly use an address and input that address as variable in a cluster class? I don't see any example of this in the PR.
I wonder if it's possible to put the control plane on "pause" until the registrationMethod
is populated, but this seems to be an improvement.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM, lets wait and see if @furkatgofurov7 has any other concerns
@@ -44,6 +44,23 @@ providers: | |||
new: "--leader-elect=false" | |||
- old: --metrics-addr=127.0.0.1:8080 | |||
new: --metrics-addr=:8080 | |||
- name: docker-updated |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I would be in favor of not duplicating this since it is a one liner less compared to the original cluster template we have in the repo, however, it looks like bigger of a change to achieve this (using jinja templating or Go's templating capabilites) vs benefits it brings.
What this PR does / why we need it:
Fixes: #343
From the list of available registration methods, control plane one seems to be the most suitable for a default. It will not work for all cases, but for those which do, namely clusters without restrictions on accessing public API and address of CP endpoint, this should work out of the box as a quickstart method.
Users may decide to define a different registrationMethod, where one edit of the value is intentionally allowed.
Which issue(s) this PR fixes (optional, in
fixes #<issue number>(, fixes #<issue_number>, ...)
format, will close the issue(s) when PR gets merged):Fixes #
Special notes for your reviewer:
Checklist: