diff --git a/charts/library/common/Chart.yaml b/charts/library/common/Chart.yaml index 11e50bd82e1..5703f3676ad 100644 --- a/charts/library/common/Chart.yaml +++ b/charts/library/common/Chart.yaml @@ -18,4 +18,4 @@ maintainers: name: common sources: type: library -version: 6.2.0 +version: 6.3.0 diff --git a/charts/library/common/templates/lib/controller/_probes.tpl b/charts/library/common/templates/lib/controller/_probes.tpl index 2f6ecfe9485..12dbaa9ac4d 100644 --- a/charts/library/common/templates/lib/controller/_probes.tpl +++ b/charts/library/common/templates/lib/controller/_probes.tpl @@ -16,8 +16,18 @@ Probes selection logic. {{- $probe.spec | toYaml | nindent 2 }} {{- else }} {{- if and $primaryService $primaryPort -}} - {{- "tcpSocket:" | nindent 2 }} - {{- printf "port: %v" $primaryPort.port | nindent 4 }} + {{- if $primaryPort.protocol -}} + {{- if or ( eq $primaryPort.protocol "HTTP" ) ( eq $primaryPort.protocol "HTTPS" ) -}} + {{- "httpGet:" | nindent 2 }} + {{- printf "path: %v" $probe.path | nindent 4 }} + {{- printf "scheme: %v" $primaryPort.protocol | nindent 4 }} + {{- else -}} + {{- "tcpSocket:" | nindent 2 }} + {{- end }} + {{- else -}} + {{- "tcpSocket:" | nindent 2 }} + {{- end }} + {{- printf "port: %v" $primaryPort.port | nindent 4 }} {{- printf "initialDelaySeconds: %v" $probe.spec.initialDelaySeconds | nindent 2 }} {{- printf "failureThreshold: %v" $probe.spec.failureThreshold | nindent 2 }} {{- printf "timeoutSeconds: %v" $probe.spec.timeoutSeconds | nindent 2 }} diff --git a/charts/library/common/values.yaml b/charts/library/common/values.yaml index c7e13a7ba01..345a18a33ef 100644 --- a/charts/library/common/values.yaml +++ b/charts/library/common/values.yaml @@ -153,6 +153,9 @@ probes: enabled: true # -- Set this to `true` if you wish to specify your own livenessProbe custom: false + # -- If a HTTP probe is used (default for HTTP/HTTPS services) this path is used + # @default -- "/" + path: "/" # -- The spec field contains the values for the default livenessProbe. # If you selected `custom: true`, this field holds the definition of the livenessProbe. # @default -- See below @@ -169,6 +172,9 @@ probes: enabled: true # -- Set this to `true` if you wish to specify your own readinessProbe custom: false + # -- If a HTTP probe is used (default for HTTP/HTTPS services) this path is used + # @default -- "/" + path: "/" # -- The spec field contains the values for the default readinessProbe. # If you selected `custom: true`, this field holds the definition of the readinessProbe. # @default -- See below @@ -185,6 +191,9 @@ probes: enabled: true # -- Set this to `true` if you wish to specify your own startupProbe custom: false + # -- If a HTTP probe is used (default for HTTP/HTTPS services) this path is used + # @default -- "/" + path: "/" # -- The spec field contains the values for the default startupProbe. # If you selected `custom: true`, this field holds the definition of the startupProbe. # @default -- See below