Refactor MC windirver plugin namespace
[oom.git] / kubernetes / multicloud / charts / multicloud-windriver / templates / deployment.yaml
index 02a78bb..3dfe72c 100644 (file)
@@ -1,5 +1,6 @@
 {{/*
 # Copyright © 2017 Amdocs, Bell Canada
+# Modifications Copyright © 2018 AT&T
 #
 # Licensed under the Apache License, Version 2.0 (the "License");
 # you may not use this file except in compliance with the License.
@@ -35,6 +36,8 @@ spec:
         app: {{ include "common.name" . }}
         release: {{ .Release.Name }}
       name: {{ include "common.name" . }}
+      annotations:
+        sidecar.istio.io/inject: "{{.Values.istioSidecar}}"
     spec:
      containers:
      - env:
@@ -43,7 +46,7 @@ spec:
        - name: MSB_PORT
          value: "{{ .Values.config.msbPort }}"
        - name: AAI_ADDR
-         value: aai-service.{{ include "common.namespace" . }}
+         value: aai.{{ include "common.namespace" . }}
        - name: AAI_PORT
          value: "{{ .Values.config.aai.port }}"
        - name: AAI_SCHEMA_VERSION
@@ -59,7 +62,9 @@ spec:
        - mountPath: /opt/windriver/titanium_cloud/pub/config/log.yml
          name: windriver-logconfig
          subPath: log.yml
-       image: "{{ .Values.global.repository | default .Values.repository }}/{{ .Values.image }}"
+       resources:
+{{ toYaml (pluck .Values.flavor .Values.resources| first) | indent 12 }}
+       image: "{{ include "common.repository" . }}/{{ .Values.image }}"
        imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }}
        ports:
        - containerPort: {{ .Values.service.internalPort }}
@@ -68,7 +73,7 @@ spec:
        {{ if .Values.liveness.enabled }}
        livenessProbe:
          httpGet:
-           path: /api/multicloud-titanium_cloud/v0/swagger.json
+           path: /api/multicloud-titaniumcloud/v1/swagger.json
            port: {{ .Values.service.internalPort }}
            scheme: HTTP
          initialDelaySeconds: {{ .Values.liveness.initialDelaySeconds }}
@@ -77,17 +82,6 @@ spec:
          successThreshold: {{ .Values.liveness.successThreshold }}
          failureThreshold: {{ .Values.liveness.failureThreshold }}
        {{ end }}
-       resources:
-{{ toYaml .Values.resources | indent 12 }}
-        {{- if .Values.nodeSelector }}
-     nodeSelector:
-{{ toYaml .Values.nodeSelector | indent 10 }}
-     {{- end -}}
-     {{- if .Values.affinity }}
-     affinity:
-{{ toYaml .Values.affinity | indent 10 }}
-     {{- end }}
-
      # side car containers
      - image: "{{ .Values.global.loggingRepository }}/{{ .Values.global.loggingImage }}"
        imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }}