Skip to content

Commit

Permalink
Merge pull request #1382 from porter-dev/stefanmcshane-patch-1
Browse files Browse the repository at this point in the history
Add stabilizationWindow
  • Loading branch information
yosefmih authored Aug 19, 2024
2 parents e1b152f + 4f798cb commit 53054ec
Show file tree
Hide file tree
Showing 2 changed files with 15 additions and 1 deletion.
14 changes: 13 additions & 1 deletion applications/testdata/web.yaml
Original file line number Diff line number Diff line change
@@ -1,5 +1,17 @@
autoscaling:
enabled: false
enabled: true
behavior:
enabled: true
scaleDown:
stabilizationWindowSeconds: 3600
type: Pods
value: 2
periodSeconds: 60
scaleUp:
stabilizationWindowSeconds: 3600
type: Pods
value: 2
periodSeconds: 60
gpu: false
maxReplicas: 10
minReplicas: 1
Expand Down
2 changes: 2 additions & 0 deletions applications/web/templates/hpa.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -12,11 +12,13 @@ spec:
{{- if .Values.autoscaling.behavior.enabled }}
behavior:
scaleDown:
stabilizationWindowSeconds: {{ .Values.autoscaling.behavior.scaleDown.stabilizationWindowSeconds | default 60 }}
policies:
- type: {{ .Values.autoscaling.behavior.scaleDown.type }}
value: {{ .Values.autoscaling.behavior.scaleDown.value }}
periodSeconds: {{ .Values.autoscaling.behavior.scaleDown.periodSeconds }}
scaleUp:
stabilizationWindowSeconds: {{ .Values.autoscaling.behavior.scaleUp.stabilizationWindowSeconds | default 60 }}
policies:
- type: {{ .Values.autoscaling.behavior.scaleUp.type }}
value: {{ .Values.autoscaling.behavior.scaleUp.value }}
Expand Down

0 comments on commit 53054ec

Please sign in to comment.