mirror of
https://github.com/bitnami/charts.git
synced 2026-03-15 06:47:24 +08:00
[bitnami/tomcat] Allow setting existing PVCs (#2130)
Signed-off-by: Javier J. Salmeron Garcia <jsalmeron@vmware.com> Co-authored-by: Carlos Rodríguez Hernández <carlosrh@vmware.com>
This commit is contained in:
committed by
GitHub
parent
8041743dc9
commit
a4573d871f
@@ -1,6 +1,6 @@
|
||||
apiVersion: v1
|
||||
name: tomcat
|
||||
version: 6.2.10
|
||||
version: 6.3.0
|
||||
appVersion: 9.0.33
|
||||
description: Chart for Apache Tomcat
|
||||
keywords:
|
||||
|
||||
@@ -30,6 +30,13 @@ Create chart name and version as used by the chart label.
|
||||
{{- printf "%s-%s" .Chart.Name .Chart.Version | replace "+" "_" | trunc 63 | trimSuffix "-" -}}
|
||||
{{- end -}}
|
||||
|
||||
{{/*
|
||||
Expand the name of the chart.
|
||||
*/}}
|
||||
{{- define "tomcat.pvc" -}}
|
||||
{{- coalesce .Values.persistence.existingClaim (include "tomcat.fullname" .) -}}
|
||||
{{- end -}}
|
||||
|
||||
{{/*
|
||||
Common labels
|
||||
*/}}
|
||||
|
||||
@@ -93,7 +93,7 @@ spec:
|
||||
- name: data
|
||||
{{- if .Values.persistence.enabled }}
|
||||
persistentVolumeClaim:
|
||||
claimName: {{ template "tomcat.fullname" . }}
|
||||
claimName: {{ template "tomcat.pvc" . }}
|
||||
{{- else }}
|
||||
emptyDir: {}
|
||||
{{- end -}}
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
{{- if .Values.persistence.enabled -}}
|
||||
{{- if and .Values.persistence.enabled (not .Values.persistence.existingClaim) -}}
|
||||
kind: PersistentVolumeClaim
|
||||
apiVersion: v1
|
||||
metadata:
|
||||
|
||||
@@ -159,6 +159,9 @@ persistence:
|
||||
## Persistent Volume size
|
||||
##
|
||||
size: 8Gi
|
||||
## Name of an existing PVC
|
||||
##
|
||||
existingClaim:
|
||||
|
||||
## Service parameters
|
||||
##
|
||||
|
||||
Reference in New Issue
Block a user