From fe2501e942c1fd2b170c05556363f4be08cbd41f Mon Sep 17 00:00:00 2001 From: Emilien Devos <121870973+edevosc2c@users.noreply.github.com> Date: Fri, 22 Mar 2024 10:13:35 +0100 Subject: [PATCH] fix rm before git clone + fix volumes for geoserver-lb --- cadastrapp/Chart.yaml | 2 +- cadastrapp/templates/cadastrapp-depl.yaml | 2 +- geoserver-lb/Chart.yaml | 2 +- geoserver-lb/templates/geoserver-deploy.yaml | 2 +- geoserver-lb/templates/geoserver-lb-deploy.yaml | 11 ++++------- mviewer/Chart.yaml | 2 +- .../templates/_bootstrap-mviewer-configuration.tpl | 1 + 7 files changed, 10 insertions(+), 12 deletions(-) diff --git a/cadastrapp/Chart.yaml b/cadastrapp/Chart.yaml index efc0225..1bbcc7e 100644 --- a/cadastrapp/Chart.yaml +++ b/cadastrapp/Chart.yaml @@ -4,7 +4,7 @@ description: A Helm chart for deploying geOrchestra's cadastrapp type: application -version: 0.2.2 +version: 0.2.3 # Last version released on https://github.com/georchestra/cadastrapp is 2.0 appVersion: "2.0.0" diff --git a/cadastrapp/templates/cadastrapp-depl.yaml b/cadastrapp/templates/cadastrapp-depl.yaml index 60222db..a3f43e4 100644 --- a/cadastrapp/templates/cadastrapp-depl.yaml +++ b/cadastrapp/templates/cadastrapp-depl.yaml @@ -31,7 +31,7 @@ spec: cp /ssh-secret/ssh-privatekey /root/.ssh/id_rsa ; chmod 0600 /root/.ssh/id_rsa ; {{- end }} - rm -Rf /etc/georchestra + rm -Rf /etc/georchestra ; git clone {{ .Values.cadastrapp.datadir.git.url }} -b {{ .Values.cadastrapp.datadir.git.ref }} /etc/georchestra env: {{- if .Values.cadastrapp.datadir.git.ssh_secret }} diff --git a/geoserver-lb/Chart.yaml b/geoserver-lb/Chart.yaml index e643fa6..05fbab8 100644 --- a/geoserver-lb/Chart.yaml +++ b/geoserver-lb/Chart.yaml @@ -2,5 +2,5 @@ name: geoserver-lb apiVersion: v2 description: A Helm chart for deploying geoserver loadbalanced type: application -version: 0.6.1 +version: 0.6.2 appVersion: "22.0.4" diff --git a/geoserver-lb/templates/geoserver-deploy.yaml b/geoserver-lb/templates/geoserver-deploy.yaml index 6dd0471..5907a27 100644 --- a/geoserver-lb/templates/geoserver-deploy.yaml +++ b/geoserver-lb/templates/geoserver-deploy.yaml @@ -66,7 +66,7 @@ spec: - mkdir -p /root/.ssh ; cp /ssh-secret/ssh-privatekey /root/.ssh/id_rsa ; chmod 0600 /root/.ssh/id_rsa ; - rm -Rf /etc/georchestra + rm -Rf /etc/georchestra ; if [ ! -f /etc/georchestra/default.properties ] ; then git clone {{ .Values.geoserver.git.repository_url }} -b {{ .Values.geoserver.git.branch }} /etc/georchestra ; fi ; diff --git a/geoserver-lb/templates/geoserver-lb-deploy.yaml b/geoserver-lb/templates/geoserver-lb-deploy.yaml index 929d132..23cee38 100644 --- a/geoserver-lb/templates/geoserver-lb-deploy.yaml +++ b/geoserver-lb/templates/geoserver-lb-deploy.yaml @@ -47,9 +47,8 @@ spec: mountPath: /var/cache/nginx - name: var-run mountPath: /var/run - {{- range .Values.geoserver.extra_volumes }} - - name: {{ .name }} - mountPath: {{ .mountPath }} + {{- if .Values.geoserver.extra_volumes }} + {{ .Values.geoserver.extra_volumes | toYaml | nindent 8 }} {{- end }} resources: requests: @@ -79,10 +78,8 @@ spec: emptyDir: {} - name: etc-nginx emptyDir: {} - {{- range .Values.geoserver.extra_volumes }} - - name: {{ .name }} - persistentVolumeClaim: - claimName: {{ .claimName }} + {{- if .Values.geoserver.extra_volumeMounts }} + {{ .Values.geoserver.extra_volumeMounts | toYaml | nindent 10 }} {{- end }} diff --git a/mviewer/Chart.yaml b/mviewer/Chart.yaml index df7ef0f..e67fcb7 100644 --- a/mviewer/Chart.yaml +++ b/mviewer/Chart.yaml @@ -2,7 +2,7 @@ apiVersion: v2 name: mviewer description: A Helm chart to deploy the mviewer stack type: application -version: 0.2.11 +version: 0.2.12 appVersion: "3.9" maintainers: - name: geOrchestra diff --git a/mviewer/templates/_bootstrap-mviewer-configuration.tpl b/mviewer/templates/_bootstrap-mviewer-configuration.tpl index 036d269..039df9b 100644 --- a/mviewer/templates/_bootstrap-mviewer-configuration.tpl +++ b/mviewer/templates/_bootstrap-mviewer-configuration.tpl @@ -9,6 +9,7 @@ cp /ssh-secret/ssh-privatekey /root/.ssh/id_rsa ; chmod 0600 /root/.ssh/id_rsa ; {{- end }} + rm -Rf /usr/share/nginx/html/apps ; git clone --depth 1 --single-branch {{ .Values.configuration.git.url }} -b {{ .Values.configuration.git.ref }} /usr/share/nginx/html/apps ; {{- if .Values.configuration.git.ssh_secret }} env: