Skip to content

Commit fb93670

Browse files
committed
fix: Reorder metrics list in HPA
this fixed reconciliation loops with Argo CD because HPA controller reorders this list Signed-off-by: Silvan Loser <[email protected]>
1 parent db71dca commit fb93670

File tree

2 files changed

+9
-9
lines changed

2 files changed

+9
-9
lines changed

helm/oauth2-proxy/Chart.yaml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
name: oauth2-proxy
2-
version: 7.7.6
2+
version: 7.7.7
33
apiVersion: v2
44
appVersion: 7.6.0
55
home: https://oauth2-proxy.github.io/oauth2-proxy/
@@ -35,7 +35,7 @@ kubeVersion: ">=1.9.0-0"
3535
annotations:
3636
artifacthub.io/changes: |
3737
- kind: fixed
38-
description: Updated the Redis chart to the latest version
38+
description: Reorder metrics list in HPA to avoid reconciliation loops with Argo CD
3939
links:
4040
- name: Github PR
41-
url: https://github.com/oauth2-proxy/manifests/pull/218
41+
url: https://github.com/oauth2-proxy/manifests/pull/219

helm/oauth2-proxy/templates/hpa.yaml

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -19,20 +19,20 @@ spec:
1919
minReplicas: {{ .Values.autoscaling.minReplicas }}
2020
maxReplicas: {{ .Values.autoscaling.maxReplicas }}
2121
metrics:
22-
{{- if .Values.autoscaling.targetCPUUtilizationPercentage }}
22+
{{- if .Values.autoscaling.targetMemoryUtilizationPercentage }}
2323
- type: Resource
2424
resource:
25-
name: cpu
25+
name: memory
2626
target:
2727
type: Utilization
28-
averageUtilization: {{ .Values.autoscaling.targetCPUUtilizationPercentage }}
28+
averageUtilization: {{ .Values.autoscaling.targetMemoryUtilizationPercentage }}
2929
{{- end }}
30-
{{- if .Values.autoscaling.targetMemoryUtilizationPercentage }}
30+
{{- if .Values.autoscaling.targetCPUUtilizationPercentage }}
3131
- type: Resource
3232
resource:
33-
name: memory
33+
name: cpu
3434
target:
3535
type: Utilization
36-
averageUtilization: {{ .Values.autoscaling.targetMemoryUtilizationPercentage }}
36+
averageUtilization: {{ .Values.autoscaling.targetCPUUtilizationPercentage }}
3737
{{- end }}
3838
{{- end }}

0 commit comments

Comments
 (0)