diff --git a/chart/templates/deployment-celery-worker.yaml b/chart/templates/celery-worker.yaml similarity index 76% rename from chart/templates/deployment-celery-worker.yaml rename to chart/templates/celery-worker.yaml index 662a46a62107d0bd31fe8948d6c24c088941e496..471dc1b1ac48bf1e06c68490d3012c1ac99e5aef 100644 --- a/chart/templates/deployment-celery-worker.yaml +++ b/chart/templates/celery-worker.yaml @@ -1,5 +1,3 @@ ---- -{{- if .Values.celery.autoScaling}} apiVersion: v1 kind: Service metadata: @@ -16,44 +14,6 @@ spec: {{- include "chart.labels" . | nindent 4 }} app: celery-worker --- -#apiVersion: autoscaling/v1 -#kind: HorizontalPodAutoscaler -#metadata: -# name: {{ printf "%s-%s" .Release.Name "hpa" }} -#spec: -# scaleTargetRef: -# apiVersion: apps/v1 -# kind: StatefulSet -# name: {{ printf "%s-%s" .Release.Name "celery" }} -# minReplicas: 1 -# maxReplicas: 3 -# targetCPUUtilizationPercentage: 50 ---- -apiVersion: autoscaling/v2beta2 -kind: HorizontalPodAutoscaler -metadata: - name: {{ printf "%s-%s" .Release.Name "hpa" }} -spec: - scaleTargetRef: - apiVersion: apps/v1 - kind: StatefulSet - name: {{ printf "%s-%s" .Release.Name "celery" }} - minReplicas: 1 - maxReplicas: 3 - metrics: - - type: Resource - resource: - name: cpu - target: - type: Utilization - averageUtilization: 50 - behavior: - scaleDown: - stabilizationWindowSeconds: 120 - scaleUp: - stabilizationWindowSeconds: 10 ---- -{{- end }} apiVersion: apps/v1 kind: StatefulSet metadata: