-
Notifications
You must be signed in to change notification settings - Fork 205
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* Allow pega credential secret to be overridden in a subchart. * Allow pega-credentials-secret to be overridden when used as subchart to support secret values coming from multiple k8s secrets (via a projected volume potentially). Co-authored-by: dorid <[email protected]>
- Loading branch information
1 parent
23f7985
commit f57af65
Showing
5 changed files
with
41 additions
and
38 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,28 @@ | ||
{{- define "pegaCredentialsSecretTemplate" }} | ||
kind: Secret | ||
apiVersion: v1 | ||
metadata: | ||
name: {{ template "pegaCredentialsSecret" }} | ||
namespace: {{ .Release.Namespace }} | ||
data: | ||
# Base64 encdoded username for connecting to the Pega DB | ||
DB_USERNAME: {{ .Values.global.jdbc.username | b64enc }} | ||
# Base64 encdoded password for connecting to the Pega DB | ||
DB_PASSWORD: {{ .Values.global.jdbc.password | b64enc }} | ||
|
||
{{ if (eq (include "performDeployment" .) "true") }} | ||
# Base64 encdoded username for connecting to cassandra | ||
CASSANDRA_USERNAME: {{ .Values.dds.username | b64enc }} | ||
# Base64 encdoded password for connecting to cassandra | ||
CASSANDRA_PASSWORD: {{ .Values.dds.password | b64enc }} | ||
{{ range $index, $dep := .Values.global.tier}} | ||
{{ if and ($dep.pegaDiagnosticUser) (eq $dep.name "web") }} | ||
# Base64 encdoded username for a Tomcat user that will be created with the PegaDiagnosticUser role | ||
PEGA_DIAGNOSTIC_USER: {{ $dep.pegaDiagnosticUser | b64enc }} | ||
# Base64 encdoded password for a Tomcat user that will be created with the PegaDiagnosticUser role | ||
PEGA_DIAGNOSTIC_PASSWORD: {{ $dep.pegaDiagnosticPassword | b64enc }} | ||
{{ end }} | ||
{{ end }} | ||
{{ end }} | ||
type: Opaque | ||
{{- end }} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,26 +1 @@ | ||
kind: Secret | ||
apiVersion: v1 | ||
metadata: | ||
name: {{ template "pegaCredentialsSecret" }} | ||
namespace: {{ .Release.Namespace }} | ||
data: | ||
# Base64 encdoded username for connecting to the Pega DB | ||
DB_USERNAME: {{ .Values.global.jdbc.username | b64enc }} | ||
# Base64 encdoded password for connecting to the Pega DB | ||
DB_PASSWORD: {{ .Values.global.jdbc.password | b64enc }} | ||
|
||
{{ if (eq (include "performDeployment" .) "true") }} | ||
# Base64 encdoded username for connecting to cassandra | ||
CASSANDRA_USERNAME: {{ .Values.dds.username | b64enc }} | ||
# Base64 encdoded password for connecting to cassandra | ||
CASSANDRA_PASSWORD: {{ .Values.dds.password | b64enc }} | ||
{{ range $index, $dep := .Values.global.tier}} | ||
{{ if and ($dep.pegaDiagnosticUser) (eq $dep.name "web") }} | ||
# Base64 encdoded username for a Tomcat user that will be created with the PegaDiagnosticUser role | ||
PEGA_DIAGNOSTIC_USER: {{ $dep.pegaDiagnosticUser | b64enc }} | ||
# Base64 encdoded password for a Tomcat user that will be created with the PegaDiagnosticUser role | ||
PEGA_DIAGNOSTIC_PASSWORD: {{ $dep.pegaDiagnosticPassword | b64enc }} | ||
{{ end }} | ||
{{ end }} | ||
{{ end }} | ||
type: Opaque | ||
{{- include "pegaCredentialsSecretTemplate" . }} |