From b3a6546b398a0fc20ff2acd09fd351cfa1126588 Mon Sep 17 00:00:00 2001 From: Petya Vasileva Date: Fri, 5 Jan 2024 19:04:47 +0200 Subject: [PATCH] Scale up pods. Add rediness check --- kube/frontend.yaml | 32 +++++++++++++++++++++----------- 1 file changed, 21 insertions(+), 11 deletions(-) diff --git a/kube/frontend.yaml b/kube/frontend.yaml index 426054e..1a1ac32 100644 --- a/kube/frontend.yaml +++ b/kube/frontend.yaml @@ -47,7 +47,12 @@ metadata: labels: k8s-app: ps-dash spec: - replicas: 1 + replicas: 3 + strategy: + type: RollingUpdate + rollingUpdate: + maxUnavailable: 1 + maxSurge: 1 selector: matchLabels: k8s-app: ps-dash @@ -56,24 +61,29 @@ spec: labels: k8s-app: ps-dash spec: + terminationGracePeriodSeconds: 900 # wait for 15 minuted before forcibly terminating the pod containers: - name: ps-dash image: sandci/ps-dash:latest - # command: ["sleep"] - # args: ["36500000"] + imagePullPolicy: Always ports: - containerPort: 8050 - # livenessProbe: - # httpGet: - # scheme: HTTP - # path: /healthz - # port: 80 - # periodSeconds: 60 - # initialDelaySeconds: 60 - # timeoutSeconds: 10 + readinessProbe: + httpGet: + path: /ready + port: 8050 + initialDelaySeconds: 200 + periodSeconds: 10 volumeMounts: - name: frontend-conf-volume mountPath: "/etc/ps-dash/" + resources: + requests: + cpu: "1000m" + memory: "4Gi" + limits: + cpu: "4000m" + memory: "12Gi" volumes: - name: frontend-conf-volume secret: