diff --git a/deploy/app/webhooks-processor/base/hpa.yaml b/deploy/app/webhooks-processor/base/hpa.yaml new file mode 100644 index 00000000..b80a45c5 --- /dev/null +++ b/deploy/app/webhooks-processor/base/hpa.yaml @@ -0,0 +1,23 @@ +apiVersion: autoscaling/v2beta2 +kind: HorizontalPodAutoscaler +metadata: + name: webhooks-processor +spec: + scaleTargetRef: + apiVersion: apps/v1 + kind: Deployment + name: webhooks-processor + minReplicas: 1 + maxReplicas: 10 + behavior: + scaleDown: + stabilizationWindowSeconds: 20 + scaleUp: + stabilizationWindowSeconds: 0 + metrics: + - type: Resource + resource: + name: cpu + target: + type: Utilization + averageUtilization: 75 diff --git a/deploy/app/webhooks-processor/base/kustomization.yaml b/deploy/app/webhooks-processor/base/kustomization.yaml index 36052210..e69ec2db 100644 --- a/deploy/app/webhooks-processor/base/kustomization.yaml +++ b/deploy/app/webhooks-processor/base/kustomization.yaml @@ -1,5 +1,6 @@ resources: - deployment.yaml +- hpa.yaml commonLabels: kubernetes.io/name: webhooks-processor