-
Notifications
You must be signed in to change notification settings - Fork 218
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
feat(helm): add option to set resources for initHelper #865
feat(helm): add option to set resources for initHelper #865
Conversation
Signed-off-by: Guilherme Oki <[email protected]>
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.
Hi @guilhermeoki. Thank you for your contribution. Please see my inline comment.
Also, I know you only added the resources part, but could you please add the entire initHelper struct to the values.yaml
of the chart to show that it is possible to set it?
{{- if .Values.opensearchCluster.initHelper.resources }} | ||
resources: | ||
{{- if .Values.opensearchCluster.initHelper.resources.requests }} | ||
requests: | ||
{{- if .Values.opensearchCluster.initHelper.resources.requests.memory }} | ||
memory: {{ .Values.opensearchCluster.initHelper.resources.requests.memory }} | ||
{{- end }} | ||
{{- if .Values.opensearchCluster.initHelper.resources.requests.cpu }} | ||
cpu: {{ .Values.opensearchCluster.initHelper.resources.requests.cpu }} | ||
{{- end }} | ||
{{- end }} | ||
{{- if .Values.opensearchCluster.initHelper.resources.limits }} | ||
limits: | ||
{{- if .Values.opensearchCluster.initHelper.resources.limits.memory }} | ||
memory: {{ .Values.opensearchCluster.initHelper.resources.limits.memory }} | ||
{{- end }} | ||
{{- if .Values.opensearchCluster.initHelper.resources.limits.cpu }} | ||
cpu: {{ .Values.opensearchCluster.initHelper.resources.limits.cpu }} | ||
{{- end }} | ||
{{- end }} | ||
{{- end }} |
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 could be simplified like this:
{{- if .Values.opensearchCluster.initHelper.resources }}
resources:
{{- toYaml .Values.opensearchCluster.initHelper.resources | nindent 6 }}
{{- end }}
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.
Also, I know you only added the resources part, but could you please add the entire initHelper struct to the values.yaml of the chart to show that it is possible to set it?
Sure! I will add the struct to the values.yaml
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 could be simplified like this:
Ok! I will simplify that part.
Signed-off-by: Guilherme Oki <[email protected]>
eaad80a
to
c4269ab
Compare
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.
Not sure why the test fails, when I run it locally it passes, so not a problem with your code.
I'll merge it anyway.
…oject#865) ### Description This PR adds an option to define resources for initHelper container. ### Issues Resolved Closes this issue opensearch-project#866 ### Check List - [X] Commits are signed per the DCO using --signoff - [X] Unittest added for the new/changed functionality and all unit tests are successful - [X] Customer-visible features documented - [X] No linter warnings (`make lint`) By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license. For more information on following Developer Certificate of Origin and signing off your commits, please check [here](https://github.com/opensearch-project/OpenSearch/blob/main/CONTRIBUTING.md#developer-certificate-of-origin). --------- Signed-off-by: Guilherme Oki <[email protected]>
…oject#865) ### Description This PR adds an option to define resources for initHelper container. ### Issues Resolved Closes this issue opensearch-project#866 ### Check List - [X] Commits are signed per the DCO using --signoff - [X] Unittest added for the new/changed functionality and all unit tests are successful - [X] Customer-visible features documented - [X] No linter warnings (`make lint`) By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license. For more information on following Developer Certificate of Origin and signing off your commits, please check [here](https://github.com/opensearch-project/OpenSearch/blob/main/CONTRIBUTING.md#developer-certificate-of-origin). --------- Signed-off-by: Guilherme Oki <[email protected]>
…oject#865) ### Description This PR adds an option to define resources for initHelper container. ### Issues Resolved Closes this issue opensearch-project#866 ### Check List - [X] Commits are signed per the DCO using --signoff - [X] Unittest added for the new/changed functionality and all unit tests are successful - [X] Customer-visible features documented - [X] No linter warnings (`make lint`) By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license. For more information on following Developer Certificate of Origin and signing off your commits, please check [here](https://github.com/opensearch-project/OpenSearch/blob/main/CONTRIBUTING.md#developer-certificate-of-origin). --------- Signed-off-by: Guilherme Oki <[email protected]> Signed-off-by: rkthtrifork <[email protected]>
Description
This PR adds an option to define resources for initHelper container.
Issues Resolved
Closes this issue #866
Check List
make lint
)By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license.
For more information on following Developer Certificate of Origin and signing off your commits, please check here.