Skip to content
Snippets Groups Projects
Commit 643f6cfe authored by OZGCloud's avatar OZGCloud
Browse files

OZG-7037 refactor deployment chart to avoid repetition

parent e1f8c113
No related branches found
No related tags found
1 merge request!2Ozg 7037 configure xta client
......@@ -167,3 +167,11 @@ app.kubernetes.io/namespace: {{ include "app.namespace" . }}
{{- define "app.getZufiManagerAddress" -}}
{{- required "zufiManager.address must be set" (.Values.zufiManager).address -}}
{{- end -}}
{{- define "app.getKeyStorePath" -}}
{{- printf "/workspace/keystore/xta-keystore.p12" -}}
{{- end -}}
{{- define "app.getTrustStorePath" -}}
{{- printf "/workspace/truststore/xta-truststore.jks" -}}
{{- end -}}
\ No newline at end of file
......@@ -284,7 +284,7 @@ spec:
- name: ozgcloud_xta_clientIdentifiers
value: '{{ ((.Values.ozgcloud).xta).clientIdentifiers | toJson }}'
- name: ozgcloud_xta_keystore_file
value: "file:/workspace/keystore/xta-keystore.p12"
value: {{ printf "file:%s" (include "app.getKeyStorePath" .) }}
- name: ozgcloud_xta_keystore_type
valueFrom:
secretKeyRef:
......@@ -299,7 +299,7 @@ spec:
optional: false
{{- if ((.Values.ozgcloud).xta).truststore }}
- name: ozgcloud_xta_truststore_file
value: "file:/workspace/truststore/xta-truststore.jks"
value: {{ printf "file:%s" (include "app.getTrustStorePath" .) }}
- name: ozgcloud_xta_truststore_type
valueFrom:
secretKeyRef:
......@@ -419,13 +419,13 @@ spec:
readOnly: true
{{- if ((.Values.ozgcloud).xta).keystore }}
- name: xta-keystore
mountPath: "/workspace/keystore/xta-keystore.p12"
mountPath: {{ include "app.getKeyStorePath" . }}
subPath: file
readOnly: true
{{- end }}
{{- if ((.Values.ozgcloud).xta).truststore }}
- name: xta-truststore
mountPath: "/workspace/truststore/xta-truststore.jks"
mountPath: {{ include "app.getTrustStorePath" . }}
subPath: file
readOnly: true
{{- end }}
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment