diff --git a/deploy/azure/azure.yml b/deploy/azure/azure.yml index 81612d5d..f988d5fc 100644 --- a/deploy/azure/azure.yml +++ b/deploy/azure/azure.yml @@ -29,6 +29,13 @@ spec: containers: - name: atst image: $CONTAINER_IMAGE + env: + - name: UWSGI_PROCESSES + value: "2" + - name: UWSGI_THREADS + value: "2" + - name: UWSGI_ENABLE_THREADS + value: "1" envFrom: - configMapRef: name: atst-envvars @@ -50,11 +57,11 @@ spec: mountPath: "/config" resources: requests: - memory: 200Mi - cpu: 400m + memory: 400Mi + cpu: 940m limits: - memory: 200Mi - cpu: 400m + memory: 400Mi + cpu: 940m - name: nginx image: nginx:alpine ports: @@ -86,10 +93,10 @@ spec: resources: requests: memory: 20Mi - cpu: 10m + cpu: 25m limits: memory: 20Mi - cpu: 10m + cpu: 25m volumes: - name: nginx-client-ca-bundle configMap: diff --git a/deploy/overlays/staging/autoscaling.yml b/deploy/overlays/staging/autoscaling.yml new file mode 100644 index 00000000..b7500c09 --- /dev/null +++ b/deploy/overlays/staging/autoscaling.yml @@ -0,0 +1,16 @@ +--- +apiVersion: autoscaling/v2beta1 +kind: HorizontalPodAutoscaler +metadata: + name: atst +spec: + minReplicas: 1 + maxReplicas: 2 +--- +apiVersion: autoscaling/v2beta1 +kind: HorizontalPodAutoscaler +metadata: + name: atst-worker +spec: + minReplicas: 1 + maxReplicas: 2 diff --git a/deploy/overlays/staging/kustomization.yaml b/deploy/overlays/staging/kustomization.yaml index 24705531..c1ef8fd2 100644 --- a/deploy/overlays/staging/kustomization.yaml +++ b/deploy/overlays/staging/kustomization.yaml @@ -5,6 +5,7 @@ resources: - namespace.yml - reset-cron-job.yml patchesStrategicMerge: + - autoscaling.yml - ports.yml - envvars.yml - flex_vol.yml