Merge "[DMAAP] DMaaP ServiceMesh compatibility"
[oom.git] / kubernetes / aaf / components / aaf-templates / templates / _deployment.tpl
index 00b44a0..c0614b2 100644 (file)
@@ -23,12 +23,16 @@ spec:
   replicas: {{ .Values.replicaCount }}
   template:
     metadata: {{- include "common.templateMetadata" . | nindent 6 }}
+      {{- if (include "common.onServiceMesh" .) }}
+      annotations:
+        sidecar.istio.io/inject: "false"
+      {{- end }}
     spec: {{ include "aaf.initContainers" . | nindent 6 }}
       containers:
       - name: {{ include "common.name" . }}
         workingDir: /opt/app/aaf
         command: ["bin/{{ .Values.binary }}"]
-        image: {{ include "common.repository" . }}/{{.Values.global.aaf.image}}
+        image: {{ include "repositoryGenerator.repository" . }}/{{.Values.global.aaf.image}}
         imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }}
         ports: {{ include "common.containerPorts" . | nindent 10  }}
         volumeMounts:
@@ -40,6 +44,8 @@ spec:
         - mountPath: /opt/app/osaaf/etc/org.osaaf.aaf.log4j.props
           name: aaf-log
           subPath: org.osaaf.aaf.log4j.props
+        - mountPath: /opt/app/osaaf/data/
+          name: config-identity
         {{- if eq .Values.liveness.enabled true }}
         livenessProbe:
           tcpSocket:
@@ -68,6 +74,11 @@ spec:
       - name: aaf-log
         configMap:
           name: {{ include "common.release" . }}-aaf-log
+      - name: config-init-identity
+        configMap:
+          name: {{ include "common.release" . }}-aaf-identity
+      - name: config-identity
+        emptyDir: {}
       imagePullSecrets:
       - name: "{{ include "common.namespace" . }}-docker-registry-key"
 {{- end -}}