From d4153ccf70dd95c59c36b2b4fa456270a5c56505 Mon Sep 17 00:00:00 2001 From: Ansgar Schulte <1299623+ansgarschulte@users.noreply.github.com> Date: Wed, 9 Nov 2022 17:33:12 +0100 Subject: [PATCH 1/4] feat: add onprem license --- charts/steadybit-platform/README.md | 41 ++++++++++--------- charts/steadybit-platform/templates/NOTES.txt | 6 +++ .../templates/deployment.yaml | 5 +++ .../steadybit-platform/templates/secrets.yaml | 13 ++++++ charts/steadybit-platform/values.yaml | 1 + 5 files changed, 46 insertions(+), 20 deletions(-) diff --git a/charts/steadybit-platform/README.md b/charts/steadybit-platform/README.md index 953c572f..4b008e50 100644 --- a/charts/steadybit-platform/README.md +++ b/charts/steadybit-platform/README.md @@ -41,26 +41,27 @@ $ helm show values steadybit-platform The following table lists the configurable parameters of the steadybit platform chart and their default values. -| Key | Type | Default | Description | -|------------------------------|--------|-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------| -| affinity | object | `{}` | Affinities to influence platform pod assignment. | -| image.name | string | `"docker.steadybit.io/steadybit/platform"` | The container image to use of the steadybit platform. | -| image.pullPolicy | string | `"Always"` | Specifies when to pull the image container. | -| image.tag | string | `"latest"` | Tag name of the platform container image to use. | -| ingress | object | `{"annotations":null,"enabled":true,"hosts":[]}` | Ingress configuration properties | -| nodeSelector | object | `{}` | Node labels for pod assignment | -| platform.env | array | `[{"name:", "STEADYBIT_AUTH_PROVIDER", "value": "static"},{"name":"STEADYBIT_AUTH_STATIC_0_PASSWORD", "value": "{noop}admin"},{"name":"STEADYBIT_AUTH_STATIC_0_USERNAME", "value":"admin"}]` | Use this to set additional environment variables See https://docs.steadybit.io/installation-platform/3-advanced-configuration. | -| platform.extraLabels | object | `{}` | Additional labels | -| platform.tenant.key | string | `"onprem"` | Name for the tenant assigned to you. | -| platform.tenant.agentKey | string | `nil` | The secret token which your agent uses to authenticate to steadybit's servers. Get it from https://platform.steadybit.io/settings/agents/setup. | -| platform.tenant.name | string | `"onprem"` | Key for the tenant assigned to you. | -| platform.uiPort | int | `80` | (internal) Web-UI port for the user interface. | -| platform.websocketPort | int | `7878` | (internal) Websocket port for communication between platform and agents. | -| platform.publicWebsocketPort | int | `80` | The public port used for experiments - Use this if the agent access the websocket via ingress or a reverse proxy, that serves websocket and http traffic using the same port | -| platform.service.type | string | `NodePort` | Service Type to use for the platform | -| podAnnotations | object | `{}` | Additional annotations to be added to the platform pod. | -| serviceAccount.create | bool | `true` | Specifies whether a ServiceAccount should be created. | -| tolerations | list | `[]` | Tolerations to influence platform pod assignment. | +| Key | Type | Default | Description | +|------------------------------|--------|----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------| +| affinity | object | `{}` | Affinities to influence platform pod assignment. | +| image.name | string | `"docker.steadybit.io/steadybit/platform"` | The container image to use of the steadybit platform. | +| image.pullPolicy | string | `"Always"` | Specifies when to pull the image container. | +| image.tag | string | `"latest"` | Tag name of the platform container image to use. | +| ingress | object | `{"annotations":null,"enabled":true,"hosts":[]}` | Ingress configuration properties | +| nodeSelector | object | `{}` | Node labels for pod assignment | +| platform.env | array | `[{"name:", "STEADYBIT_AUTH_PROVIDER", "value": "static"},{"name":"STEADYBIT_AUTH_STATIC_0_PASSWORD", "value": "{noop}admin"},{"name":"STEADYBIT_AUTH_STATIC_0_USERNAME", "value":"admin"}]` | Use this to set additional environment variables See https://docs.steadybit.io/installation-platform/3-advanced-configuration. | +| platform.extraLabels | object | `{}` | Additional labels | +| platform.tenant.key | string | `"onprem"` | Name for the tenant assigned to you. | +| platform.tenant.agentKey | string | `nil` | The secret token which your agent uses to authenticate to steadybit's servers. Get it from https://platform.steadybit.io/settings/agents/setup. | +| platform.tenant.name | string | `"onprem"` | Key for the tenant assigned to you. | +| platform.tenant.license | string | `nil` | Key for the tenant assigned to you. | +| platform.uiPort | int | `80` | (internal) Web-UI port for the user interface. | +| platform.websocketPort | int | `7878` | (internal) Websocket port for communication between platform and agents. | +| platform.publicWebsocketPort | int | `80` | The public port used for experiments - Use this if the agent access the websocket via ingress or a reverse proxy, that serves websocket and http traffic using the same port | +| platform.service.type | string | `NodePort` | Service Type to use for the platform | +| podAnnotations | object | `{}` | Additional annotations to be added to the platform pod. | +| serviceAccount.create | bool | `true` | Specifies whether a ServiceAccount should be created. | +| tolerations | list | `[]` | Tolerations to influence platform pod assignment. | ### YAML file diff --git a/charts/steadybit-platform/templates/NOTES.txt b/charts/steadybit-platform/templates/NOTES.txt index 0a34bb05..72076190 100644 --- a/charts/steadybit-platform/templates/NOTES.txt +++ b/charts/steadybit-platform/templates/NOTES.txt @@ -4,6 +4,12 @@ #### ERROR: You did not specify your secret agent key (platform.tenant.agentKey). #### ################################################################################## +{{- else if not .Values.platform.tenant.license -}} + +################################################################################## +#### ERROR: You did not specify your license key (platform.tenant.license). #### +################################################################################## + {{- else -}} The steadybit platform server can be accessed via port {{ .Values.platform.uiPort }} on the following DNS name from within your cluster: diff --git a/charts/steadybit-platform/templates/deployment.yaml b/charts/steadybit-platform/templates/deployment.yaml index 73208422..31b82c7a 100644 --- a/charts/steadybit-platform/templates/deployment.yaml +++ b/charts/steadybit-platform/templates/deployment.yaml @@ -110,6 +110,11 @@ spec: value: {{ .Values.platform.tenant.key | quote }} - name: STEADYBIT_TENANT_NAME value: {{ .Values.platform.tenant.name | quote }} + - name: STEADYBIT_TENANT_LICENSE + valueFrom: + secretKeyRef: + name: {{ template "steadybit-platform.fullname" . }}-license + key: license {{- end }} - name: STEADYBIT_WEB_PUBLIC_EXPERIMENT_PORT value: {{ .Values.platform.publicWebsocketPort | quote }} diff --git a/charts/steadybit-platform/templates/secrets.yaml b/charts/steadybit-platform/templates/secrets.yaml index 2335ad62..ea8f4b62 100644 --- a/charts/steadybit-platform/templates/secrets.yaml +++ b/charts/steadybit-platform/templates/secrets.yaml @@ -21,4 +21,17 @@ type: Opaque data: {{- if .Values.platform.tenant.agentKey }} key: {{ .Values.platform.tenant.agentKey | b64enc | quote }} + {{- end }} +--- +apiVersion: v1 +kind: Secret +metadata: + name: {{ template "steadybit-platform.fullname" . }}-license + namespace: {{ .Release.Namespace }} + labels: + {{- include "steadybit-platform.commonLabels" . | nindent 4 }} +type: Opaque +data: + {{- if .Values.platform.tenant.license }} + license: {{ .Values.platform.tenant.license | b64enc | quote }} {{- end }} \ No newline at end of file diff --git a/charts/steadybit-platform/values.yaml b/charts/steadybit-platform/values.yaml index bcbb2c89..a108fdae 100644 --- a/charts/steadybit-platform/values.yaml +++ b/charts/steadybit-platform/values.yaml @@ -10,6 +10,7 @@ platform: name: onprem # -- The secret token which your agent uses to authenticate to steadybit's servers. Get it from https://platform.steadybit.io/settings/agents/setup. agentKey: null + license: null agent: auth: # platform.tenant.agent.auth.provider -- Default is `agent-key`. Use `oauth2` if you like to use oauth2 authenication From 1d37cc08beccfc2062e042a18210441f251fa4ab Mon Sep 17 00:00:00 2001 From: Ansgar Schulte <1299623+ansgarschulte@users.noreply.github.com> Date: Wed, 9 Nov 2022 17:42:15 +0100 Subject: [PATCH 2/4] chore: version bump --- charts/steadybit-platform/Chart.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/charts/steadybit-platform/Chart.yaml b/charts/steadybit-platform/Chart.yaml index ed17a54d..293a5c5a 100644 --- a/charts/steadybit-platform/Chart.yaml +++ b/charts/steadybit-platform/Chart.yaml @@ -1,7 +1,7 @@ apiVersion: v2 name: steadybit-platform description: steadybit Platform Helm chart for Kubernetes. -version: 0.6.1 +version: 0.6.2 appVersion: latest home: https://www.steadybit.com/ icon: https://steadybit-website-assets.s3.amazonaws.com/logo-symbol-transparent.png From 28d42a9917ec39cbde66eba6eaf212c5a7b57b3e Mon Sep 17 00:00:00 2001 From: Ansgar Schulte <1299623+ansgarschulte@users.noreply.github.com> Date: Fri, 25 Oct 2024 11:32:56 +0200 Subject: [PATCH 3/4] chore: reformat table --- charts/steadybit-platform/README.md | 42 ++++++++++++++--------------- 1 file changed, 21 insertions(+), 21 deletions(-) diff --git a/charts/steadybit-platform/README.md b/charts/steadybit-platform/README.md index 052005ba..adb2f3a4 100644 --- a/charts/steadybit-platform/README.md +++ b/charts/steadybit-platform/README.md @@ -41,27 +41,27 @@ $ helm show values steadybit-platform The following table lists the configurable parameters of the steadybit platform chart and their default values. -| Key | Type | Default | Description | -|------------------------------|--------|----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------| -| affinity | object | `{}` | Affinities to influence platform pod assignment. | -| image.name | string | `"docker.steadybit.io/steadybit/platform"` | The container image to use of the steadybit platform. | -| image.pullPolicy | string | `"Always"` | Specifies when to pull the image container. | -| image.tag | string | `"latest"` | Tag name of the platform container image to use. | -| ingress | object | `{"annotations":null,"enabled":true,"hosts":[]}` | Ingress configuration properties | -| nodeSelector | object | `{}` | Node labels for pod assignment | -| platform.env | array | `[{"name:", "STEADYBIT_AUTH_PROVIDER", "value": "static"},{"name":"STEADYBIT_AUTH_STATIC_0_PASSWORD", "value": "{noop}admin"},{"name":"STEADYBIT_AUTH_STATIC_0_USERNAME", "value":"admin"}]` | Use this to set additional environment variables See https://docs.steadybit.io/installation-platform/3-advanced-configuration. | -| platform.extraLabels | object | `{}` | Additional labels | -| platform.tenant.key | string | `"onprem"` | Name for the tenant assigned to you. | -| platform.tenant.agentKey | string | `nil` | The secret token which your agent uses to authenticate to steadybit's servers. Get it from https://platform.steadybit.io/settings/agents/setup. | -| platform.tenant.name | string | `"onprem"` | Key for the tenant assigned to you. | -| platform.tenant.license | string | `nil` | Key for the tenant assigned to you. | -| platform.uiPort | int | `80` | (internal) Web-UI port for the user interface. | -| platform.websocketPort | int | `7878` | (internal) Websocket port for communication between platform and agents. | -| platform.publicWebsocketPort | int | `80` | The public port used for experiments - Use this if the agent access the websocket via ingress or a reverse proxy, that serves websocket and http traffic using the same port | -| platform.service.type | string | `NodePort` | Service Type to use for the platform | -| podAnnotations | object | `{}` | Additional annotations to be added to the platform pod. | -| serviceAccount.create | bool | `true` | Specifies whether a ServiceAccount should be created. | -| tolerations | list | `[]` | Tolerations to influence platform pod assignment. | +| Key | Type | Default | Description | +|------------------------------|--------|----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|------------------------------------------------------------------------------------------------------------------------------------------------------------------------------| +| affinity | object | `{}` | Affinities to influence platform pod assignment. | +| image.name | string | `"docker.steadybit.io/steadybit/platform"` | The container image to use of the steadybit platform. | +| image.pullPolicy | string | `"Always"` | Specifies when to pull the image container. | +| image.tag | string | `"latest"` | Tag name of the platform container image to use. | +| ingress | object | `{"annotations":null,"enabled":true,"hosts":[]}` | Ingress configuration properties | +| nodeSelector | object | `{}` | Node labels for pod assignment | +| platform.env | array | `[{"name:", "STEADYBIT_AUTH_PROVIDER", "value": "static"},{"name":"STEADYBIT_AUTH_STATIC_0_PASSWORD", "value": "{noop}admin"},{"name":"STEADYBIT_AUTH_STATIC_0_USERNAME", "value":"admin"}]` | Use this to set additional environment variables See https://docs.steadybit.io/installation-platform/3-advanced-configuration. | +| platform.extraLabels | object | `{}` | Additional labels | +| platform.tenant.key | string | `"onprem"` | Name for the tenant assigned to you. | +| platform.tenant.agentKey | string | `nil` | The secret token which your agent uses to authenticate to steadybit's servers. Get it from https://platform.steadybit.io/settings/agents/setup. | +| platform.tenant.name | string | `"onprem"` | Key for the tenant assigned to you. | +| platform.tenant.license | string | `nil` | Key for the tenant assigned to you. | +| platform.uiPort | int | `80` | (internal) Web-UI port for the user interface. | +| platform.websocketPort | int | `7878` | (internal) Websocket port for communication between platform and agents. | +| platform.publicWebsocketPort | int | `80` | The public port used for experiments - Use this if the agent access the websocket via ingress or a reverse proxy, that serves websocket and http traffic using the same port | +| platform.service.type | string | `NodePort` | Service Type to use for the platform | +| podAnnotations | object | `{}` | Additional annotations to be added to the platform pod. | +| serviceAccount.create | bool | `true` | Specifies whether a ServiceAccount should be created. | +| tolerations | list | `[]` | Tolerations to influence platform pod assignment. | ### YAML file From 42e67839e1e7959bf08ac237db7b28aa2c3dc552 Mon Sep 17 00:00:00 2001 From: Ansgar Schulte <1299623+ansgarschulte@users.noreply.github.com> Date: Mon, 25 Nov 2024 12:49:25 +0100 Subject: [PATCH 4/4] feat: license file is optional --- charts/steadybit-platform/templates/NOTES.txt | 6 ------ charts/steadybit-platform/templates/deployment.yaml | 2 ++ charts/steadybit-platform/templates/secrets.yaml | 4 ++-- 3 files changed, 4 insertions(+), 8 deletions(-) diff --git a/charts/steadybit-platform/templates/NOTES.txt b/charts/steadybit-platform/templates/NOTES.txt index 7aa936ef..748f8ac2 100644 --- a/charts/steadybit-platform/templates/NOTES.txt +++ b/charts/steadybit-platform/templates/NOTES.txt @@ -4,12 +4,6 @@ #### ERROR: You did not specify your secret agent key (platform.tenant.agentKey). #### ################################################################################## -{{- else if not .Values.platform.tenant.license -}} - -################################################################################## -#### ERROR: You did not specify your license key (platform.tenant.license). #### -################################################################################## - {{- else -}} The steadybit platform server can be accessed via port {{ .Values.platform.uiPort }} on the following DNS name from within your cluster: diff --git a/charts/steadybit-platform/templates/deployment.yaml b/charts/steadybit-platform/templates/deployment.yaml index 4957cc1d..28a8ef0c 100644 --- a/charts/steadybit-platform/templates/deployment.yaml +++ b/charts/steadybit-platform/templates/deployment.yaml @@ -186,12 +186,14 @@ spec: value: {{ .Values.platform.tenant.key | quote }} - name: STEADYBIT_TENANT_NAME value: {{ .Values.platform.tenant.name | quote }} + {{- if .Values.platform.tenant.license }} - name: STEADYBIT_TENANT_LICENSE valueFrom: secretKeyRef: name: {{ template "steadybit-platform.fullname" . }}-license key: license {{- end }} + {{- end }} {{- if .Values.platform.publicWebUrl }} - name: STEADYBIT_WEB_PUBLIC_URL value: {{ .Values.platform.publicWebUrl }} diff --git a/charts/steadybit-platform/templates/secrets.yaml b/charts/steadybit-platform/templates/secrets.yaml index ea8f4b62..0995a7a1 100644 --- a/charts/steadybit-platform/templates/secrets.yaml +++ b/charts/steadybit-platform/templates/secrets.yaml @@ -23,6 +23,7 @@ data: key: {{ .Values.platform.tenant.agentKey | b64enc | quote }} {{- end }} --- +{{- if .Values.platform.tenant.license }} apiVersion: v1 kind: Secret metadata: @@ -32,6 +33,5 @@ metadata: {{- include "steadybit-platform.commonLabels" . | nindent 4 }} type: Opaque data: - {{- if .Values.platform.tenant.license }} license: {{ .Values.platform.tenant.license | b64enc | quote }} - {{- end }} \ No newline at end of file +{{- end }} \ No newline at end of file