[COMMON] Update all ReadinessChecks
[oom.git] / kubernetes / policy / components / policy-drools-pdp / templates / statefulset.yaml
index 4ce90da..1c66f6a 100755 (executable)
@@ -40,11 +40,18 @@ spec:
         image: {{ include "repositoryGenerator.image.readiness" . }}
         imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }}
         name: {{ include "common.name" . }}-db-readiness
+        resources:
+          limits:
+            cpu: "100m"
+            memory: "500Mi"
+          requests:
+            cpu: "3m"
+            memory: "20Mi"
 {{- if not .Values.nexus.offline }}
       - command:
         - /app/ready.py
         args:
-        - --container-name
+        - --service-name
         - {{ .Values.nexus.name }}
         env:
         - name: NAMESPACE
@@ -52,9 +59,24 @@ spec:
             fieldRef:
               apiVersion: v1
               fieldPath: metadata.namespace
+        - name: KAFKA_URL
+          value: {{ include "common.release" . }}-{{ .Values.global.kafkaBootstrap }}
+        - name: SASL
+          value: {{ .Values.kafkaUser.authenticationType | upper }}
+        - name: GROUP_ID
+          value: {{ .Values.config.kafka.consumer.groupId }}
+        - name: PAP_TOPIC
+          value: {{ .Values.config.app.listener.policyPdpPapTopic }}
         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"
 {{- end }}
       containers:
         - name: {{ include "common.name" . }}
@@ -130,5 +152,4 @@ spec:
               path: {{ base $path }}
               mode: 0644
             {{- end }}
-      imagePullSecrets:
-      - name: "{{ include "common.namespace" . }}-docker-registry-key"
+      {{- include "common.imagePullSecrets" . | nindent 6 }}