Skip to content

Commit cd64953

Browse files
committed
Fix issue with EKS semver suffix
The semver suffix added by EKS indicated a "pre-release" version, however the EKS team just wanted to add their own custom tag, not to indicate a pre-release. The check to print the correct ingress version can probably be removed now since v1 became stable as of v1.19, that said this change strips any K8s version suffix so that the comparison does not fail. It was failing because semverCompare considered any pre-release version to be less than v1.19. Tested by helm template. We didn't see this issue before because most people seem to create their own separate ingress records rather than the one generated by the chart. Signed-off-by: Alex Ellis (OpenFaaS Ltd) <[email protected]>
1 parent 6ed2e1d commit cd64953

14 files changed

+296
-271
lines changed

chart/openfaas/Chart.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@ apiVersion: v2
22
type: application
33
description: OpenFaaS - Serverless Functions Made Simple
44
name: openfaas
5-
version: 14.2.81
5+
version: 14.2.82
66
sources:
77
- https://github.com/openfaas/faas
88
- https://github.com/openfaas/faas-netes

chart/openfaas/templates/_helpers.tpl

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -19,9 +19,10 @@ We truncate at 63 chars because some Kubernetes name fields are limited to this
1919
{{- end -}}
2020
{{- end -}}
2121

22-
{{/* Way to override KubeVersion. */}}
22+
{{/* Way to override KubeVersion, with EKS suffix sanitization */}}
2323
{{- define "openfaas.ingress.kubeVersion" -}}
24-
{{- default .Capabilities.KubeVersion.Version .Values.k8sVersionOverride -}}
24+
{{- $version := default .Capabilities.KubeVersion.Version .Values.k8sVersionOverride -}}
25+
{{- regexReplaceAll "([0-9]+\\.[0-9]+\\.[0-9]+).*" $version "$1" -}}
2526
{{- end -}}
2627

2728
{{/* Determine Ingress API Version */}}

docs/cron-connector-0.6.11.tgz

1 Byte
Binary file not shown.

docs/federated-gateway-0.1.0.tgz

0 Bytes
Binary file not shown.

docs/index.yaml

Lines changed: 292 additions & 268 deletions
Large diffs are not rendered by default.

docs/kafka-connector-0.7.11.tgz

-4 Bytes
Binary file not shown.

docs/mqtt-connector-0.4.7.tgz

0 Bytes
Binary file not shown.

docs/nats-connector-0.3.2.tgz

0 Bytes
Binary file not shown.

docs/openfaas-14.2.82.tgz

62.3 KB
Binary file not shown.

docs/postgres-connector-0.1.1.tgz

-2 Bytes
Binary file not shown.

0 commit comments

Comments
 (0)