Skip to content

Conversation

iuriaranda
Copy link
Contributor

@iuriaranda iuriaranda commented Aug 20, 2025

Please ensure your pull request adheres to the following guidelines:

  • For first time contributors, read Submitting a pull request
  • All code is covered by unit and/or runtime tests where feasible.
  • All commits contain a well written commit description including a title,
    description and a Fixes: #XXX line if the commit addresses a particular
    GitHub issue.
  • If your commit description contains a Fixes: <commit-id> tag, then
    please add the commit author[s] as reviewer[s] to this issue.
  • All commits are signed off. See the section Developer’s Certificate of Origin
  • Provide a title or release-note blurb suitable for the release notes.
  • Are you a user of Cilium? Please add yourself to the Users doc
  • Thanks for contributing!

In some edge-case scenarios, the chart gets installed before the cluster info ConfigMap has been created or populated. In such cases cilium gets deployed with an erroneous value ("auto") as the k8s service host and fails to start. The helm install operation won't fail immediately, but it will timeout eventually and get rolled back. This makes remediation difficult, specially with large install timeouts, which are often used on larger clusters.

With this change, if the k8s host auto discovery is requested in the chart values (by setting "auto" in .Values.k8sServiceHost), the chart will immediately fail to get installed if it can't find the cluster info ConfigMap, and the installer will be forced to retry the chart installation.

@iuriaranda iuriaranda requested review from a team as code owners August 20, 2025 07:11
@maintainer-s-little-helper
Copy link

Commit edd681e does not match "(?m)^Signed-off-by:".

Please follow instructions provided in https://docs.cilium.io/en/stable/contributing/development/contributing_guide/#developer-s-certificate-of-origin

@maintainer-s-little-helper maintainer-s-little-helper bot added dont-merge/needs-sign-off The author needs to add signoff to their commits before merge. dont-merge/needs-release-note-label The author needs to describe the release impact of these changes. labels Aug 20, 2025
@github-actions github-actions bot added the kind/community-contribution This was a contribution made by a community member. label Aug 20, 2025
@iuriaranda iuriaranda force-pushed the fix-k8shost-autodiscovery branch from edd681e to ba407eb Compare August 20, 2025 07:13
@maintainer-s-little-helper maintainer-s-little-helper bot removed the dont-merge/needs-sign-off The author needs to add signoff to their commits before merge. label Aug 20, 2025
Copy link
Member

@gandro gandro left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thaks for the PR! This looks reasonable to me. I have one optional suggestion

@gandro gandro added release-note/misc This PR makes changes that have no direct user impact. area/helm Impacts helm charts and user deployment experience labels Aug 20, 2025
@maintainer-s-little-helper maintainer-s-little-helper bot removed the dont-merge/needs-release-note-label The author needs to describe the release impact of these changes. label Aug 20, 2025
@maintainer-s-little-helper
Copy link

Commit 37dff97 does not match "(?m)^Signed-off-by:".

Please follow instructions provided in https://docs.cilium.io/en/stable/contributing/development/contributing_guide/#developer-s-certificate-of-origin

@maintainer-s-little-helper maintainer-s-little-helper bot added the dont-merge/needs-sign-off The author needs to add signoff to their commits before merge. label Aug 20, 2025
@iuriaranda iuriaranda force-pushed the fix-k8shost-autodiscovery branch from 37dff97 to f61ea1b Compare August 20, 2025 12:46
@maintainer-s-little-helper
Copy link

Commit 37dff97 does not match "(?m)^Signed-off-by:".

Please follow instructions provided in https://docs.cilium.io/en/stable/contributing/development/contributing_guide/#developer-s-certificate-of-origin

@maintainer-s-little-helper
Copy link

Commit 3312483 does not match "(?m)^Signed-off-by:".

Please follow instructions provided in https://docs.cilium.io/en/stable/contributing/development/contributing_guide/#developer-s-certificate-of-origin

@iuriaranda iuriaranda force-pushed the fix-k8shost-autodiscovery branch from 3312483 to f61ea1b Compare August 20, 2025 12:50
@maintainer-s-little-helper maintainer-s-little-helper bot removed the dont-merge/needs-sign-off The author needs to add signoff to their commits before merge. label Aug 20, 2025
@iuriaranda iuriaranda force-pushed the fix-k8shost-autodiscovery branch from f61ea1b to 9127bc3 Compare August 20, 2025 12:50
Copy link
Member

@gandro gandro left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks! Would you mind squashing the two commits into one? Then I'll run CI to get this merged

In some edge-case scenarios, the chart gets installed before the cluster info ConfigMap has been created or populated. In such cases cilium gets deployed with an erroneous value ("auto") as the k8s service host and fails to start. The helm install operation won't fail immediately, but it will timeout eventually and get rolled back. This makes remediation difficult, specially with large install timeouts, which are often used on larger clusters.

With this change, if the k8s host auto discovery is requested in the chart values (by setting "auto" in `.Values.k8sServiceHost`), the chart will immediately fail to get installed if it can't find the cluster info ConfigMap, and the installer will be forced to retry the chart installation.

Signed-off-by: iuri aranda <iuri@giantswarm.io>
@iuriaranda iuriaranda force-pushed the fix-k8shost-autodiscovery branch from 9127bc3 to f826c41 Compare August 20, 2025 13:15
@iuriaranda
Copy link
Contributor Author

Thanks! Would you mind squashing the two commits into one? Then I'll run CI to get this merged

sure, done

@gandro
Copy link
Member

gandro commented Aug 20, 2025

/test

@gandro gandro enabled auto-merge August 21, 2025 06:48
@iuriaranda
Copy link
Contributor Author

I see some failed checks, although I doubt it's because of the changes. Do we need to re-run the CI?

@gandro
Copy link
Member

gandro commented Aug 21, 2025

I've restarted them, thanks for the heads-up! I believe only organization members can trigger/restart CI.

@gandro gandro added this pull request to the merge queue Aug 21, 2025
@maintainer-s-little-helper maintainer-s-little-helper bot added the ready-to-merge This PR has passed all tests and received consensus from code owners to merge. label Aug 21, 2025
Merged via the queue into cilium:main with commit 6417706 Aug 21, 2025
68 checks passed
@iuriaranda iuriaranda deleted the fix-k8shost-autodiscovery branch August 21, 2025 08:45
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area/helm Impacts helm charts and user deployment experience kind/community-contribution This was a contribution made by a community member. ready-to-merge This PR has passed all tests and received consensus from code owners to merge. release-note/misc This PR makes changes that have no direct user impact.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants