-
Notifications
You must be signed in to change notification settings - Fork 83
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 helm chart syntax errors #533
🐛 Fix helm chart syntax errors #533
Conversation
✅ Deploy Preview for kubernetes-sigs-cluster-api-operator ready!
To edit notification comments on pull requests, go to your Netlify site configuration. |
@@ -45,7 +45,7 @@ spec: | |||
{{- end }} | |||
{{- if $.Values.manager }} | |||
manager: | |||
{{- if $.Values.manager.featureGates.core }} | |||
{{- if and $.Values.manager.featureGates $.Values.manager.featureGates.core }} |
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.
Fixes nil pointer exception if manager is defined but not manager.featureGates
@@ -38,15 +38,15 @@ metadata: | |||
annotations: | |||
"helm.sh/hook": "post-install" | |||
"helm.sh/hook-weight": "2" | |||
{{- if or $infrastructureVersion $.Values.configSecret.name }} | |||
{{- if or $infrastructureVersion $.Values.configSecret.name $.Values.manager }} |
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.
This fixes a bug where spec:
is not printed when infrastructureVersion .Values.configSecret.name are not specified and Values.manager is.
spec: | ||
{{- end }} | ||
{{- if $infrastructureVersion }} | ||
version: {{ $infrastructureVersion }} | ||
{{- end }} | ||
{{- if $.Values.manager }} | ||
manager: | ||
{{- if hasKey $.Values.manager.featureGates $infrastructureName }} | ||
{{- if and (kindIs "map" $.Values.manager.featureGates) (hasKey $.Values.manager.featureGates $infrastructureName) }} |
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.
This fixes a type check error if $.Values.manager.featureGates is not specified.
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
LGTM label has been added. Git tree hash: dd57901978af6ad5b4553b19b357a2d5518616ac
|
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
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.
thanks a lot for fixing this
/approve
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: alexander-demicev 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 |
What this PR does / why we need it:
This PR fixes a few edge cases that cause syntax errors in helm charts.
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 part of #532