diff options
author | 2019-12-11 14:04:58 +0000 | |
---|---|---|
committer | 2019-12-11 14:04:58 +0000 | |
commit | 7be20b6c241f25b9845b448f1d65d97705634380 (patch) | |
tree | 5652700723d9a587732ff50dd04717f84cc5a4d4 /kubernetes/policy/charts/drools | |
parent | 16b32ddfe9237ffeed3dc9f1422978ca65995e4b (diff) | |
parent | 899370565bd26ab2d268c9acd53c4e6a59e198ec (diff) |
Merge "[POLICY] Use global storage templates for PVC"
Diffstat (limited to 'kubernetes/policy/charts/drools')
-rw-r--r-- | kubernetes/policy/charts/drools/charts/nexus/templates/pv.yaml | 3 | ||||
-rw-r--r-- | kubernetes/policy/charts/drools/charts/nexus/templates/pvc.yaml | 11 |
2 files changed, 4 insertions, 10 deletions
diff --git a/kubernetes/policy/charts/drools/charts/nexus/templates/pv.yaml b/kubernetes/policy/charts/drools/charts/nexus/templates/pv.yaml index bf372b3744..f45e9d4b58 100644 --- a/kubernetes/policy/charts/drools/charts/nexus/templates/pv.yaml +++ b/kubernetes/policy/charts/drools/charts/nexus/templates/pv.yaml @@ -16,6 +16,7 @@ */}} {{- if and .Values.persistence.enabled (not .Values.persistence.existingClaim) -}} +{{- if eq "True" (include "common.needPV" .) -}} kind: PersistentVolume apiVersion: v1 metadata: @@ -33,6 +34,8 @@ spec: accessModes: - {{ .Values.persistence.accessMode }} persistentVolumeReclaimPolicy: {{ .Values.persistence.volumeReclaimPolicy }} + storageClassName: "{{ include "common.fullname" . }}-data" hostPath: path: {{ .Values.global.persistence.mountPath | default .Values.persistence.mountPath }}/{{ .Release.Name }}/{{ .Values.persistence.mountSubPath }} {{- end -}} +{{- end -}} diff --git a/kubernetes/policy/charts/drools/charts/nexus/templates/pvc.yaml b/kubernetes/policy/charts/drools/charts/nexus/templates/pvc.yaml index 1deed4e92a..a082319789 100644 --- a/kubernetes/policy/charts/drools/charts/nexus/templates/pvc.yaml +++ b/kubernetes/policy/charts/drools/charts/nexus/templates/pvc.yaml @@ -31,19 +31,10 @@ metadata: {{ toYaml .Values.persistence.annotations | indent 4 }} {{- end }} spec: - selector: - matchLabels: - name: {{ include "common.fullname" . }} accessModes: - {{ .Values.persistence.accessMode }} + storageClassName: {{ include "common.storageClass" . }} resources: requests: storage: {{ .Values.persistence.size }} -{{- if .Values.persistence.storageClass }} -{{- if (eq "-" .Values.persistence.storageClass) }} - storageClassName: "" -{{- else }} - storageClassName: "{{ .Values.persistence.storageClass }}" -{{- end }} -{{- end }} {{- end -}} |