Skip to content

Commit

Permalink
chore(console): improve documentation & values (#10)
Browse files Browse the repository at this point in the history
* Fix license with secrets
* Add additional snippet for configuration
* Add annotations to put checksum on deployment
---------

Signed-off-by: ConduktorBot <[email protected]>
Co-authored-by: ConduktorBot <[email protected]>
  • Loading branch information
Alexandre Burgoni and ConduktorBot authored Sep 6, 2023
1 parent 99e8407 commit b6f244b
Show file tree
Hide file tree
Showing 5 changed files with 53 additions and 11 deletions.
2 changes: 1 addition & 1 deletion charts/console/Chart.yaml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
apiVersion: v2
name: console
appVersion: 1.17.3
version: 1.1.0
version: 1.1.1
description: Helm chart to deploy Conduktor Platform on Kubernetes
icon: https://www.conduktor.io/svgs/logo/symbol.svg
home: https://www.conduktor.io
Expand Down
43 changes: 38 additions & 5 deletions charts/console/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -204,15 +204,16 @@ console, we recommend you to look at our
### Kubernetes configuration

- [Install with a PodAffinity](#install-with-a-podaffinity)
- [Install with a PodAntiAffinity](#install-with-a-podantiaffinity)
- [Install with a Toleration](#install-with-a-toleration)
- [Install with a Self-Signed Certificate](#install-with-self-signed-tls-certificate)
- [Install with a custom service account](#install-with-a-custom-service-account)
- [Install with a AWS EKS IAM Role](#install-with-a-aws-eks-iam-role)

- [Provide credentials as a Kubernetes Secret](#provide-credentials-configuration-as-a-kubernetes-secret)
- [Provide the license as a Kubernetes Secret](#provide-the-license-as-a-kubernetes-secret)
- [Provide the license as a Kubernetes ConfigMap](#provide-the-platform-config-as-a-kubernetes-configmap)
- [Provide the license as a Kubernetes ConfigMap](#provide-console-configuration-as-a-kubernetes-configmap)

- [Provide additional credentials as a Kubernetes Secret](#provide-additional-credentials-as-a-kubernetes-secret)

### Install with an enterprise license

Expand Down Expand Up @@ -294,10 +295,11 @@ config:
### Provide the license as a Kubernetes Secret
We expect the secret to contain a key named `license` which contains your
license key.
This snippet expects that a *Kubernetes Secret Resource* already exists inside
your cluster with a key named `license` containing your license key.


```shell
```yaml
# values.yaml
config:
organization:
Expand Down Expand Up @@ -384,6 +386,37 @@ platform:
existingConfigMap: "<your_configmap_name>"
```

### Provide additional credentials as a Kubernetes Secret

In case our helm chart doesn't protect all the credentials you need, you can
use this method to provide additional credentials through a Kubernetes
Secret Resource you previously created. You can have this case for LDAP
credentials, or for SSO credentials for example.

The keys of your secret will be used as environment variables in the
console pod. Be sure to check available [environment variables](https://docs.conduktor.io/platform/configuration/env-variables/)
in our documentation.

```yaml
config:
organization:
name: "my-org"
admin:
email: "[email protected]"
password: "admin"
database:
host: ''
port: 5432
name: 'postgres'
username: ''
password: ''
platform:
extraEnvVarsSecret: "<your_secret_name>"
```

### Install with a toleration

```yaml
Expand Down
2 changes: 1 addition & 1 deletion charts/console/templates/NOTES.txt
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ Conduktor Platform will be accessible at : http://127.0.0.1:8080

To connect use following admin account ADMIN_LOGIN and ADMIN_PASSWORD

ADMIN_LOGIN="{{ .Values.config.admin.email }}"
ADMIN_LOGIN="{{ include "common.secrets.lookup" (dict "secret" (include "conduktor.platform.secretName" .) "key" "CDK_ADMIN_EMAIL" "defaultValue" .Values.config.admin.email "context" $) | b64dec }}"
ADMIN_PASSWORD="$(kubectl get secret {{ include "conduktor.platform.secretName" . }} -n {{ .Release.Namespace }} -o jsonpath="{.data.CDK_ADMIN_PASSWORD}" | base64 --decode)"

More details on Platform configuration are available at https://docs.conduktor.io/platform/
Expand Down
6 changes: 6 additions & 0 deletions charts/console/templates/platform/deployment.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,12 @@ spec:
{{- include "common.tplvalues.render" (dict "value" .Values.platform.podAnnotations "context" $) | nindent 8 }}
{{- end }}
checksum/config: {{ include (print $.Template.BasePath "/platform/configmap.yaml") . | sha256sum }}
{{- if not .Values.config.existingSecret }}
checksum/credentials: {{ include (print $.Template.BasePath "/platform/secret-credentials.yaml") . | sha256sum }}
{{- end }}
{{- if and .Values.config.license (not .Values.config.existingLicenseSecret) }}
checksum/license: {{ include (print $.Template.BasePath "/platform/secret-license.yaml") . | sha256sum }}
{{- end }}
labels: {{- include "common.labels.standard" . | nindent 8 }}
app.kubernetes.io/component: conduktor-platform
{{- if .Values.platform.podLabels }}
Expand Down
11 changes: 7 additions & 4 deletions charts/console/values.yaml
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
## @section Global parameters
## @descriptionStart
## @descriptionStart
## Global Docker image parameters
## Please, note that this will override the image parameters, including dependencies, configured to use the global value
## Current available global Docker image parameters: imageRegistry, imagePullSecrets and storageClass
Expand Down Expand Up @@ -59,7 +59,7 @@ diagnosticMode:
- infinity

## @section Platform product Parameters
## @descriptionStart
## @descriptionStart
## You can paste here your Conduktor Platform Configuration
##
## Refer to our [documentation](https://docs.conduktor.io/platform/configuration/env-variables/) for the full list of product configuration properties.
Expand All @@ -85,15 +85,15 @@ config:
host: ''
port: 5432
name: 'postgres'
username: ''
password: ''
username: ''

## @param config.license Conduktor Platform Enterprise license, if none given, the product will run in free tier
license: ""

## @param config.existingLicenseSecret Name of an existing secret containing the license
##
## Secret should just contain key "license" with the license as value
## Secret should just contain key "CDK_LICENSE" with the license as value
## NOTE: 'config.license' will be ignored
existingLicenseSecret: ""

Expand Down Expand Up @@ -341,16 +341,19 @@ platform:
##
lifecycleHooks: {}
## @param platform.extraEnvVars Array with extra environment variables to add to Conduktor Platform nodes
## ref: https://docs.conduktor.io/platform/configuration/env-variables/
## e.g:
## extraEnvVars:
## - name: FOO
## value: "bar"
##
extraEnvVars: []
## @param platform.extraEnvVarsCM Name of existing ConfigMap containing extra env vars for Conduktor Platform nodes
## ref: https://docs.conduktor.io/platform/configuration/env-variables/
##
extraEnvVarsCM: ""
## @param platform.extraEnvVarsSecret Name of existing Secret containing extra env vars for Conduktor Platform nodes
## ref: https://docs.conduktor.io/platform/configuration/env-variables/
##
extraEnvVarsSecret: ""
## @param platform.extraVolumes Optionally specify extra list of additional volumes for the Conduktor Platform pod(s)
Expand Down

0 comments on commit b6f244b

Please sign in to comment.