From ccc4035d348384e2d52d037552b702f3515eddda Mon Sep 17 00:00:00 2001 From: "Alex Ellis (OpenFaaS Ltd)" Date: Mon, 10 Jun 2024 17:41:20 +0100 Subject: [PATCH] Use inlets 0.9.31 for server/client Signed-off-by: Alex Ellis (OpenFaaS Ltd) --- Makefile | 9 +++++++-- chart/inlets-operator/README.md | 6 +++--- chart/inlets-operator/templates/deployment.yaml | 4 ++-- chart/inlets-operator/values.yaml | 12 ++++++++---- image_test.go | 8 ++++---- main.go | 2 +- 6 files changed, 25 insertions(+), 16 deletions(-) diff --git a/Makefile b/Makefile index bb6d5f19..818b0c6e 100644 --- a/Makefile +++ b/Makefile @@ -92,5 +92,10 @@ verify-chart: .PHONY: upgrade-chart upgrade-chart: - @echo Upgrading helm chart images && \ - arkade chart upgrade --verbose=$(VERBOSE) -f ./chart/inlets-operator/values.yaml -w + @echo Upgrading helm chart images in remote registries && \ + arkade chart upgrade --verbose=$(VERBOSE) -f ./chart/inlets-operator/values.yaml --write + +.PHONY: bump-chart +bump-chart: + @echo Bumping helm chart version if needed && \ + arkade chart bump --verbose=$(VERBOSE) -f ./chart/inlets-operator/values.yaml --write diff --git a/chart/inlets-operator/README.md b/chart/inlets-operator/README.md index 70b7421e..bf1c5476 100644 --- a/chart/inlets-operator/README.md +++ b/chart/inlets-operator/README.md @@ -79,15 +79,15 @@ and can be overwritten via the helm `--set` flag. Parameter | Description | Default value --- | --- | --- `annotatedOnly` | Only create tunnels for LoadBalancer with a `operator.inlets.dev/manage=1` annotation | `false` -`inletsClientImage` | Docker image for the inlets client | See values.yaml -`image` | Docker image for the inlets-operator | See values.yaml +`inletsclient.Image` | Container image for the inlets client when deployed inside K8s | See values.yaml +`image` | Container image for the inlets-operator | See values.yaml +`inletsRelease` | Release version of inlets for tunnel server VMs run via systemd | See values.yaml `secretKeyFile` | If we are using a provider that requires a secret key as well as an access key, set to `/var/secrets/inlets/secret/inlets-secret-key` | `""` `affinity` | Node affinity policy | `{}` `nodeSelector` | Node labels for data pod assignment | `{}` `tolerations` | Node tolerations | `[]` `resources` | Operator resources requests & limits | `{"requests":{"cpu": "100m", "memory": "128Mi"}}` `accessKeyFile` | Read the access key for your infrastructure provider from a file (recommended) | `/var/secrets/inlets/inlets-access-key` -`inletsRelease` |Release version of inlets for tunnel servers | See values.yaml `subnetId` | The Subnet ID where the exit-server should be placed (EC2) | `""` `vpcId` | The VPC ID to create the exit-server in (EC2) | `""` `plan` | The plan or size for your cloud instance | different defaults, depending of the infrastructure provider diff --git a/chart/inlets-operator/templates/deployment.yaml b/chart/inlets-operator/templates/deployment.yaml index d612fa71..3691a8b3 100644 --- a/chart/inlets-operator/templates/deployment.yaml +++ b/chart/inlets-operator/templates/deployment.yaml @@ -47,8 +47,8 @@ spec: {{- if .Values.organizationID }} - "-organization-id={{.Values.organizationID}}" {{- end }} - {{- if .Values.inletsClientImage }} - - "-client-image={{.Values.inletsClientImage}}" + {{- if .Values.inletsClient.image }} + - "-client-image={{.Values.inletsClient.image}}" {{- end }} {{- if .Values.inletsRelease }} - "-inlets-release={{.Values.inletsRelease}}" diff --git a/chart/inlets-operator/values.yaml b/chart/inlets-operator/values.yaml index 5170c1b1..e30e5ec4 100644 --- a/chart/inlets-operator/values.yaml +++ b/chart/inlets-operator/values.yaml @@ -12,6 +12,14 @@ region: "lon1" # Required when using a network driver that uses IPVS instead of iptables annotatedOnly: false +# These two versions should match for the client and server +# For the client which will run as a Deployment in Kubernetes +inletsClient: + image: "ghcr.io/inlets/inlets-pro:0.9.31" + +# For the server which will run a binary via systemd +inletsRelease: "0.9.31" + #plan: # provider: "gce" @@ -44,10 +52,6 @@ subnetId: "" image: "ghcr.io/inlets/inlets-operator:0.17.7" pullPolicy: "IfNotPresent" -# These should match -inletsClientImage: "ghcr.io/inlets/inlets-pro:0.9.23" -inletsRelease: "0.9.23" - nameOverride: "" fullnameOverride: "" diff --git a/image_test.go b/image_test.go index be334e10..9b3e0d4e 100644 --- a/image_test.go +++ b/image_test.go @@ -13,7 +13,7 @@ func Test_GetInletsReleaseDefault(t *testing.T) { got := c.GetInletsRelease() - want := "0.9.14" + want := "0.9.31" if got != want { t.Fatalf("want %s, but got %s", want, got) } @@ -24,14 +24,14 @@ func Test_GetInletsReleaseOverride(t *testing.T) { c := InfraConfig{ ProConfig: InletsProConfig{ License: "non-empty", - InletsRelease: "0.9.14", + InletsRelease: "0.9.31", }, AccessKey: "key", } got := c.GetInletsRelease() - want := "0.9.14" + want := "0.9.31" if got != want { t.Fatalf("want %s, but got %s", want, got) @@ -48,7 +48,7 @@ func Test_InletsClientImageDefault(t *testing.T) { } got := c.GetInletsClientImage() - want := "ghcr.io/inlets/inlets-pro:0.9.14" + want := "ghcr.io/inlets/inlets-pro:0.9.31" if got != want { t.Fatalf("want %s, but got %s", want, got) } diff --git a/main.go b/main.go index e63699e8..0b17ce15 100644 --- a/main.go +++ b/main.go @@ -38,7 +38,7 @@ func init() { flag.StringVar(&masterURL, "master", "", "The address of the Kubernetes API server. Overrides any value in kubeconfig. Only required if out-of-cluster.") } -const defaultRelease = "0.9.14" +const defaultRelease = "0.9.31" func main() { infra := &InfraConfig{