Merge "[COMMON][READINESS] Update readiness image and use service feature"
[oom.git] / kubernetes / common / mariadb-galera / templates / backup / cronjob.yaml
index 4548626..f212869 100644 (file)
@@ -32,6 +32,13 @@ spec:
   jobTemplate:
     spec:
       template:
+        metadata:
+          annotations:
+            # Workarround to exclude K8S API from istio communication
+            # as init-container (readinessCheck) does not work with the
+            # Istio CNI plugin, see:
+            # (https://istio.io/latest/docs/setup/additional-setup/cni/#compatibility-with-application-init-containers)
+            traffic.sidecar.istio.io/excludeOutboundPorts: "443"
         spec:
           serviceAccountName: {{ include "common.fullname" (dict "suffix" "read" "dot" . )}}
           {{ include "common.podSecurityContext" . | indent 10 | trim}}
@@ -162,8 +169,7 @@ spec:
                   readOnly: true
                 - name: backup-dir
                   mountPath: /backup
-          imagePullSecrets:
-            - name: {{ include "common.namespace" . }}-docker-registry-key
+          {{- include "common.imagePullSecrets" . | nindent 10 }}
           volumes:
             - name: localtime
               hostPath: