From 774df645b2d37d9f3af76e62082e2909b7a60387 Mon Sep 17 00:00:00 2001 From: Stavros kois Date: Tue, 4 Oct 2022 14:59:47 +0300 Subject: [PATCH 1/3] fix(solr): add missing plainhost key in secret --- charts/common/Chart.yaml | 2 +- charts/common/templates/lib/dependencies/_solrInjector.tpl | 3 ++- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/charts/common/Chart.yaml b/charts/common/Chart.yaml index a6116daa..ea511799 100644 --- a/charts/common/Chart.yaml +++ b/charts/common/Chart.yaml @@ -15,4 +15,4 @@ maintainers: name: common sources: null type: library -version: 10.6.5 +version: 10.6.9 diff --git a/charts/common/templates/lib/dependencies/_solrInjector.tpl b/charts/common/templates/lib/dependencies/_solrInjector.tpl index ef98fc69..ea86d43a 100644 --- a/charts/common/templates/lib/dependencies/_solrInjector.tpl +++ b/charts/common/templates/lib/dependencies/_solrInjector.tpl @@ -22,7 +22,8 @@ data: {{- $solrPass = randAlphaNum 50 }} solr-password: {{ $solrPass | b64enc | quote }} {{- end }} - url: {{ ( printf "http://%v:%v@%v-solr:8983/%v" .Values.solr.solrUsername $solrPass .Release.Name .Values.solr.solrCores ) | b64enc | quote }} + url: {{ ( printf "http://%v:%v@%v-solr:8983/%v" .Values.solr.solrUsername $solrPass .Release.Name .Values.solr.solrCores ) | b64enc | quote }} + plainhost: {{ ( ( printf "%v-%v" .Release.Name "solr" ) ) | b64enc | quote }} type: Opaque {{- $_ := set .Values.solr "solrPassword" ( $solrPass | quote ) }} {{- $_ := set .Values.solr.url "plain" ( ( printf "%v-%v" .Release.Name "solr" ) | quote ) }} From 8542e1f02d518a30cf2ff0fa4a7af24ab1a76dff Mon Sep 17 00:00:00 2001 From: Stavros kois Date: Tue, 4 Oct 2022 15:04:33 +0300 Subject: [PATCH 2/3] add an extra if --- charts/common/templates/lib/controller/_prepare.tpl | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/charts/common/templates/lib/controller/_prepare.tpl b/charts/common/templates/lib/controller/_prepare.tpl index 9b0f4b20..3fb6c843 100644 --- a/charts/common/templates/lib/controller/_prepare.tpl +++ b/charts/common/templates/lib/controller/_prepare.tpl @@ -63,7 +63,7 @@ before chart installation. key: ping {{- end }} {{- if .Values.solr.enabled }} - - name: "SOLR_HOST" + - name: SOLR_HOST valueFrom: secretKeyRef: name: solrcreds @@ -72,6 +72,7 @@ before chart installation. value: "{{ .Values.solr.solrCores }}" - name: SOLR_ENABLE_AUTHENTICATION value: "{{ .Values.solr.solrEnableAuthentication }}" + {{- if eq .Values.solr.solrEnableAuthentication "yes" }} - name: SOLR_ADMIN_USERNAME value: "{{ .Values.solr.solrUsername }}" - name: SOLR_ADMIN_PASSWORD @@ -80,6 +81,7 @@ before chart installation. name: solrcreds key: solr-password {{- end }} + {{- end }} command: - "/bin/sh" - "-c" From ca09143a2505ddd5a03fdcfd883edeb5d07c26cd Mon Sep 17 00:00:00 2001 From: Stavros kois Date: Tue, 4 Oct 2022 15:09:24 +0300 Subject: [PATCH 3/3] quote find pattern --- .github/workflows/charts-lint-test.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/charts-lint-test.yaml b/.github/workflows/charts-lint-test.yaml index ff82b26d..5eaea520 100644 --- a/.github/workflows/charts-lint-test.yaml +++ b/.github/workflows/charts-lint-test.yaml @@ -96,4 +96,4 @@ jobs: - name: Run chart-testing (install) if: needs.lint.outputs.changed == 'true' - run: find ./ -type f -name *.yaml -exec sed -i 's/tccr.io/ghcr.io/gI' {} \; && ct install --config .github/ct-install.yaml + run: find ./ -type f -name "*.yaml" -exec sed -i 's/tccr.io/ghcr.io/gI' {} \; && ct install --config .github/ct-install.yaml