Merge "[CPS] New Delhi release changes"
[oom.git] / kubernetes / sdnc / components / sdnc-prom / templates / deployment.yaml
index 803434c..7562a97 100644 (file)
@@ -18,9 +18,6 @@ apiVersion: apps/v1
 kind: Deployment
 metadata: {{- include "common.resourceMetadata" . | nindent 2 }}
 spec:
-  selector:
-    matchLabels:
-      app: {{ include "common.name" . }}
   replicas: 1
   selector: {{- include "common.selectors" . | nindent 4 }}
   template:
@@ -30,9 +27,9 @@ spec:
       - command:
         - /app/ready.py
         args:
-        - --container-name
+        - --service-name
         - sdnc
-        - --container-name
+        - --service-name
         - consul
         env:
         - name: NAMESPACE
@@ -43,6 +40,13 @@ spec:
         image: {{ include "repositoryGenerator.image.readiness" . }}
         imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }}
         name: {{ include "common.name" . }}-readiness
+        resources:
+          limits:
+            cpu: "100m"
+            memory: "500Mi"
+          requests:
+            cpu: "3m"
+            memory: "20Mi"
       containers:
       - name: {{ include "common.name" . }}
         image: {{ include "repositoryGenerator.repository" . }}/{{ .Values.image }}
@@ -53,9 +57,6 @@ spec:
         workingDir: "/app"
         command: [ "bin/prom.sh" ]
         volumeMounts:
-        - name: localtime
-          mountPath: /etc/localtime
-          readOnly: true
         - name: prom-config
           mountPath: /app/config
         - name: prom-scripts
@@ -71,9 +72,6 @@ spec:
       {{- end }}
       serviceAccountName: {{ include "common.fullname" (dict "suffix" "read" "dot" . )}}
       volumes:
-        - name: localtime
-          hostPath:
-            path: /etc/localtime
         - name: prom-config
           configMap:
             name: {{ include "common.fullname" . }}-configmap
@@ -88,5 +86,4 @@ spec:
         {{- else }}
           emptyDir: {}
         {{- end }}
-      imagePullSecrets:
-        - name: {{ include "common.namespace" . }}-docker-registry-key"
+      {{- include "common.imagePullSecrets" . | nindent 6 }}