Support execution control of SDC Workflow init
[oom.git] / kubernetes / sdc / charts / sdc-wfd-be / templates / deployment.yaml
index a822504..84285c4 100644 (file)
@@ -1,4 +1,5 @@
-# Copyright © 2018 Amdocs, Bell Canada
+# Copyright © 2017 Amdocs, AT&T, Bell Canada
+# Modifications Copyright © 2018  ZTE
 #
 # Licensed under the Apache License, Version 2.0 (the "License");
 # you may not use this file except in compliance with the License.
@@ -31,6 +32,7 @@ spec:
         release: {{ .Release.Name }}
     spec:
       initContainers:
+      {{- if .Values.initJob.enabled }}
       - name: {{ include "common.name" . }}-job-completion
         image: "{{ .Values.global.readinessRepository }}/{{ .Values.global.readinessImage }}"
         imagePullPolicy: "{{ .Values.global.pullPolicy | default .Values.pullPolicy }}"
@@ -45,6 +47,7 @@ spec:
             fieldRef:
               apiVersion: v1
               fieldPath: metadata.namespace
+      {{ end }}
       containers:
         - name: {{ include "common.name" . }}
           image: "{{ include "common.repository" . }}/{{ .Values.image }}"
@@ -82,5 +85,9 @@ spec:
             value: "{{ .Values.config.sdcProtocol }}"
           - name: SDC_ENDPOINT
             value: "{{ .Values.config.sdcEndpoint }}"
+          - name: SDC_USER
+            value: "{{ .Values.config.sdcExternalUser }}"
+          - name: SDC_PASSWORD
+            value: "{{ .Values.config.sdcExternalUserPassword }}"
       imagePullSecrets:
-      - name: "{{ include "common.namespace" . }}-docker-registry-key"
\ No newline at end of file
+      - name: "{{ include "common.namespace" . }}-docker-registry-key"