Add kubelet serving certificate readiness example - #365
Conversation
✅ Deploy Preview for node-readiness-controller ready!
To edit notification comments on pull requests, go to your Netlify project configuration. |
|
[APPROVALNOTIFIER] This PR is NOT APPROVED This pull-request has been approved by: arnab-logs The full list of commands accepted by this bot can be found here. DetailsNeeds approval from an approver in each of these files:Approvers can indicate their approval by writing |
|
@arnab-logs: The following test failed, say
Full PR test history. Your PR dashboard. Please help us cut down on flakes by linking to an open issue when you hit one in your PR. DetailsInstructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes-sigs/prow repository. I understand the commands that are listed here. |
|
Looks like the prow job failed on the docs link check. I verified the files are present in this PR and the failure seems to be because the links point to main where these new files don't exist yet |
This PR adds a new example demonstrating how to use NRC to prevent workloads from scheduling on a node until kubelet has obtained its TLS serving certificate.
Includes:
examples/kubelet-cert-readiness/: kind cluster config and manifests (RBAC, NPD ConfigMaps, NPD DaemonSet, NodeReadinessRule)docs/book/src/examples/kubelet-cert-readiness.md: mdBook documentation pagedocs/book/src/SUMMARY.md: adds the new page to the site navigationUse Case
This is in reference to a slack discussion raised in the NRC community. When a node is marked
Ready,kubectl execandkubectl logsmay still fail because kubelet has not yet received its TLS serving certificate, the certificate is issued separately via a CSR and its approval can be delayed on some providers.This causes visible failures in CI/CD environments: GitLab Runner marks jobs as failed when it cannot exec into pods on a new node, and Fluentbit fails to collect logs from kubelet before the certificate is in place.
How to test
Create kind cluster
Install the CRDs and Controller
See the Installation Guide for details
Deploy the Example
Check the startup taint is applied
Check the node condition
Approve the worker's pending CSR to simulate the certificate being issued
kubectl get csr # find the entry with SIGNERNAME kubernetes.io/kubelet-serving and REQUESTOR system:node:<worker-name> kubectl certificate approve <worker-csr-name>Check the condition again
Check taint removal
Confirm
kubectl execworks