From f036c84ac3bb0cdfbc06e966684d727f07c79540 Mon Sep 17 00:00:00 2001 From: Giovanni Toraldo Date: Tue, 19 Dec 2023 09:53:09 +0100 Subject: [PATCH] Fix nodeSelector configuration --- charts/alfresco-repository/Chart.yaml | 2 +- charts/alfresco-repository/README.md | 2 +- charts/alfresco-repository/templates/deployment.yaml | 4 +--- charts/alfresco-repository/tests/deployment_test.yaml | 11 +++++++++++ 4 files changed, 14 insertions(+), 5 deletions(-) diff --git a/charts/alfresco-repository/Chart.yaml b/charts/alfresco-repository/Chart.yaml index 65c16e74..da33670b 100644 --- a/charts/alfresco-repository/Chart.yaml +++ b/charts/alfresco-repository/Chart.yaml @@ -2,7 +2,7 @@ apiVersion: v2 name: alfresco-repository description: Alfresco content repository Helm chart type: application -version: 0.1.1 +version: 0.1.2 appVersion: 23.1.1 dependencies: - name: alfresco-common diff --git a/charts/alfresco-repository/README.md b/charts/alfresco-repository/README.md index 9c51051c..81d0f7ef 100644 --- a/charts/alfresco-repository/README.md +++ b/charts/alfresco-repository/README.md @@ -1,6 +1,6 @@ # alfresco-repository -![Version: 0.1.1](https://img.shields.io/badge/Version-0.1.1-informational?style=flat-square) ![Type: application](https://img.shields.io/badge/Type-application-informational?style=flat-square) ![AppVersion: 23.1.1](https://img.shields.io/badge/AppVersion-23.1.1-informational?style=flat-square) +![Version: 0.1.2](https://img.shields.io/badge/Version-0.1.2-informational?style=flat-square) ![Type: application](https://img.shields.io/badge/Type-application-informational?style=flat-square) ![AppVersion: 23.1.1](https://img.shields.io/badge/AppVersion-23.1.1-informational?style=flat-square) Alfresco content repository Helm chart diff --git a/charts/alfresco-repository/templates/deployment.yaml b/charts/alfresco-repository/templates/deployment.yaml index fbfae747..fa1907a4 100644 --- a/charts/alfresco-repository/templates/deployment.yaml +++ b/charts/alfresco-repository/templates/deployment.yaml @@ -22,8 +22,6 @@ spec: spec: serviceAccountName: {{ include "alfresco-repository.serviceAccountName" . }} {{- include "alfresco-common.component-pod-security-context" .Values | indent 4 }} - nodeSelector: - {{- toYaml .Values.nodeSelector | nindent 8 }} {{- include "alfresco-common.imagePullSecrets" . | indent 6 }} initContainers: - name: wait-db-ready @@ -221,7 +219,7 @@ spec: terminationGracePeriodSeconds: {{ .Values.terminationGracePeriod }} {{- with .Values.nodeSelector }} nodeSelector: - {{- toYaml . | indent 8 }} + {{- toYaml . | nindent 8 }} {{- end }} {{- with .Values.affinity }} affinity: diff --git a/charts/alfresco-repository/tests/deployment_test.yaml b/charts/alfresco-repository/tests/deployment_test.yaml index be83f6a8..3a3c4a56 100644 --- a/charts/alfresco-repository/tests/deployment_test.yaml +++ b/charts/alfresco-repository/tests/deployment_test.yaml @@ -206,3 +206,14 @@ tests: path: spec.template.spec.containers count: 2 template: deployment.yaml + + - it: should allow setting nodeSelector properly + values: *test_values + set: + nodeSelector: + node_label: node_value + asserts: + - equal: + path: spec.template.spec.nodeSelector.node_label + value: node_value + template: deployment.yaml