Skip to content
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

Handle existingClaim for storage conf #123

Open
wants to merge 2 commits into
base: main
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion templates/geonetwork/elasticsearch/es-data-pvc.yaml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{{- $webapp := .Values.georchestra.webapps.geonetwork.elasticsearch -}}
{{- $webapp_storage := .Values.georchestra.storage.gn4_es -}}
{{- if .Values.georchestra.webapps.geonetwork.enabled -}}
{{- if and .Values.georchestra.webapps.geonetwork.enabled (not $webapp_storage.existingClaim) -}}
apiVersion: v1
kind: PersistentVolumeClaim
metadata:
Expand Down
2 changes: 1 addition & 1 deletion templates/geonetwork/elasticsearch/es-deployment.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,7 @@ spec:
volumes:
- name: gn4-es-data
persistentVolumeClaim:
claimName: {{ include "georchestra.fullname" . }}-gn4-es-data
claimName: {{ .Values.georchestra.storage.gn4_es.existingClaim | default (print (include "georchestra.fullname" .) "-gn4-es-data") }}
{{- if $webapp.tolerations }}
tolerations:
{{- $webapp.tolerations | toYaml | nindent 8 }}
Expand Down
2 changes: 1 addition & 1 deletion templates/geonetwork/geonetwork-datadir-pvc.yaml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{{- $webapp := .Values.georchestra.webapps.geonetwork -}}
{{- $webapp_storage := .Values.georchestra.storage.geonetwork_datadir -}}
{{- if $webapp.enabled -}}
{{- if and $webapp.enabled (not $webapp_storage.existingClaim) -}}
apiVersion: v1
kind: PersistentVolumeClaim
metadata:
Expand Down
2 changes: 1 addition & 1 deletion templates/geonetwork/geonetwork-deployment.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -97,7 +97,7 @@ spec:
emptyDir: {}
- name: geonetwork-datadir
persistentVolumeClaim:
claimName: {{ include "georchestra.fullname" . }}-geonetwork-datadir
claimName: {{ .Values.georchestra.storage.geonetwork_datadir.existingClaim | default (print (include "georchestra.fullname" .) "-geonetwork-datadir") }}
{{- if .Values.georchestra.datadir.git.ssh_secret }}
- name: ssh-secret
secret:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ spec:
volumes:
- name: geonetwork-datadir
persistentVolumeClaim:
claimName: {{ include "georchestra.fullname" . }}-geonetwork-datadir
claimName: {{ .Values.georchestra.storage.geonetwork_datadir.existingClaim | default (print (include "georchestra.fullname" .) "-geonetwork-datadir") }}
restartPolicy: OnFailure
{{- if $webapp.housekeeping.tolerations }}
tolerations:
Expand Down
2 changes: 1 addition & 1 deletion templates/geoserver/geoserver-datadir-pvc.yaml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{{- $webapp := .Values.georchestra.webapps.geoserver -}}
{{- $webapp_storage := .Values.georchestra.storage.geoserver_datadir -}}
{{- if $webapp.enabled -}}
{{- if and $webapp.enabled (not $webapp_storage.existingClaim) -}}
apiVersion: v1
kind: PersistentVolumeClaim
metadata:
Expand Down
6 changes: 3 additions & 3 deletions templates/geoserver/geoserver-deployment.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -231,13 +231,13 @@ spec:
emptyDir: {}
- name: geoserver-tiles
persistentVolumeClaim:
claimName: {{ include "georchestra.fullname" . }}-geoserver-tiles
claimName: {{ .Values.georchestra.storage.geoserver_tiles.existingClaim | default (print (include "georchestra.fullname" .) "-geoserver-tiles") }}
- name: geoserver-geodata
persistentVolumeClaim:
claimName: {{ include "georchestra.fullname" . }}-geoserver-geodata
claimName: {{ .Values.georchestra.storage.geoserver_geodata.existingClaim | default (print (include "georchestra.fullname" .) "-geoserver-geodata") }}
- name: geoserver-datadir
persistentVolumeClaim:
claimName: {{ include "georchestra.fullname" . }}-geoserver-datadir
claimName: {{ .Values.georchestra.storage.geoserver_datadir.existingClaim | default (print (include "georchestra.fullname" .) "-geoserver-datadir") }}
{{- if .Values.georchestra.datadir.git.ssh_secret }}
- name: ssh-secret
secret:
Expand Down
2 changes: 1 addition & 1 deletion templates/geoserver/geoserver-geodata-pvc.yaml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{{- $webapp := .Values.georchestra.webapps.geoserver -}}
{{- $webapp_storage := .Values.georchestra.storage.geoserver_geodata -}}
{{- if $webapp.enabled -}}
{{- if and $webapp.enabled (not $webapp_storage.existingClaim) -}}
apiVersion: v1
kind: PersistentVolumeClaim
metadata:
Expand Down
2 changes: 1 addition & 1 deletion templates/geoserver/geoserver-tiles-pvc.yaml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{{- $webapp := .Values.georchestra.webapps.geoserver -}}
{{- $webapp_storage := .Values.georchestra.storage.geoserver_tiles -}}
{{- if and $webapp.enabled .Values.georchestra.storage.geoserver_tiles -}}
{{- if and $webapp.enabled .Values.georchestra.storage.geoserver_tiles (not $webapp_storage.existingClaim) -}}
apiVersion: v1
kind: PersistentVolumeClaim
metadata:
Expand Down
2 changes: 1 addition & 1 deletion templates/geowebcache/geowebcache-deployment.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -92,7 +92,7 @@ spec:
emptyDir: {}
- name: geowebcache-tiles
persistentVolumeClaim:
claimName: {{ include "georchestra.fullname" . }}-geowebcache-tiles
claimName: {{ .Values.georchestra.storage.geowebcache_tiles.existingClaim | default (print (include "georchestra.fullname" .) "-geowebcache-tiles") }}
{{- if .Values.georchestra.datadir.git.ssh_secret }}
- name: ssh-secret
secret:
Expand Down
2 changes: 1 addition & 1 deletion templates/geowebcache/geowebcache-tiles-pvc.yaml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{{- $webapp := .Values.georchestra.webapps.geowebcache -}}
{{- $webapp_storage := .Values.georchestra.storage.geowebcache_tiles -}}
{{- if and $webapp.enabled .Values.georchestra.storage.geowebcache_tiles -}}
{{- if and $webapp.enabled .Values.georchestra.storage.geowebcache_tiles (not $webapp_storage.existingClaim) -}}
apiVersion: v1
kind: PersistentVolumeClaim
metadata:
Expand Down
4 changes: 2 additions & 2 deletions templates/ldap/openldap-deployment.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -73,10 +73,10 @@ spec:
volumes:
- name: openldap-data
persistentVolumeClaim:
claimName: {{ include "georchestra.fullname" . }}-openldap-data
claimName: {{ .Values.georchestra.storage.openldap_data.existingClaim | default (print (include "georchestra.fullname" .) "-openldap-data") }}
- name: openldap-config
persistentVolumeClaim:
claimName: {{ include "georchestra.fullname" . }}-openldap-config
claimName: {{ .Values.georchestra.storage.openldap_config.existingClaim | default (print (include "georchestra.fullname" .) "-openldap-config") }}
{{- if $webapp.extraVolumes }}
{{- toYaml $webapp.extraVolumes | nindent 6 }}
{{- end }}
Expand Down
2 changes: 1 addition & 1 deletion templates/ldap/openldap-pvc-config.yaml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{{- $webapp := .Values.georchestra.webapps.openldap -}}
{{- $webapp_storage := .Values.georchestra.storage.openldap_config -}}
{{- if $webapp.enabled -}}
{{- if and $webapp.enabled (not $webapp_storage.existingClaim) -}}
apiVersion: v1
kind: PersistentVolumeClaim
metadata:
Expand Down
2 changes: 1 addition & 1 deletion templates/ldap/openldap-pvc-data.yaml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{{- $webapp := .Values.georchestra.webapps.openldap -}}
{{- $webapp_storage := .Values.georchestra.storage.openldap_data -}}
{{- if $webapp.enabled -}}
{{- if and $webapp.enabled (not $webapp_storage.existingClaim) -}}
apiVersion: v1
kind: PersistentVolumeClaim
metadata:
Expand Down
2 changes: 1 addition & 1 deletion templates/mapstore/mapstore-deployment.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -79,7 +79,7 @@ spec:
emptyDir: {}
- name: mapstore-datadir
persistentVolumeClaim:
claimName: {{ include "georchestra.fullname" . }}-mapstore-datadir
claimName: {{ .Values.georchestra.storage.mapstore_datadir.existingClaim | default (print (include "georchestra.fullname" .) "-mapstore-datadir") }}
{{- if .Values.georchestra.datadir.git.ssh_secret }}
- name: ssh-secret
secret:
Expand Down
2 changes: 1 addition & 1 deletion templates/mapstore/mapstore-pvc.yaml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{{- $webapp := .Values.georchestra.webapps.mapstore -}}
{{- $webapp_storage := .Values.georchestra.storage.mapstore_datadir -}}
{{- if $webapp.enabled -}}
{{- if and $webapp.enabled (not $webapp_storage.existingClaim) -}}
apiVersion: v1
kind: PersistentVolumeClaim
metadata:
Expand Down
4 changes: 2 additions & 2 deletions templates/rabbitmq/rabbitmq-pvc.yaml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{{- $rabbitmq := .Values.rabbitmq -}}
{{- $rabbitmq_storage := .Values.georchestra.storage.mapstore_datadir -}}
{{- if and $rabbitmq.enabled $rabbitmq.storage -}}
{{- $rabbitmq_storage := .Values.rabbitmq.storage -}}
{{- if and $rabbitmq.enabled $rabbitmq.storage (not $rabbitmq_storage.existingClaim) -}}
apiVersion: v1
kind: PersistentVolumeClaim
metadata:
Expand Down
2 changes: 2 additions & 0 deletions values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -217,8 +217,10 @@ georchestra:
# Some cloud providers automatically create & assign PVs to PVCs
# some other need to create a PV first ; if so, then you can
# uncomment the `pv_name` entries below.
# You can use existingClaim to provide the name of an existing PVC to use for persistence
storage:
gn4_es:
# existingClaim: gn4-es-data
# pv_name: gn4_es_data
size: 2Gi
geonetwork_datadir:
Expand Down
Loading