Skip to content
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

fix: Modify conversion webhook check to check for v1 version existence #1914

Conversation

jonathan-innis
Copy link
Member

@jonathan-innis jonathan-innis commented Jan 14, 2025

Fixes #N/A

Description

This change updates the conversion webhook check that we added to the latest pre-v1.0 patch versions so that we crash when we have an issue calling the v1 conversion endpoint converting from v1beta1, not when we get any error -- this allows the v1 CRD to be deployed after the application is deployed.

This also logs errors if we get any unknown errors when calling this API just in case there are errors that we are getting in this health check that are unexpected and we don't see.

This also ensures that this health check will continually fire throughout the lifetime of the process so that if the CRD is updated and deployed later after the application is deployed or if the NodePools aren't deployed until after the process is started, the check continues to be executed.

We also need to ensure that we don't fail immediately when we restart the container so that we give an unhealthy container a chance to become healthy again -- if a Karpenter container was crahsing with a blocked network path to the conversion webhook and that network path has now opened back up again -- we need to allow for that container to go back to ready -- we can make that happen by ensuring that we don't crash on the first failure but checking that we have consecutive failures.

How was this change tested?

make presubmit

By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license.

@k8s-ci-robot k8s-ci-robot added the cncf-cla: yes Indicates the PR's author has signed the CNCF CLA. label Jan 14, 2025
@k8s-ci-robot
Copy link
Contributor

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: jonathan-innis

The full list of commands accepted by this bot can be found here.

The pull request process is described here

Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@k8s-ci-robot k8s-ci-robot added approved Indicates a PR has been approved by an approver from all required OWNERS files. size/M Denotes a PR that changes 30-99 lines, ignoring generated files. labels Jan 14, 2025
@jonathan-innis jonathan-innis force-pushed the modify-conversion-webhook-check branch from 6bb735e to 2e949b2 Compare January 14, 2025 23:56
@jonathan-innis jonathan-innis force-pushed the modify-conversion-webhook-check branch 2 times, most recently from 0d81d83 to 0e525f7 Compare January 15, 2025 00:28
@jonathan-innis jonathan-innis force-pushed the modify-conversion-webhook-check branch from 0e525f7 to c97a838 Compare January 15, 2025 01:15
@jmdeal
Copy link
Member

jmdeal commented Jan 15, 2025

/lgtm
/hold

@k8s-ci-robot k8s-ci-robot added the do-not-merge/hold Indicates that a PR should not merge because someone has issued a /hold command. label Jan 15, 2025
@k8s-ci-robot k8s-ci-robot added the lgtm "Looks good to me", indicates that a PR is ready to be merged. label Jan 15, 2025
@jonathan-innis
Copy link
Member Author

/unhold No more changes required from my side

@jonathan-innis
Copy link
Member Author

/unhold

@k8s-ci-robot k8s-ci-robot removed the do-not-merge/hold Indicates that a PR should not merge because someone has issued a /hold command. label Jan 15, 2025
@k8s-ci-robot k8s-ci-robot merged commit 9fc1bbe into kubernetes-sigs:release-v0.37.x Jan 15, 2025
12 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
approved Indicates a PR has been approved by an approver from all required OWNERS files. cncf-cla: yes Indicates the PR's author has signed the CNCF CLA. lgtm "Looks good to me", indicates that a PR is ready to be merged. size/M Denotes a PR that changes 30-99 lines, ignoring generated files.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants