tomcat: added secrets manifest for sensitive variables.

A secret volume named `tomcat` is created to store password variables.
This commit is contained in:
Sameer Naik
2016-06-30 12:20:29 +05:30
parent 0881727cd5
commit 440eb7123d
5 changed files with 31 additions and 3 deletions

View File

@@ -2,7 +2,7 @@ name: tomcat
home: http://tomcat.apache.org
source:
- https://github.com/bitnami/bitnami-docker-tomcat
version: 0.2.0
version: 0.2.1
description: Chart for Apache Tomcat
maintainers:
- Bitnami <containers@bitnami.com>

View File

@@ -25,7 +25,10 @@ spec:
- name: TOMCAT_USER
value: "user"
- name: TOMCAT_PASSWORD
value: ""
valueFrom:
secretKeyRef:
name: tomcat
key: tomcat-password
ports:
- name: http
containerPort: 8080

View File

@@ -0,0 +1,11 @@
#helm:generate helmc tpl -d tpl/values.toml -o manifests/tomcat-secrets.yaml $HELM_GENERATE_FILE
apiVersion: v1
kind: Secret
metadata:
name: tomcat
labels:
provider: tomcat
heritage: bitnami
type: Opaque
data:
tomcat-password: ""

View File

@@ -25,7 +25,10 @@ spec:
- name: TOMCAT_USER
value: {{ .tomcatUser | quote }}
- name: TOMCAT_PASSWORD
value: {{ .tomcatPassword | quote }}
valueFrom:
secretKeyRef:
name: tomcat
key: tomcat-password
ports:
- name: http
containerPort: 8080

View File

@@ -0,0 +1,11 @@
#helm:generate helmc tpl -d tpl/values.toml -o manifests/tomcat-secrets.yaml $HELM_GENERATE_FILE
apiVersion: v1
kind: Secret
metadata:
name: tomcat
labels:
provider: tomcat
heritage: bitnami
type: Opaque
data:
tomcat-password: {{ .tomcatPassword | b64enc | quote }}