Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions charts/argo-cd/Chart.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ appVersion: v3.2.0
kubeVersion: ">=1.25.0-0"
description: A Helm chart for Argo CD, a declarative, GitOps continuous delivery tool for Kubernetes.
name: argo-cd
version: 9.1.3
version: 9.1.4
home: https://github.com/argoproj/argo-helm
icon: https://argo-cd.readthedocs.io/en/stable/assets/logo.png
sources:
Expand All @@ -26,5 +26,5 @@ annotations:
fingerprint: 2B8F22F57260EFA67BE1C5824B11F800CD9D2252
url: https://argoproj.github.io/argo-helm/pgp_keys.asc
artifacthub.io/changes: |
- kind: changed
description: Add documentation about breaking changes when upgrading to 9.1.0 for redis-ha dependency
- kind: fixed
description: Make gateway API backend protocol selection work for server.
4 changes: 4 additions & 0 deletions charts/argo-cd/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -1328,8 +1328,12 @@ NAME: my-release
| server.service.loadBalancerIP | string | `""` | LoadBalancer will get created with the IP specified in this field |
| server.service.loadBalancerSourceRanges | list | `[]` | Source IP ranges to allow access to service from |
| server.service.nodePortHttp | int | `30080` | Server service http port for NodePort service type (only if `server.service.type` is set to "NodePort") |
| server.service.nodePortHttp2 | int | `38008` | Server service http2 port for NodePort service type (only if `server.service.type` is set to "NodePort") |
| server.service.nodePortHttps | int | `30443` | Server service https port for NodePort service type (only if `server.service.type` is set to "NodePort") |
| server.service.servicePortHttp | int | `80` | Server service http port |
| server.service.servicePortHttp2 | int | `8008` | Server service http2 port |
| server.service.servicePortHttp2AppProtocol | string | `"kubernetes.io/h2c"` | Server service http2 port appProtocol |
| server.service.servicePortHttp2Name | string | `"http2"` | Server service http2 port name, can be used to route traffic via istio |
| server.service.servicePortHttpName | string | `"http"` | Server service http port name, can be used to route traffic via istio |
| server.service.servicePortHttps | int | `443` | Server service https port |
| server.service.servicePortHttpsAppProtocol | string | `""` | Server service https port appProtocol |
Expand Down
28 changes: 17 additions & 11 deletions charts/argo-cd/templates/argocd-server/httproute.yaml
Original file line number Diff line number Diff line change
@@ -1,7 +1,9 @@
{{- if .Values.server.httproute.enabled -}}
{{- $fullName := include "argo-cd.server.fullname" . -}}
{{- $insecure := index .Values.configs.params "server.insecure" | toString -}}
{{- $servicePort := eq $insecure "true" | ternary .Values.server.service.servicePortHttp .Values.server.service.servicePortHttps -}}
{{- $servicePortHttp := .Values.server.service.servicePortHttp -}}
{{- $servicePortHttps := .Values.server.service.servicePortHttps -}}
{{- $servicePortHttp2 := .Values.server.service.servicePortHttp2 -}}
apiVersion: gateway.networking.k8s.io/v1
kind: HTTPRoute
metadata:
Expand All @@ -26,20 +28,24 @@ spec:
{{- toYaml . | nindent 4 }}
{{- end }}
rules:
{{- range .Values.server.httproute.rules }}
{{- with .matches }}
- matches:
{{- toYaml . | nindent 8 }}
{{- end }}
{{- with .filters }}
filters:
{{- toYaml . | nindent 8 }}
{{- end }}
backendRefs:
{{- range $servicePort := eq $insecure "true" | ternary (list $servicePortHttp $servicePortHttp2) (list $servicePortHttps) -}}
{{- range $.Values.server.httproute.rules | default (list dict) }}
- backendRefs:
- group: ''
kind: Service
name: {{ $fullName }}
port: {{ $servicePort }}
weight: 1
{{- with .matches | default (eq $servicePort $servicePortHttp2 | ternary (list dict) list) }}
matches:
{{- range . }}
- {{ eq $servicePort $servicePortHttp2 | ternary (set (deepCopy .) "headers" (prepend (index . "headers" | default list) (dict "name" "Content-Type" "value" "application/grpc"))) . | toYaml | indent 10 | trim }}
{{- end }}
{{- end }}
{{- with .filters }}
filters:
{{- toYaml . | nindent 8 }}
{{- end }}
{{- end }}
{{- end }}
{{- end }}
9 changes: 8 additions & 1 deletion charts/argo-cd/templates/argocd-server/service.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -44,6 +44,14 @@ spec:
{{- if eq .Values.server.service.type "NodePort" }}
nodePort: {{ .Values.server.service.nodePortHttp }}
{{- end }}
- name: {{ .Values.server.service.servicePortHttp2Name }}
protocol: TCP
appProtocol: {{ .Values.server.service.servicePortHttp2AppProtocol}}
port: {{ .Values.server.service.servicePortHttp2 }}
targetPort: {{ .Values.server.containerPorts.server }}
{{- if eq .Values.server.service.type "NodePort" }}
nodePort: {{ .Values.server.service.nodePortHttp2 }}
{{- end }}
Comment on lines +47 to +54
Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

What do you think about toggling between the h2c port AND http port OR https port based on the value of $insecure, since h2c and http should only be needed if the server isn't listening with https. I suppose this would be a more major change though than simply adding a port for h2c.

- name: {{ .Values.server.service.servicePortHttpsName }}
protocol: TCP
port: {{ .Values.server.service.servicePortHttps }}
Expand All @@ -56,4 +64,3 @@ spec:
{{- end }}
selector:
{{- include "argo-cd.selectorLabels" (dict "context" . "name" .Values.server.name) | nindent 4 }}

9 changes: 9 additions & 0 deletions charts/argo-cd/values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -2297,16 +2297,25 @@ server:
type: ClusterIP
# -- Server service http port for NodePort service type (only if `server.service.type` is set to "NodePort")
nodePortHttp: 30080
# -- Server service http2 port for NodePort service type (only if `server.service.type` is set to "NodePort")
nodePortHttp2: 38008
# -- Server service https port for NodePort service type (only if `server.service.type` is set to "NodePort")
nodePortHttps: 30443
# -- Server service http port
servicePortHttp: 80
# -- Server service http2 port
servicePortHttp2: 8008
# -- Server service https port
servicePortHttps: 443
# -- Server service http port name, can be used to route traffic via istio
servicePortHttpName: http
# -- Server service http2 port name, can be used to route traffic via istio
servicePortHttp2Name: http2
# -- Server service https port name, can be used to route traffic via istio
servicePortHttpsName: https
# -- Server service http2 port appProtocol
## Ref: https://kubernetes.io/docs/concepts/services-networking/service/#application-protocol
servicePortHttp2AppProtocol: "kubernetes.io/h2c"
# -- Server service https port appProtocol
## Ref: https://kubernetes.io/docs/concepts/services-networking/service/#application-protocol
servicePortHttpsAppProtocol: ""
Expand Down