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

[bitnami/common] Capabilities to return latest apiVersion if kubeVersion is undefined #26758

Merged
merged 4 commits into from
Jun 5, 2024

Conversation

juan131
Copy link
Contributor

@juan131 juan131 commented Jun 5, 2024

Description of the change

This PR ensures we return the latest known apiVersion for a given K8s object if common.capabilities.kubeVersion is unable to obtain the kubeVersion (e.g. using helm template with both global.kubeVersion and kubeVersion values unset).

Benefits

We should assume the latest kubernetes version as the target when it's undefined.

Possible drawbacks

Users using helm template (or ArgoCD and other CD tools that use helm templating engine under the hood) that aren't setting global.kubeVersion nor kubeVersion may experience a change in their K8s objects' apiVersion.

Applicable issues

None

Additional information

N/A

Checklist

  • Chart version bumped in Chart.yaml according to semver. This is not necessary when the changes only affect README.md files.
  • Title of the pull request follows this pattern [bitnami/<name_of_the_chart>] Descriptive title
  • All commits signed off and in agreement of Developer Certificate of Origin (DCO)

Sorry, something went wrong.

juan131 added 2 commits June 5, 2024 10:50

Unverified

This commit is not signed, but one or more authors requires that any commit attributed to them is signed.
…ion is undefined

Signed-off-by: juan131 <jariza@vmware.com>

Unverified

This commit is not signed, but one or more authors requires that any commit attributed to them is signed.
Signed-off-by: juan131 <jariza@vmware.com>
@juan131 juan131 requested review from javsalgar and carrodher June 5, 2024 08:56
@github-actions github-actions bot added the common label Jun 5, 2024
@bitnami-bot bitnami-bot added the verify Execute verification workflow for these changes label Jun 5, 2024
@github-actions github-actions bot requested a review from dgomezleon June 5, 2024 08:56
Signed-off-by: Bitnami Containers <bitnami-bot@vmware.com>
Copy link
Contributor

@javsalgar javsalgar left a comment

Choose a reason for hiding this comment

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

LGTM! Small suggestion

Signed-off-by: juan131 <jariza@vmware.com>
@juan131 juan131 requested a review from javsalgar June 5, 2024 09:08
@juan131 juan131 enabled auto-merge (squash) June 5, 2024 09:09
@juan131 juan131 merged commit 6582c32 into bitnami:main Jun 5, 2024
8 checks passed
@github-actions github-actions bot added the solved label Jun 5, 2024
@juan131 juan131 deleted the feat/common-capabilities branch June 5, 2024 09:13
Copy link
Collaborator

@fmulero fmulero left a comment

Choose a reason for hiding this comment

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

LGTM

{{- if .Values.ingress -}}
{{- if .Values.ingress.apiVersion -}}
{{- $kubeVersion := include "common.capabilities.kubeVersion" . -}}
{{- if (.Values.ingress).apiVersion -}}
Copy link
Collaborator

Choose a reason for hiding this comment

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

Nice hack! I take note 📝

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bitnami common solved verify Execute verification workflow for these changes
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

5 participants