Compare commits
8 Commits
bf8382c840
...
main
| Author | SHA1 | Date | |
|---|---|---|---|
| 363946b064 | |||
| 1b93a9612d | |||
| f4d9561330 | |||
| c724a38dda | |||
| 505e34223a | |||
| 3868575669 | |||
| 6c363adf2d | |||
| 0a93c9a444 |
@@ -4,13 +4,13 @@ on:
|
||||
branches:
|
||||
- main
|
||||
paths:
|
||||
- "charts/keycloak/Chart.yaml"
|
||||
- "charts/paperless-ngx/Chart.yaml"
|
||||
|
||||
jobs:
|
||||
helm-package:
|
||||
runs-on: ubuntu-latest
|
||||
env:
|
||||
APP: charts/keycloak
|
||||
APP: charts/paperless-ngx
|
||||
steps:
|
||||
- name: Checkout repository
|
||||
uses: actions/checkout@v3
|
||||
@@ -2,8 +2,8 @@ apiVersion: v2
|
||||
name: audiobookshelf
|
||||
description: A Helm chart for Audiobookshelf
|
||||
type: application
|
||||
version: 1.10.0
|
||||
appVersion: "2.29.0"
|
||||
version: 1.11.0
|
||||
appVersion: "2.30.0"
|
||||
home: https://git.cooltux.net/marko/HelmChartSammlung/src/branch/main/charts/audiobookshelf
|
||||
keywords:
|
||||
- audiobookshelf
|
||||
|
||||
@@ -8,16 +8,16 @@ annotations:
|
||||
- name: apache-exporter
|
||||
image: docker.io/bitnami/apache-exporter:1.0.10-debian-12-r5
|
||||
- name: dokuwiki
|
||||
image: git.cooltux.net/marko/docker-dokuwiki-debian12:20250516-debian-12
|
||||
image: git.cooltux.net/marko/docker-dokuwiki-debian12:20251031
|
||||
- name: os-shell
|
||||
image: docker.io/bitnami/os-shell:12-debian-12-r43
|
||||
apiVersion: v2
|
||||
dependencies:
|
||||
- name: common
|
||||
repository: oci://registry-1.docker.io/bitnamicharts
|
||||
tags:
|
||||
- bitnami-common
|
||||
version: 2.x.x
|
||||
- name: common
|
||||
repository: oci://registry-1.docker.io/bitnamicharts
|
||||
tags:
|
||||
- bitnami-common
|
||||
version: 2.x.x
|
||||
description: DokuWiki is a standards-compliant wiki optimized for creating documentation. Designed to be simple to use for small organizations, it stores all data in plain text files so no database is required.
|
||||
home: https://bitnami.com
|
||||
icon: https://bitnami.com/assets/stacks/dokuwiki/img/dokuwiki-stack-220x234.png
|
||||
@@ -32,5 +32,5 @@ maintainers: []
|
||||
name: dokuwiki
|
||||
sources:
|
||||
- https://git.cooltux.net/Interne-Entwicklungen/TuxNet-helm-charts.git/dokuwiki
|
||||
version: 1.2.0
|
||||
appVersion: "20250918-debian-12"
|
||||
version: 1.2.1
|
||||
appVersion: "20251031"
|
||||
|
||||
@@ -70,7 +70,7 @@ extraDeploy: []
|
||||
image:
|
||||
registry: git.cooltux.net
|
||||
repository: marko/docker-dokuwiki-debian12
|
||||
tag: "20250918-debian-12"
|
||||
tag: "20251031"
|
||||
digest: ""
|
||||
## Specify a imagePullPolicy
|
||||
## Defaults to 'Always' if image tag is 'latest', else set to 'IfNotPresent'
|
||||
|
||||
File diff suppressed because it is too large
Load Diff
@@ -1,9 +0,0 @@
|
||||
dependencies:
|
||||
- name: postgresql
|
||||
repository: oci://registry-1.docker.io/bitnamicharts
|
||||
version: 16.7.24
|
||||
- name: common
|
||||
repository: oci://registry-1.docker.io/bitnamicharts
|
||||
version: 2.31.3
|
||||
digest: sha256:d8069a70d0f19ff31989b0755d92997aae49301596058d679b002f678315ab9e
|
||||
generated: "2025-08-10T11:18:09.390206634+02:00"
|
||||
@@ -1,40 +0,0 @@
|
||||
# Copyright Broadcom, Inc. All Rights Reserved.
|
||||
# SPDX-License-Identifier: APACHE-2.0
|
||||
|
||||
annotations:
|
||||
category: DeveloperTools
|
||||
images: |
|
||||
- name: keycloak
|
||||
image: docker.io/bitnami/keycloak:26.3.2-debian-12-r1
|
||||
- name: keycloak-config-cli
|
||||
image: docker.io/bitnami/keycloak-config-cli:6.4.0-debian-12-r11
|
||||
licenses: Apache-2.0
|
||||
tanzuCategory: application
|
||||
apiVersion: v2
|
||||
appVersion: 26.3.2
|
||||
dependencies:
|
||||
- condition: postgresql.enabled
|
||||
name: postgresql
|
||||
repository: oci://registry-1.docker.io/bitnamicharts
|
||||
version: 16.x.x
|
||||
- name: common
|
||||
repository: oci://registry-1.docker.io/bitnamicharts
|
||||
tags:
|
||||
- bitnami-common
|
||||
version: 2.x.x
|
||||
description:
|
||||
Keycloak is a high performance Java-based identity and access management
|
||||
solution. It lets developers add an authentication layer to their applications with
|
||||
minimum effort.
|
||||
home: https://bitnami.com
|
||||
icon: https://dyltqmyl993wv.cloudfront.net/assets/stacks/keycloak/img/keycloak-stack-220x234.png
|
||||
keywords:
|
||||
- keycloak
|
||||
- access-management
|
||||
maintainers:
|
||||
- name: Broadcom, Inc. All Rights Reserved.
|
||||
url: https://github.com/bitnami/charts
|
||||
name: keycloak
|
||||
sources:
|
||||
- https://github.com/bitnami/charts/tree/main/bitnami/keycloak
|
||||
version: 24.9.1
|
||||
@@ -1,883 +0,0 @@
|
||||
<!--- app-name: Keycloak -->
|
||||
|
||||
# Bitnami package for Keycloak
|
||||
|
||||
Keycloak is a high performance Java-based identity and access management solution. It lets developers add an authentication layer to their applications with minimum effort.
|
||||
|
||||
[Overview of Keycloak](https://www.keycloak.org/)
|
||||
|
||||
Trademarks: This software listing is packaged by Bitnami. The respective trademarks mentioned in the offering are owned by the respective companies, and use of them does not imply any affiliation or endorsement.
|
||||
|
||||
## TL;DR
|
||||
|
||||
```console
|
||||
helm install my-release oci://registry-1.docker.io/bitnamicharts/keycloak
|
||||
```
|
||||
|
||||
Looking to use Keycloak in production? Try [VMware Tanzu Application Catalog](https://bitnami.com/enterprise), the commercial edition of the Bitnami catalog.
|
||||
|
||||
## ⚠️ Important Notice: Upcoming changes to the Bitnami Catalog
|
||||
|
||||
Beginning August 28th, 2025, Bitnami will evolve its public catalog to offer a curated set of hardened, security-focused images under the new [Bitnami Secure Images initiative](https://news.broadcom.com/app-dev/broadcom-introduces-bitnami-secure-images-for-production-ready-containerized-applications). As part of this transition:
|
||||
|
||||
- Granting community users access for the first time to security-optimized versions of popular container images.
|
||||
- Bitnami will begin deprecating support for non-hardened, Debian-based software images in its free tier and will gradually remove non-latest tags from the public catalog. As a result, community users will have access to a reduced number of hardened images. These images are published only under the “latest” tag and are intended for development purposes
|
||||
- Starting August 28th, over two weeks, all existing container images, including older or versioned tags (e.g., 2.50.0, 10.6), will be migrated from the public catalog (docker.io/bitnami) to the “Bitnami Legacy” repository (docker.io/bitnamilegacy), where they will no longer receive updates.
|
||||
- For production workloads and long-term support, users are encouraged to adopt Bitnami Secure Images, which include hardened containers, smaller attack surfaces, CVE transparency (via VEX/KEV), SBOMs, and enterprise support.
|
||||
|
||||
These changes aim to improve the security posture of all Bitnami users by promoting best practices for software supply chain integrity and up-to-date deployments. For more details, visit the [Bitnami Secure Images announcement](https://github.com/bitnami/containers/issues/83267).
|
||||
|
||||
## Introduction
|
||||
|
||||
Bitnami charts for Helm are carefully engineered, actively maintained and are the quickest and easiest way to deploy containers on a Kubernetes cluster that are ready to handle production workloads.
|
||||
|
||||
This chart bootstraps a [Keycloak](https://github.com/bitnami/containers/tree/main/bitnami/keycloak) deployment on a [Kubernetes](https://kubernetes.io) cluster using the [Helm](https://helm.sh) package manager.
|
||||
|
||||
## Prerequisites
|
||||
|
||||
- Kubernetes 1.23+
|
||||
- Helm 3.8.0+
|
||||
|
||||
## Installing the Chart
|
||||
|
||||
To install the chart with the release name `my-release`:
|
||||
|
||||
```console
|
||||
helm install my-release oci://REGISTRY_NAME/REPOSITORY_NAME/keycloak
|
||||
```
|
||||
|
||||
> Note: You need to substitute the placeholders `REGISTRY_NAME` and `REPOSITORY_NAME` with a reference to your Helm chart registry and repository. For example, in the case of Bitnami, you need to use `REGISTRY_NAME=registry-1.docker.io` and `REPOSITORY_NAME=bitnamicharts`.
|
||||
|
||||
These commands deploy a Keycloak application on the Kubernetes cluster in the default configuration.
|
||||
|
||||
> **Tip**: List all releases using `helm list`
|
||||
|
||||
## Configuration and installation details
|
||||
|
||||
### Resource requests and limits
|
||||
|
||||
Bitnami charts allow setting resource requests and limits for all containers inside the chart deployment. These are inside the `resources` value (check parameter table). Setting requests is essential for production workloads and these should be adapted to your specific use case.
|
||||
|
||||
To make this process easier, the chart contains the `resourcesPreset` values, which automatically sets the `resources` section according to different presets. Check these presets in [the bitnami/common chart](https://github.com/bitnami/charts/blob/main/bitnami/common/templates/_resources.tpl#L15). However, in production workloads using `resourcesPreset` is discouraged as it may not fully adapt to your specific needs. Find more information on container resource management in the [official Kubernetes documentation](https://kubernetes.io/docs/concepts/configuration/manage-resources-containers/).
|
||||
|
||||
### Prometheus metrics
|
||||
|
||||
This chart can be integrated with Prometheus by setting `metrics.enabled` to `true`. This will expose Keycloak native Prometheus endpoint in a `metrics` service, which can be configured under the `metrics.service` section. It will have the necessary annotations to be automatically scraped by Prometheus.
|
||||
|
||||
#### Prometheus requirements
|
||||
|
||||
It is necessary to have a working installation of Prometheus or Prometheus Operator for the integration to work. Install the [Bitnami Prometheus helm chart](https://github.com/bitnami/charts/tree/main/bitnami/prometheus) or the [Bitnami Kube Prometheus helm chart](https://github.com/bitnami/charts/tree/main/bitnami/kube-prometheus) to easily have a working Prometheus in your cluster.
|
||||
|
||||
#### Integration with Prometheus Operator
|
||||
|
||||
The chart can deploy `ServiceMonitor` objects for integration with Prometheus Operator installations. To do so, set the value `metrics.serviceMonitor.enabled=true`. Ensure that the Prometheus Operator `CustomResourceDefinitions` are installed in the cluster or it will fail with the following error:
|
||||
|
||||
```text
|
||||
no matches for kind "ServiceMonitor" in version "monitoring.coreos.com/v1"
|
||||
```
|
||||
|
||||
Install the [Bitnami Kube Prometheus helm chart](https://github.com/bitnami/charts/tree/main/bitnami/kube-prometheus) for having the necessary CRDs and the Prometheus Operator.
|
||||
|
||||
### [Rolling vs Immutable tags](https://techdocs.broadcom.com/us/en/vmware-tanzu/application-catalog/tanzu-application-catalog/services/tac-doc/apps-tutorials-understand-rolling-tags-containers-index.html)
|
||||
|
||||
It is strongly recommended to use immutable tags in a production environment. This ensures your deployment does not change automatically if the same tag is updated with a different image.
|
||||
|
||||
Bitnami will release a new chart updating its containers if a new version of the main container, significant changes, or critical vulnerabilities exist.
|
||||
|
||||
### Update credentials
|
||||
|
||||
Bitnami charts configure credentials at first boot. Any further change in the secrets or credentials require manual intervention. Follow these instructions:
|
||||
|
||||
- Update the user password following [the upstream documentation](https://www.keycloak.org/server/configuration)
|
||||
- Update the password secret with the new values (replace the SECRET_NAME and PASSWORD placeholders)
|
||||
|
||||
```shell
|
||||
kubectl create secret generic SECRET_NAME --from-literal=admin-password=PASSWORD --dry-run -o yaml | kubectl apply -f -
|
||||
```
|
||||
|
||||
### Use an external database
|
||||
|
||||
Sometimes, you may want to have Keycloak connect to an external PostgreSQL database rather than a database within your cluster - for example, when using a managed database service, or when running a single database server for all your applications. To do this, set the `postgresql.enabled` parameter to `false` and specify the credentials for the external database using the `externalDatabase.*` parameters. Here is an example:
|
||||
|
||||
```text
|
||||
postgresql.enabled=false
|
||||
externalDatabase.host=myexternalhost
|
||||
externalDatabase.user=myuser
|
||||
externalDatabase.password=mypassword
|
||||
externalDatabase.database=mydatabase
|
||||
externalDatabase.port=5432
|
||||
externalDatabase.schema=public
|
||||
```
|
||||
|
||||
> NOTE: Only PostgreSQL database server is supported as external database
|
||||
|
||||
It is not supported but possible to run Keycloak with an external MSSQL database with the following settings:
|
||||
|
||||
```yaml
|
||||
externalDatabase:
|
||||
host: "mssql.example.com"
|
||||
port: 1433
|
||||
user: keycloak
|
||||
database: keycloak
|
||||
existingSecret: passwords
|
||||
extraEnvVars:
|
||||
- name: KC_DB # override values from the conf file
|
||||
value: 'mssql'
|
||||
- name: KC_DB_URL
|
||||
value: 'jdbc:sqlserver://mssql.example.com:1433;databaseName=keycloak;'
|
||||
```
|
||||
|
||||
### Importing and exporting a realm
|
||||
|
||||
#### Importing a realm
|
||||
|
||||
You can import a realm by setting the `KEYCLOAK_EXTRA_ARGS` to contain the `--import-realm` argument.
|
||||
|
||||
This will import all `*.json` under `/opt/bitnami/keycloak/data/import` files as a realm into keycloak as per the
|
||||
official documentation [here](https://www.keycloak.org/server/importExport#_importing_a_realm_from_a_directory). You
|
||||
can supply the files by mounting a volume e.g. with docker compose as follows:
|
||||
|
||||
```yaml
|
||||
keycloak:
|
||||
image: bitnami/keycloak:latest
|
||||
volumes:
|
||||
- /local/path/to/realms/folder:/opt/bitnami/keycloak/data/import
|
||||
```
|
||||
|
||||
#### Exporting a realm
|
||||
|
||||
You can export a realm through the GUI but it will not export users even the option is set, this is a known keycloak
|
||||
[bug](https://github.com/keycloak/keycloak/issues/23970).
|
||||
|
||||
By using the `kc.sh` script you can export a realm with users. Be sure to mount the export folder to a local folder:
|
||||
|
||||
```yaml
|
||||
keycloak:
|
||||
image: bitnami/keycloak:latest
|
||||
volumes:
|
||||
- /local/path/to/export/folder:/export
|
||||
```
|
||||
|
||||
Then open a terminal in the running keycloak container and run:
|
||||
|
||||
```bash
|
||||
kc.sh export --dir /export/ --users realm_file
|
||||
````
|
||||
|
||||
This will export the all the realms with users to the `/export` folder.
|
||||
|
||||
### Configure Ingress
|
||||
|
||||
This chart provides support for Ingress resources. If you have an ingress controller installed on your cluster, such as [nginx-ingress-controller](https://github.com/bitnami/charts/tree/main/bitnami/nginx-ingress-controller) or [contour](https://github.com/bitnami/charts/tree/main/bitnami/contour) you can utilize the ingress controller to serve your application.To enable Ingress integration, set `ingress.enabled` to `true`.
|
||||
|
||||
The most common scenario is to have one host name mapped to the deployment. In this case, the `ingress.hostname` property can be used to set the host name. The `ingress.tls` parameter can be used to add the TLS configuration for this host.
|
||||
|
||||
However, it is also possible to have more than one host. To facilitate this, the `ingress.extraHosts` parameter (if available) can be set with the host names specified as an array. The `ingress.extraTLS` parameter (if available) can also be used to add the TLS configuration for extra hosts.
|
||||
|
||||
> NOTE: For each host specified in the `ingress.extraHosts` parameter, it is necessary to set a name, path, and any annotations that the Ingress controller should know about. Not all annotations are supported by all Ingress controllers, but [this annotation reference document](https://github.com/kubernetes/ingress-nginx/blob/master/docs/user-guide/nginx-configuration/annotations.md) lists the annotations supported by many popular Ingress controllers.
|
||||
|
||||
Adding the TLS parameter (where available) will cause the chart to generate HTTPS URLs, and the application will be available on port 443. The actual TLS secrets do not have to be generated by this chart. However, if TLS is enabled, the Ingress record will not work until the TLS secret exists.
|
||||
|
||||
[Learn more about Ingress controllers](https://kubernetes.io/docs/concepts/services-networking/ingress-controllers/).
|
||||
|
||||
### Configure admin Ingress
|
||||
|
||||
In addition to the Ingress resource described above, this chart also provides the ability to define an Ingress for the admin area of Keycloak, for example the `master` realm.
|
||||
|
||||
For this scenario, you can use the Keycloak Config CLI integration with the following values, where `keycloak-admin.example.com` is to be replaced by the actual hostname:
|
||||
|
||||
```yaml
|
||||
adminIngress:
|
||||
enabled: true
|
||||
hostname: keycloak-admin.example.com
|
||||
keycloakConfigCli:
|
||||
enabled: true
|
||||
configuration:
|
||||
master.json: |
|
||||
{
|
||||
"realm" : "master",
|
||||
"attributes": {
|
||||
"frontendUrl": "https://keycloak-admin.example.com"
|
||||
}
|
||||
}
|
||||
```
|
||||
|
||||
### Configure TLS Secrets for use with Ingress
|
||||
|
||||
This chart facilitates the creation of TLS secrets for use with the Ingress controller (although this is not mandatory). There are several common use cases:
|
||||
|
||||
- Generate certificate secrets based on chart parameters.
|
||||
- Enable externally generated certificates.
|
||||
- Manage application certificates via an external service (like [cert-manager](https://github.com/jetstack/cert-manager/)).
|
||||
- Create self-signed certificates within the chart (if supported).
|
||||
|
||||
In the first two cases, a certificate and a key are needed. Files are expected in `.pem` format.
|
||||
|
||||
Here is an example of a certificate file:
|
||||
|
||||
> NOTE: There may be more than one certificate if there is a certificate chain.
|
||||
|
||||
```text
|
||||
-----BEGIN CERTIFICATE-----
|
||||
MIID6TCCAtGgAwIBAgIJAIaCwivkeB5EMA0GCSqGSIb3DQEBCwUAMFYxCzAJBgNV
|
||||
...
|
||||
jScrvkiBO65F46KioCL9h5tDvomdU1aqpI/CBzhvZn1c0ZTf87tGQR8NK7v7
|
||||
-----END CERTIFICATE-----
|
||||
```
|
||||
|
||||
Here is an example of a certificate key:
|
||||
|
||||
```text
|
||||
-----BEGIN RSA PRIVATE KEY-----
|
||||
MIIEogIBAAKCAQEAvLYcyu8f3skuRyUgeeNpeDvYBCDcgq+LsWap6zbX5f8oLqp4
|
||||
...
|
||||
wrj2wDbCDCFmfqnSJ+dKI3vFLlEz44sAV8jX/kd4Y6ZTQhlLbYc=
|
||||
-----END RSA PRIVATE KEY-----
|
||||
```
|
||||
|
||||
- If using Helm to manage the certificates based on the parameters, copy these values into the `certificate` and `key` values for a given `*.ingress.secrets` entry.
|
||||
- If managing TLS secrets separately, it is necessary to create a TLS secret with name `INGRESS_HOSTNAME-tls` (where INGRESS_HOSTNAME is a placeholder to be replaced with the hostname you set using the `*.ingress.hostname` parameter).
|
||||
- If your cluster has a [cert-manager](https://github.com/jetstack/cert-manager) add-on to automate the management and issuance of TLS certificates, add to `*.ingress.annotations` the [corresponding ones](https://cert-manager.io/docs/usage/ingress/#supported-annotations) for cert-manager.
|
||||
- If using self-signed certificates created by Helm, set both `*.ingress.tls` and `*.ingress.selfSigned` to `true`.
|
||||
|
||||
### Securing traffic using TLS
|
||||
|
||||
Keycloak can work with TLS interally by setting `tls.enabled=true`. The chart allows two configuration options:
|
||||
|
||||
- Provide your own secret using the `tls.existingSecret` value. Also set the correct name of the truststore and keystore using the `tls.truststoreFilename` and `tls.keystoreFilename` values.
|
||||
- Have the chart auto-generate the certificates using `tls.autoGenerated=true`.
|
||||
|
||||
### Use with ingress offloading SSL
|
||||
|
||||
If your ingress controller has the SSL Termination, you should set `proxy` to `edge`.
|
||||
|
||||
### Manage secrets and passwords
|
||||
|
||||
This chart provides several ways to manage passwords:
|
||||
|
||||
- Values passed to the chart: In this scenario, a new secret including all the passwords will be created during the chart installation. When upgrading, it is necessary to provide the secrets to the chart as shown below. Replace the KC_BOOTSTRAP_ADMIN_PASSWORD, POSTGRESQL_PASSWORD and POSTGRESQL_PVC placeholders with the correct passwords and PVC name.
|
||||
|
||||
```console
|
||||
helm upgrade keycloak bitnami/keycloak \
|
||||
--set auth.adminPassword=KC_BOOTSTRAP_ADMIN_PASSWORD \
|
||||
--set postgresql.postgresqlPassword=POSTGRESQL_PASSWORD \
|
||||
--set postgresql.persistence.existingClaim=POSTGRESQL_PVC
|
||||
```
|
||||
|
||||
- An existing secret with all the passwords via the `existingSecret` parameter.
|
||||
|
||||
### Backup and restore
|
||||
|
||||
To back up and restore Helm chart deployments on Kubernetes, you need to back up the persistent volumes from the source deployment and attach them to a new deployment using [Velero](https://velero.io/), a Kubernetes backup/restore tool. Find the instructions for using Velero in [this guide](https://techdocs.broadcom.com/us/en/vmware-tanzu/application-catalog/tanzu-application-catalog/services/tac-doc/apps-tutorials-backup-restore-deployments-velero-index.html).
|
||||
|
||||
### Add extra environment variables
|
||||
|
||||
In case you want to add extra environment variables (useful for advanced operations like custom init scripts), you can use the `extraEnvVars` property.
|
||||
|
||||
```yaml
|
||||
extraEnvVars:
|
||||
- name: KEYCLOAK_LOG_LEVEL
|
||||
value: DEBUG
|
||||
```
|
||||
|
||||
Alternatively, you can use a ConfigMap or a Secret with the environment variables. To do so, use the `extraEnvVarsCM` or the `extraEnvVarsSecret` values.
|
||||
|
||||
### Use Sidecars and Init Containers
|
||||
|
||||
If additional containers are needed in the same pod (such as additional metrics or logging exporters), they can be defined using the `sidecars` config parameter.
|
||||
|
||||
```yaml
|
||||
sidecars:
|
||||
- name: your-image-name
|
||||
image: your-image
|
||||
imagePullPolicy: Always
|
||||
ports:
|
||||
- name: portname
|
||||
containerPort: 1234
|
||||
```
|
||||
|
||||
If these sidecars export extra ports, extra port definitions can be added using the `service.extraPorts` parameter (where available), as shown in the example below:
|
||||
|
||||
```yaml
|
||||
service:
|
||||
extraPorts:
|
||||
- name: extraPort
|
||||
port: 11311
|
||||
targetPort: 11311
|
||||
```
|
||||
|
||||
> NOTE: This Helm chart already includes sidecar containers for the Prometheus exporters (where applicable). These can be activated by adding the `--enable-metrics=true` parameter at deployment time. The `sidecars` parameter should therefore only be used for any extra sidecar containers.
|
||||
|
||||
If additional init containers are needed in the same pod, they can be defined using the `initContainers` parameter. Here is an example:
|
||||
|
||||
```yaml
|
||||
initContainers:
|
||||
- name: your-image-name
|
||||
image: your-image
|
||||
imagePullPolicy: Always
|
||||
ports:
|
||||
- name: portname
|
||||
containerPort: 1234
|
||||
```
|
||||
|
||||
Learn more about [sidecar containers](https://kubernetes.io/docs/concepts/workloads/pods/) and [init containers](https://kubernetes.io/docs/concepts/workloads/pods/init-containers/).
|
||||
|
||||
### Initialize a fresh instance
|
||||
|
||||
The [Bitnami Keycloak](https://github.com/bitnami/containers/tree/main/bitnami/keycloak) image allows you to use your custom scripts to initialize a fresh instance. In order to execute the scripts, you can specify custom scripts using the `initdbScripts` parameter as dict.
|
||||
|
||||
In addition to this option, you can also set an external ConfigMap with all the initialization scripts. This is done by setting the `initdbScriptsConfigMap` parameter. Note that this will override the previous option.
|
||||
|
||||
The allowed extensions is `.sh`.
|
||||
|
||||
### Deploy extra resources
|
||||
|
||||
There are cases where you may want to deploy extra objects, such a ConfigMap containing your app's configuration or some extra deployment with a micro service used by your app. For covering this case, the chart allows adding the full specification of other objects using the `extraDeploy` parameter.
|
||||
|
||||
### Set Pod affinity
|
||||
|
||||
This chart allows you to set your custom affinity using the `affinity` parameter. Find more information about Pod's affinity in the [kubernetes documentation](https://kubernetes.io/docs/concepts/configuration/assign-pod-node/#affinity-and-anti-affinity).
|
||||
|
||||
As an alternative, you can use of the preset configurations for pod affinity, pod anti-affinity, and node affinity available at the [bitnami/common](https://github.com/bitnami/charts/tree/main/bitnami/common#affinities) chart. To do so, set the `podAffinityPreset`, `podAntiAffinityPreset`, or `nodeAffinityPreset` parameters.
|
||||
|
||||
## Parameters
|
||||
|
||||
### Global parameters
|
||||
|
||||
| Name | Description | Value |
|
||||
| ----------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ------- |
|
||||
| `global.imageRegistry` | Global Docker image registry | `""` |
|
||||
| `global.imagePullSecrets` | Global Docker registry secret names as an array | `[]` |
|
||||
| `global.defaultStorageClass` | Global default StorageClass for Persistent Volume(s) | `""` |
|
||||
| `global.storageClass` | DEPRECATED: use global.defaultStorageClass instead | `""` |
|
||||
| `global.security.allowInsecureImages` | Allows skipping image verification | `false` |
|
||||
| `global.compatibility.openshift.adaptSecurityContext` | Adapt the securityContext sections of the deployment to make them compatible with Openshift restricted-v2 SCC: remove runAsUser, runAsGroup and fsGroup and let the platform use their allowed default IDs. Possible values: auto (apply if the detected running cluster is Openshift), force (perform the adaptation always), disabled (do not perform adaptation) | `auto` |
|
||||
|
||||
### Common parameters
|
||||
|
||||
| Name | Description | Value |
|
||||
| ------------------------ | --------------------------------------------------------------------------------------- | --------------- |
|
||||
| `kubeVersion` | Force target Kubernetes version (using Helm capabilities if not set) | `""` |
|
||||
| `nameOverride` | String to partially override common.names.fullname | `""` |
|
||||
| `fullnameOverride` | String to fully override common.names.fullname | `""` |
|
||||
| `namespaceOverride` | String to fully override common.names.namespace | `""` |
|
||||
| `commonLabels` | Labels to add to all deployed objects | `{}` |
|
||||
| `enableServiceLinks` | If set to false, disable Kubernetes service links in the pod spec | `true` |
|
||||
| `commonAnnotations` | Annotations to add to all deployed objects | `{}` |
|
||||
| `dnsPolicy` | DNS Policy for pod | `""` |
|
||||
| `dnsConfig` | DNS Configuration pod | `{}` |
|
||||
| `clusterDomain` | Default Kubernetes cluster domain | `cluster.local` |
|
||||
| `extraDeploy` | Array of extra objects to deploy with the release | `[]` |
|
||||
| `usePasswordFiles` | Mount credentials as files instead of using environment variables | `true` |
|
||||
| `diagnosticMode.enabled` | Enable diagnostic mode (all probes will be disabled and the command will be overridden) | `false` |
|
||||
| `diagnosticMode.command` | Command to override all containers in the the statefulset | `["sleep"]` |
|
||||
| `diagnosticMode.args` | Args to override all containers in the the statefulset | `["infinity"]` |
|
||||
|
||||
### Keycloak parameters
|
||||
|
||||
| Name | Description | Value |
|
||||
| -------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------ | ----------------------------- |
|
||||
| `image.registry` | Keycloak image registry | `REGISTRY_NAME` |
|
||||
| `image.repository` | Keycloak image repository | `REPOSITORY_NAME/keycloak` |
|
||||
| `image.digest` | Keycloak image digest in the way sha256:aa.... Please note this parameter, if set, will override the tag | `""` |
|
||||
| `image.pullPolicy` | Keycloak image pull policy | `IfNotPresent` |
|
||||
| `image.pullSecrets` | Specify docker-registry secret names as an array | `[]` |
|
||||
| `image.debug` | Specify if debug logs should be enabled | `false` |
|
||||
| `auth.adminUser` | Keycloak administrator user | `user` |
|
||||
| `auth.adminPassword` | Keycloak administrator password for the new user | `""` |
|
||||
| `auth.existingSecret` | Existing secret containing Keycloak admin password | `""` |
|
||||
| `auth.passwordSecretKey` | Key where the Keycloak admin password is being stored inside the existing secret. | `""` |
|
||||
| `auth.annotations` | Additional custom annotations for Keycloak auth secret object | `{}` |
|
||||
| `customCaExistingSecret` | Name of the secret containing the Keycloak custom CA certificates. The secret will be mounted as a directory and configured using KC_TRUSTSTORE_PATHS. | `""` |
|
||||
| `tls.enabled` | Enable TLS encryption. Required for HTTPs traffic. | `false` |
|
||||
| `tls.autoGenerated` | Generate automatically self-signed TLS certificates. Currently only supports PEM certificates | `false` |
|
||||
| `tls.existingSecret` | Existing secret containing the TLS certificates per Keycloak replica | `""` |
|
||||
| `tls.usePem` | Use PEM certificates as input instead of PKS12/JKS stores | `false` |
|
||||
| `tls.truststoreFilename` | Truststore filename inside the existing secret | `keycloak.truststore.jks` |
|
||||
| `tls.keystoreFilename` | Keystore filename inside the existing secret | `keycloak.keystore.jks` |
|
||||
| `tls.keystorePassword` | Password to access the keystore when it's password-protected | `""` |
|
||||
| `tls.truststorePassword` | Password to access the truststore when it's password-protected | `""` |
|
||||
| `tls.passwordsSecret` | Secret containing the Keystore and Truststore passwords. | `""` |
|
||||
| `spi.existingSecret` | Existing secret containing the Keycloak truststore for SPI connection over HTTPS/TLS | `""` |
|
||||
| `spi.truststorePassword` | Password to access the truststore when it's password-protected | `""` |
|
||||
| `spi.truststoreFilename` | Truststore filename inside the existing secret | `keycloak-spi.truststore.jks` |
|
||||
| `spi.passwordsSecret` | Secret containing the SPI Truststore passwords. | `""` |
|
||||
| `spi.hostnameVerificationPolicy` | Verify the hostname of the server's certificate. Allowed values: "ANY", "WILDCARD", "STRICT". | `""` |
|
||||
| `adminRealm` | Name of the admin realm | `master` |
|
||||
| `production` | Run Keycloak in production mode. TLS configuration is required except when using proxy=edge. | `false` |
|
||||
| `proxyHeaders` | Set Keycloak proxy headers | `""` |
|
||||
| `proxy` | reverse Proxy mode edge, reencrypt, passthrough or none | `""` |
|
||||
| `httpRelativePath` | Set the path relative to '/' for serving resources. Useful if you are migrating from older version which were using '/auth/' | `/` |
|
||||
| `configuration` | Keycloak Configuration. Auto-generated based on other parameters when not specified | `""` |
|
||||
| `existingConfigmap` | Name of existing ConfigMap with Keycloak configuration | `""` |
|
||||
| `extraStartupArgs` | Extra default startup args | `""` |
|
||||
| `enableDefaultInitContainers` | Deploy default init containers | `true` |
|
||||
| `initdbScripts` | Dictionary of initdb scripts | `{}` |
|
||||
| `initdbScriptsConfigMap` | ConfigMap with the initdb scripts (Note: Overrides `initdbScripts`) | `""` |
|
||||
| `command` | Override default container command (useful when using custom images) | `[]` |
|
||||
| `args` | Override default container args (useful when using custom images) | `[]` |
|
||||
| `extraEnvVars` | Extra environment variables to be set on Keycloak container | `[]` |
|
||||
| `extraEnvVarsCM` | Name of existing ConfigMap containing extra env vars | `""` |
|
||||
| `extraEnvVarsSecret` | Name of existing Secret containing extra env vars | `""` |
|
||||
|
||||
### Keycloak statefulset parameters
|
||||
|
||||
| Name | Description | Value |
|
||||
| --------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ---------------- |
|
||||
| `replicaCount` | Number of Keycloak replicas to deploy | `1` |
|
||||
| `revisionHistoryLimitCount` | Number of controller revisions to keep | `10` |
|
||||
| `containerPorts.http` | Keycloak HTTP container port | `8080` |
|
||||
| `containerPorts.https` | Keycloak HTTPS container port | `8443` |
|
||||
| `containerPorts.metrics` | Keycloak metrics container port | `9000` |
|
||||
| `extraContainerPorts` | Optionally specify extra list of additional port-mappings for Keycloak container | `[]` |
|
||||
| `statefulsetAnnotations` | Optionally add extra annotations on the statefulset resource | `{}` |
|
||||
| `podSecurityContext.enabled` | Enabled Keycloak pods' Security Context | `true` |
|
||||
| `podSecurityContext.fsGroupChangePolicy` | Set filesystem group change policy | `Always` |
|
||||
| `podSecurityContext.sysctls` | Set kernel settings using the sysctl interface | `[]` |
|
||||
| `podSecurityContext.supplementalGroups` | Set filesystem extra groups | `[]` |
|
||||
| `podSecurityContext.fsGroup` | Set Keycloak pod's Security Context fsGroup | `1001` |
|
||||
| `containerSecurityContext.enabled` | Enabled containers' Security Context | `true` |
|
||||
| `containerSecurityContext.seLinuxOptions` | Set SELinux options in container | `{}` |
|
||||
| `containerSecurityContext.runAsUser` | Set containers' Security Context runAsUser | `1001` |
|
||||
| `containerSecurityContext.runAsGroup` | Set containers' Security Context runAsGroup | `1001` |
|
||||
| `containerSecurityContext.runAsNonRoot` | Set container's Security Context runAsNonRoot | `true` |
|
||||
| `containerSecurityContext.privileged` | Set container's Security Context privileged | `false` |
|
||||
| `containerSecurityContext.readOnlyRootFilesystem` | Set container's Security Context readOnlyRootFilesystem | `true` |
|
||||
| `containerSecurityContext.allowPrivilegeEscalation` | Set container's Security Context allowPrivilegeEscalation | `false` |
|
||||
| `containerSecurityContext.capabilities.drop` | List of capabilities to be dropped | `["ALL"]` |
|
||||
| `containerSecurityContext.seccompProfile.type` | Set container's Security Context seccomp profile | `RuntimeDefault` |
|
||||
| `resourcesPreset` | Set container resources according to one common preset (allowed values: none, nano, micro, small, medium, large, xlarge, 2xlarge). This is ignored if resources is set (resources is recommended for production). | `small` |
|
||||
| `resources` | Set container requests and limits for different resources like CPU or memory (essential for production workloads) | `{}` |
|
||||
| `livenessProbe.enabled` | Enable livenessProbe on Keycloak containers | `true` |
|
||||
| `livenessProbe.initialDelaySeconds` | Initial delay seconds for livenessProbe | `300` |
|
||||
| `livenessProbe.periodSeconds` | Period seconds for livenessProbe | `1` |
|
||||
| `livenessProbe.timeoutSeconds` | Timeout seconds for livenessProbe | `5` |
|
||||
| `livenessProbe.failureThreshold` | Failure threshold for livenessProbe | `3` |
|
||||
| `livenessProbe.successThreshold` | Success threshold for livenessProbe | `1` |
|
||||
| `readinessProbe.enabled` | Enable readinessProbe on Keycloak containers | `true` |
|
||||
| `readinessProbe.initialDelaySeconds` | Initial delay seconds for readinessProbe | `30` |
|
||||
| `readinessProbe.periodSeconds` | Period seconds for readinessProbe | `10` |
|
||||
| `readinessProbe.timeoutSeconds` | Timeout seconds for readinessProbe | `1` |
|
||||
| `readinessProbe.failureThreshold` | Failure threshold for readinessProbe | `3` |
|
||||
| `readinessProbe.successThreshold` | Success threshold for readinessProbe | `1` |
|
||||
| `startupProbe.enabled` | Enable startupProbe on Keycloak containers | `false` |
|
||||
| `startupProbe.initialDelaySeconds` | Initial delay seconds for startupProbe | `30` |
|
||||
| `startupProbe.periodSeconds` | Period seconds for startupProbe | `5` |
|
||||
| `startupProbe.timeoutSeconds` | Timeout seconds for startupProbe | `1` |
|
||||
| `startupProbe.failureThreshold` | Failure threshold for startupProbe | `60` |
|
||||
| `startupProbe.successThreshold` | Success threshold for startupProbe | `1` |
|
||||
| `customLivenessProbe` | Custom Liveness probes for Keycloak | `{}` |
|
||||
| `customReadinessProbe` | Custom Rediness probes Keycloak | `{}` |
|
||||
| `customStartupProbe` | Custom Startup probes for Keycloak | `{}` |
|
||||
| `lifecycleHooks` | LifecycleHooks to set additional configuration at startup | `{}` |
|
||||
| `automountServiceAccountToken` | Mount Service Account token in pod | `true` |
|
||||
| `hostAliases` | Deployment pod host aliases | `[]` |
|
||||
| `podLabels` | Extra labels for Keycloak pods | `{}` |
|
||||
| `podAnnotations` | Annotations for Keycloak pods | `{}` |
|
||||
| `podAffinityPreset` | Pod affinity preset. Ignored if `affinity` is set. Allowed values: `soft` or `hard` | `""` |
|
||||
| `podAntiAffinityPreset` | Pod anti-affinity preset. Ignored if `affinity` is set. Allowed values: `soft` or `hard` | `soft` |
|
||||
| `nodeAffinityPreset.type` | Node affinity preset type. Ignored if `affinity` is set. Allowed values: `soft` or `hard` | `""` |
|
||||
| `nodeAffinityPreset.key` | Node label key to match. Ignored if `affinity` is set. | `""` |
|
||||
| `nodeAffinityPreset.values` | Node label values to match. Ignored if `affinity` is set. | `[]` |
|
||||
| `affinity` | Affinity for pod assignment | `{}` |
|
||||
| `nodeSelector` | Node labels for pod assignment | `{}` |
|
||||
| `tolerations` | Tolerations for pod assignment | `[]` |
|
||||
| `topologySpreadConstraints` | Topology Spread Constraints for pod assignment spread across your cluster among failure-domains. Evaluated as a template | `[]` |
|
||||
| `podManagementPolicy` | Pod management policy for the Keycloak statefulset | `Parallel` |
|
||||
| `priorityClassName` | Keycloak pods' Priority Class Name | `""` |
|
||||
| `schedulerName` | Use an alternate scheduler, e.g. "stork". | `""` |
|
||||
| `terminationGracePeriodSeconds` | Seconds Keycloak pod needs to terminate gracefully | `""` |
|
||||
| `updateStrategy.type` | Keycloak statefulset strategy type | `RollingUpdate` |
|
||||
| `updateStrategy.rollingUpdate` | Keycloak statefulset rolling update configuration parameters | `{}` |
|
||||
| `minReadySeconds` | How many seconds a pod needs to be ready before killing the next, during update | `0` |
|
||||
| `extraVolumes` | Optionally specify extra list of additional volumes for Keycloak pods | `[]` |
|
||||
| `extraVolumeMounts` | Optionally specify extra list of additional volumeMounts for Keycloak container(s) | `[]` |
|
||||
| `initContainers` | Add additional init containers to the Keycloak pods | `[]` |
|
||||
| `sidecars` | Add additional sidecar containers to the Keycloak pods | `[]` |
|
||||
|
||||
### Exposure parameters
|
||||
|
||||
| Name | Description | Value |
|
||||
| --------------------------------------- | -------------------------------------------------------------------------------------------------------------------------------- | ------------------------ |
|
||||
| `service.type` | Kubernetes service type | `ClusterIP` |
|
||||
| `service.http.enabled` | Enable http port on service | `true` |
|
||||
| `service.ports.http` | Keycloak service HTTP port | `80` |
|
||||
| `service.ports.https` | Keycloak service HTTPS port | `443` |
|
||||
| `service.nodePorts` | Specify the nodePort values for the LoadBalancer and NodePort service types. | `{}` |
|
||||
| `service.sessionAffinity` | Control where client requests go, to the same pod or round-robin | `None` |
|
||||
| `service.sessionAffinityConfig` | Additional settings for the sessionAffinity | `{}` |
|
||||
| `service.clusterIP` | Keycloak service clusterIP IP | `""` |
|
||||
| `service.loadBalancerIP` | loadBalancerIP for the SuiteCRM Service (optional, cloud specific) | `""` |
|
||||
| `service.loadBalancerSourceRanges` | Address that are allowed when service is LoadBalancer | `[]` |
|
||||
| `service.externalTrafficPolicy` | Enable client source IP preservation | `Cluster` |
|
||||
| `service.annotations` | Additional custom annotations for Keycloak service | `{}` |
|
||||
| `service.extraPorts` | Extra port to expose on Keycloak service | `[]` |
|
||||
| `service.extraHeadlessPorts` | Extra ports to expose on Keycloak headless service | `[]` |
|
||||
| `service.headless.annotations` | Annotations for the headless service. | `{}` |
|
||||
| `service.headless.extraPorts` | Extra ports to expose on Keycloak headless service | `[]` |
|
||||
| `ingress.enabled` | Enable ingress record generation for Keycloak | `false` |
|
||||
| `ingress.ingressClassName` | IngressClass that will be be used to implement the Ingress (evaluated as template) (Kubernetes 1.18+) | `""` |
|
||||
| `ingress.pathType` | Ingress path type | `ImplementationSpecific` |
|
||||
| `ingress.apiVersion` | Force Ingress API version (automatically detected if not set) | `""` |
|
||||
| `ingress.controller` | The ingress controller type. Currently supports `default` and `gce` | `default` |
|
||||
| `ingress.hostname` | Default host for the ingress record (evaluated as template) | `keycloak.local` |
|
||||
| `ingress.hostnameStrict` | Disables dynamically resolving the hostname from request headers. | `false` |
|
||||
| `ingress.path` | Default path for the ingress record (evaluated as template) | `""` |
|
||||
| `ingress.servicePort` | Backend service port to use | `http` |
|
||||
| `ingress.annotations` | Additional annotations for the Ingress resource. To enable certificate autogeneration, place here your cert-manager annotations. | `{}` |
|
||||
| `ingress.labels` | Additional labels for the Ingress resource. | `{}` |
|
||||
| `ingress.tls` | Enable TLS configuration for the host defined at `ingress.hostname` parameter | `false` |
|
||||
| `ingress.selfSigned` | Create a TLS secret for this ingress record using self-signed certificates generated by Helm | `false` |
|
||||
| `ingress.extraHosts` | An array with additional hostname(s) to be covered with the ingress record | `[]` |
|
||||
| `ingress.extraPaths` | Any additional arbitrary paths that may need to be added to the ingress under the main host. | `[]` |
|
||||
| `ingress.extraTls` | The tls configuration for additional hostnames to be covered with this ingress record. | `[]` |
|
||||
| `ingress.secrets` | If you're providing your own certificates, please use this to add the certificates as secrets | `[]` |
|
||||
| `ingress.extraRules` | Additional rules to be covered with this ingress record | `[]` |
|
||||
| `adminIngress.enabled` | Enable admin ingress record generation for Keycloak | `false` |
|
||||
| `adminIngress.ingressClassName` | IngressClass that will be be used to implement the Ingress (evaluated as template) (Kubernetes 1.18+) | `""` |
|
||||
| `adminIngress.pathType` | Ingress path type | `ImplementationSpecific` |
|
||||
| `adminIngress.apiVersion` | Force Ingress API version (automatically detected if not set) | `""` |
|
||||
| `adminIngress.controller` | The ingress controller type. Currently supports `default` and `gce` | `default` |
|
||||
| `adminIngress.hostname` | Default host for the admin ingress record (evaluated as template) | `keycloak.local` |
|
||||
| `adminIngress.path` | Default path for the admin ingress record (evaluated as template) | `""` |
|
||||
| `adminIngress.servicePort` | Backend service port to use | `http` |
|
||||
| `adminIngress.annotations` | Additional annotations for the Ingress resource. To enable certificate autogeneration, place here your cert-manager annotations. | `{}` |
|
||||
| `adminIngress.labels` | Additional labels for the Ingress resource. | `{}` |
|
||||
| `adminIngress.tls` | Enable TLS configuration for the host defined at `adminIngress.hostname` parameter | `false` |
|
||||
| `adminIngress.selfSigned` | Create a TLS secret for this ingress record using self-signed certificates generated by Helm | `false` |
|
||||
| `adminIngress.extraHosts` | An array with additional hostname(s) to be covered with the admin ingress record | `[]` |
|
||||
| `adminIngress.extraPaths` | Any additional arbitrary paths that may need to be added to the admin ingress under the main host. | `[]` |
|
||||
| `adminIngress.extraTls` | The tls configuration for additional hostnames to be covered with this ingress record. | `[]` |
|
||||
| `adminIngress.secrets` | If you're providing your own certificates, please use this to add the certificates as secrets | `[]` |
|
||||
| `adminIngress.extraRules` | Additional rules to be covered with this ingress record | `[]` |
|
||||
| `networkPolicy.enabled` | Specifies whether a NetworkPolicy should be created | `true` |
|
||||
| `networkPolicy.allowExternal` | Don't require server label for connections | `true` |
|
||||
| `networkPolicy.allowExternalEgress` | Allow the pod to access any range of port and all destinations. | `true` |
|
||||
| `networkPolicy.kubeAPIServerPorts` | List of possible endpoints to kube-apiserver (limit to your cluster settings to increase security) | `[]` |
|
||||
| `networkPolicy.extraIngress` | Add extra ingress rules to the NetworkPolicy | `[]` |
|
||||
| `networkPolicy.extraEgress` | Add extra ingress rules to the NetworkPolicy | `[]` |
|
||||
| `networkPolicy.ingressNSMatchLabels` | Labels to match to allow traffic from other namespaces | `{}` |
|
||||
| `networkPolicy.ingressNSPodMatchLabels` | Pod labels to match to allow traffic from other namespaces | `{}` |
|
||||
|
||||
### RBAC parameter
|
||||
|
||||
| Name | Description | Value |
|
||||
| --------------------------------------------- | --------------------------------------------------------- | ------- |
|
||||
| `serviceAccount.create` | Enable the creation of a ServiceAccount for Keycloak pods | `true` |
|
||||
| `serviceAccount.name` | Name of the created ServiceAccount | `""` |
|
||||
| `serviceAccount.automountServiceAccountToken` | Auto-mount the service account token in the pod | `false` |
|
||||
| `serviceAccount.annotations` | Additional custom annotations for the ServiceAccount | `{}` |
|
||||
| `serviceAccount.extraLabels` | Additional labels for the ServiceAccount | `{}` |
|
||||
| `rbac.create` | Whether to create and use RBAC resources or not | `false` |
|
||||
| `rbac.rules` | Custom RBAC rules | `[]` |
|
||||
|
||||
### Other parameters
|
||||
|
||||
| Name | Description | Value |
|
||||
| ----------------------------------------------------------- | -------------------------------------------------------------------------------------------- | ------- |
|
||||
| `pdb.create` | Enable/disable a Pod Disruption Budget creation | `true` |
|
||||
| `pdb.minAvailable` | Minimum number/percentage of pods that should remain scheduled | `""` |
|
||||
| `pdb.maxUnavailable` | Maximum number/percentage of pods that may be made unavailable | `""` |
|
||||
| `autoscaling.enabled` | Enable autoscaling for Keycloak | `false` |
|
||||
| `autoscaling.minReplicas` | Minimum number of Keycloak replicas | `1` |
|
||||
| `autoscaling.maxReplicas` | Maximum number of Keycloak replicas | `11` |
|
||||
| `autoscaling.targetCPU` | Target CPU utilization percentage | `""` |
|
||||
| `autoscaling.targetMemory` | Target Memory utilization percentage | `""` |
|
||||
| `autoscaling.behavior.scaleUp.stabilizationWindowSeconds` | The number of seconds for which past recommendations should be considered while scaling up | `120` |
|
||||
| `autoscaling.behavior.scaleUp.selectPolicy` | The priority of policies that the autoscaler will apply when scaling up | `Max` |
|
||||
| `autoscaling.behavior.scaleUp.policies` | HPA scaling policies when scaling up | `[]` |
|
||||
| `autoscaling.behavior.scaleDown.stabilizationWindowSeconds` | The number of seconds for which past recommendations should be considered while scaling down | `300` |
|
||||
| `autoscaling.behavior.scaleDown.selectPolicy` | The priority of policies that the autoscaler will apply when scaling down | `Max` |
|
||||
| `autoscaling.behavior.scaleDown.policies` | HPA scaling policies when scaling down | `[]` |
|
||||
|
||||
### Metrics parameters
|
||||
|
||||
| Name | Description | Value |
|
||||
| ------------------------------------------ | -------------------------------------------------------------------------------------------------------------------------------------------------- | --------- |
|
||||
| `metrics.enabled` | Enable exposing Keycloak statistics | `false` |
|
||||
| `metrics.service.ports.http` | Metrics service HTTP port | `8080` |
|
||||
| `metrics.service.ports.https` | Metrics service HTTPS port | `8443` |
|
||||
| `metrics.service.ports.metrics` | Metrics service Metrics port | `9000` |
|
||||
| `metrics.service.annotations` | Annotations for enabling prometheus to access the metrics endpoints | `{}` |
|
||||
| `metrics.service.extraPorts` | Add additional ports to the keycloak metrics service (i.e. admin port 9000) | `[]` |
|
||||
| `metrics.serviceMonitor.enabled` | Create ServiceMonitor Resource for scraping metrics using PrometheusOperator | `false` |
|
||||
| `metrics.serviceMonitor.port` | Metrics service HTTP port | `metrics` |
|
||||
| `metrics.serviceMonitor.scheme` | Metrics service scheme | `http` |
|
||||
| `metrics.serviceMonitor.tlsConfig` | Metrics service TLS configuration | `{}` |
|
||||
| `metrics.serviceMonitor.endpoints` | The endpoint configuration of the ServiceMonitor. Path is mandatory. Port, scheme, tlsConfig, interval, timeout and labellings can be overwritten. | `[]` |
|
||||
| `metrics.serviceMonitor.path` | Metrics service HTTP path. Deprecated: Use @param metrics.serviceMonitor.endpoints instead | `""` |
|
||||
| `metrics.serviceMonitor.namespace` | Namespace which Prometheus is running in | `""` |
|
||||
| `metrics.serviceMonitor.interval` | Interval at which metrics should be scraped | `30s` |
|
||||
| `metrics.serviceMonitor.scrapeTimeout` | Specify the timeout after which the scrape is ended | `""` |
|
||||
| `metrics.serviceMonitor.labels` | Additional labels that can be used so ServiceMonitor will be discovered by Prometheus | `{}` |
|
||||
| `metrics.serviceMonitor.selector` | Prometheus instance selector labels | `{}` |
|
||||
| `metrics.serviceMonitor.relabelings` | RelabelConfigs to apply to samples before scraping | `[]` |
|
||||
| `metrics.serviceMonitor.metricRelabelings` | MetricRelabelConfigs to apply to samples before ingestion | `[]` |
|
||||
| `metrics.serviceMonitor.honorLabels` | honorLabels chooses the metric's labels on collisions with target labels | `false` |
|
||||
| `metrics.serviceMonitor.jobLabel` | The name of the label on the target service to use as the job name in prometheus. | `""` |
|
||||
| `metrics.prometheusRule.enabled` | Create PrometheusRule Resource for scraping metrics using PrometheusOperator | `false` |
|
||||
| `metrics.prometheusRule.namespace` | Namespace which Prometheus is running in | `""` |
|
||||
| `metrics.prometheusRule.labels` | Additional labels that can be used so PrometheusRule will be discovered by Prometheus | `{}` |
|
||||
| `metrics.prometheusRule.groups` | Groups, containing the alert rules. | `[]` |
|
||||
|
||||
### keycloak-config-cli parameters
|
||||
|
||||
| Name | Description | Value |
|
||||
| --------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------- |
|
||||
| `keycloakConfigCli.enabled` | Whether to enable keycloak-config-cli job | `false` |
|
||||
| `keycloakConfigCli.image.registry` | keycloak-config-cli container image registry | `REGISTRY_NAME` |
|
||||
| `keycloakConfigCli.image.repository` | keycloak-config-cli container image repository | `REPOSITORY_NAME/keycloak-config-cli` |
|
||||
| `keycloakConfigCli.image.digest` | keycloak-config-cli container image digest in the way sha256:aa.... Please note this parameter, if set, will override the tag | `""` |
|
||||
| `keycloakConfigCli.image.pullPolicy` | keycloak-config-cli container image pull policy | `IfNotPresent` |
|
||||
| `keycloakConfigCli.image.pullSecrets` | keycloak-config-cli container image pull secrets | `[]` |
|
||||
| `keycloakConfigCli.annotations` | Annotations for keycloak-config-cli job | `{}` |
|
||||
| `keycloakConfigCli.command` | Command for running the container (set to default if not set). Use array form | `[]` |
|
||||
| `keycloakConfigCli.args` | Args for running the container (set to default if not set). Use array form | `[]` |
|
||||
| `keycloakConfigCli.automountServiceAccountToken` | Mount Service Account token in pod | `true` |
|
||||
| `keycloakConfigCli.hostAliases` | Job pod host aliases | `[]` |
|
||||
| `keycloakConfigCli.resourcesPreset` | Set container resources according to one common preset (allowed values: none, nano, micro, small, medium, large, xlarge, 2xlarge). This is ignored if keycloakConfigCli.resources is set (keycloakConfigCli.resources is recommended for production). | `small` |
|
||||
| `keycloakConfigCli.resources` | Set container requests and limits for different resources like CPU or memory (essential for production workloads) | `{}` |
|
||||
| `keycloakConfigCli.containerSecurityContext.enabled` | Enabled keycloak-config-cli Security Context | `true` |
|
||||
| `keycloakConfigCli.containerSecurityContext.seLinuxOptions` | Set SELinux options in container | `{}` |
|
||||
| `keycloakConfigCli.containerSecurityContext.runAsUser` | Set keycloak-config-cli Security Context runAsUser | `1001` |
|
||||
| `keycloakConfigCli.containerSecurityContext.runAsGroup` | Set keycloak-config-cli Security Context runAsGroup | `1001` |
|
||||
| `keycloakConfigCli.containerSecurityContext.runAsNonRoot` | Set keycloak-config-cli Security Context runAsNonRoot | `true` |
|
||||
| `keycloakConfigCli.containerSecurityContext.privileged` | Set keycloak-config-cli Security Context privileged | `false` |
|
||||
| `keycloakConfigCli.containerSecurityContext.readOnlyRootFilesystem` | Set keycloak-config-cli Security Context readOnlyRootFilesystem | `true` |
|
||||
| `keycloakConfigCli.containerSecurityContext.allowPrivilegeEscalation` | Set keycloak-config-cli Security Context allowPrivilegeEscalation | `false` |
|
||||
| `keycloakConfigCli.containerSecurityContext.capabilities.drop` | List of capabilities to be dropped | `["ALL"]` |
|
||||
| `keycloakConfigCli.containerSecurityContext.seccompProfile.type` | Set keycloak-config-cli Security Context seccomp profile | `RuntimeDefault` |
|
||||
| `keycloakConfigCli.podSecurityContext.enabled` | Enabled keycloak-config-cli pods' Security Context | `true` |
|
||||
| `keycloakConfigCli.podSecurityContext.fsGroupChangePolicy` | Set filesystem group change policy | `Always` |
|
||||
| `keycloakConfigCli.podSecurityContext.sysctls` | Set kernel settings using the sysctl interface | `[]` |
|
||||
| `keycloakConfigCli.podSecurityContext.supplementalGroups` | Set filesystem extra groups | `[]` |
|
||||
| `keycloakConfigCli.podSecurityContext.fsGroup` | Set keycloak-config-cli pod's Security Context fsGroup | `1001` |
|
||||
| `keycloakConfigCli.backoffLimit` | Number of retries before considering a Job as failed | `1` |
|
||||
| `keycloakConfigCli.podLabels` | Pod extra labels | `{}` |
|
||||
| `keycloakConfigCli.podAnnotations` | Annotations for job pod | `{}` |
|
||||
| `keycloakConfigCli.nodeSelector` | Node labels for pod assignment | `{}` |
|
||||
| `keycloakConfigCli.podTolerations` | Tolerations for job pod assignment | `[]` |
|
||||
| `keycloakConfigCli.availabilityCheck.enabled` | Whether to wait until Keycloak is available | `true` |
|
||||
| `keycloakConfigCli.availabilityCheck.timeout` | Timeout for the availability check (Default is 120s) | `""` |
|
||||
| `keycloakConfigCli.extraEnvVars` | Additional environment variables to set | `[]` |
|
||||
| `keycloakConfigCli.extraEnvVarsCM` | ConfigMap with extra environment variables | `""` |
|
||||
| `keycloakConfigCli.extraEnvVarsSecret` | Secret with extra environment variables | `""` |
|
||||
| `keycloakConfigCli.extraVolumes` | Extra volumes to add to the job | `[]` |
|
||||
| `keycloakConfigCli.extraVolumeMounts` | Extra volume mounts to add to the container | `[]` |
|
||||
| `keycloakConfigCli.initContainers` | Add additional init containers to the Keycloak config cli pod | `[]` |
|
||||
| `keycloakConfigCli.sidecars` | Add additional sidecar containers to the Keycloak config cli pod | `[]` |
|
||||
| `keycloakConfigCli.configuration` | keycloak-config-cli realms configuration | `{}` |
|
||||
| `keycloakConfigCli.existingConfigmap` | ConfigMap with keycloak-config-cli configuration | `""` |
|
||||
| `keycloakConfigCli.cleanupAfterFinished.enabled` | Enables Cleanup for Finished Jobs | `false` |
|
||||
| `keycloakConfigCli.cleanupAfterFinished.seconds` | Sets the value of ttlSecondsAfterFinished | `600` |
|
||||
|
||||
### Database parameters
|
||||
|
||||
| Name | Description | Value |
|
||||
| -------------------------------------------- | ----------------------------------------------------------------------------------------------------------------- | ------------------ |
|
||||
| `postgresql.enabled` | Switch to enable or disable the PostgreSQL helm chart | `true` |
|
||||
| `postgresql.auth.postgresPassword` | Password for the "postgres" admin user. Ignored if `auth.existingSecret` with key `postgres-password` is provided | `""` |
|
||||
| `postgresql.auth.username` | Name for a custom user to create | `bn_keycloak` |
|
||||
| `postgresql.auth.password` | Password for the custom user to create | `""` |
|
||||
| `postgresql.auth.database` | Name for a custom database to create | `bitnami_keycloak` |
|
||||
| `postgresql.auth.existingSecret` | Name of existing secret to use for PostgreSQL credentials | `""` |
|
||||
| `postgresql.auth.secretKeys.userPasswordKey` | Name of key in existing secret to use for PostgreSQL credentials. Only used when `auth.existingSecret` is set. | `password` |
|
||||
| `postgresql.architecture` | PostgreSQL architecture (`standalone` or `replication`) | `standalone` |
|
||||
| `externalDatabase.host` | Database host | `""` |
|
||||
| `externalDatabase.port` | Database port number | `5432` |
|
||||
| `externalDatabase.user` | Non-root username for Keycloak | `bn_keycloak` |
|
||||
| `externalDatabase.password` | Password for the non-root username for Keycloak | `""` |
|
||||
| `externalDatabase.database` | Keycloak database name | `bitnami_keycloak` |
|
||||
| `externalDatabase.schema` | Keycloak database schema | `public` |
|
||||
| `externalDatabase.existingSecret` | Name of an existing secret resource containing the database credentials | `""` |
|
||||
| `externalDatabase.existingSecretHostKey` | Name of an existing secret key containing the database host name | `""` |
|
||||
| `externalDatabase.existingSecretPortKey` | Name of an existing secret key containing the database port | `""` |
|
||||
| `externalDatabase.existingSecretUserKey` | Name of an existing secret key containing the database user | `""` |
|
||||
| `externalDatabase.existingSecretDatabaseKey` | Name of an existing secret key containing the database name | `""` |
|
||||
| `externalDatabase.existingSecretPasswordKey` | Name of an existing secret key containing the database credentials | `""` |
|
||||
| `externalDatabase.annotations` | Additional custom annotations for external database secret object | `{}` |
|
||||
|
||||
### Keycloak Cache parameters
|
||||
|
||||
| Name | Description | Value |
|
||||
| ---------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------- | ---------------- |
|
||||
| `cache.enabled` | Switch to enable or disable the keycloak distributed cache for kubernetes. | `true` |
|
||||
| `cache.stack` | Set infinispan cache stack to use, sets KC_CACHE_STACK (<https://www.keycloak.org/server/all-config?q=cache-stack>) | `kubernetes` |
|
||||
| `cache.configFile` | Set infinispan cache stack config filename sets KC_CACHE_CONFIG_FILE (<https://www.keycloak.org/server/all-config?q=cache-config-file>) | `cache-ispn.xml` |
|
||||
| `cache.useHeadlessServiceWithAppVersion` | Set to true to create the headless service used for ispn containing the app version | `false` |
|
||||
|
||||
### Keycloak Logging parameters
|
||||
|
||||
| Name | Description | Value |
|
||||
| ---------------- | ------------------------------------------------------------------------------ | --------- |
|
||||
| `logging.output` | Alternates between the default log output format or json format | `default` |
|
||||
| `logging.level` | Allowed values as documented: FATAL, ERROR, WARN, INFO, DEBUG, TRACE, ALL, OFF | `INFO` |
|
||||
|
||||
Specify each parameter using the `--set key=value[,key=value]` argument to `helm install`. For example,
|
||||
|
||||
```console
|
||||
helm install my-release --set auth.adminPassword=secretpassword oci://REGISTRY_NAME/REPOSITORY_NAME/keycloak
|
||||
```
|
||||
|
||||
> Note: You need to substitute the placeholders `REGISTRY_NAME` and `REPOSITORY_NAME` with a reference to your Helm chart registry and repository. For example, in the case of Bitnami, you need to use `REGISTRY_NAME=registry-1.docker.io` and `REPOSITORY_NAME=bitnamicharts`.
|
||||
|
||||
The above command sets the Keycloak administrator password to `secretpassword`.
|
||||
|
||||
> NOTE: Once this chart is deployed, it is not possible to change the application's access credentials, such as usernames or passwords, using Helm. To change these application credentials after deployment, delete any persistent volumes (PVs) used by the chart and re-deploy it, or use the application's built-in administrative tools if available.
|
||||
|
||||
Alternatively, a YAML file that specifies the values for the parameters can be provided while installing the chart. For example,
|
||||
|
||||
```console
|
||||
helm install my-release -f values.yaml oci://REGISTRY_NAME/REPOSITORY_NAME/keycloak
|
||||
```
|
||||
|
||||
> Note: You need to substitute the placeholders `REGISTRY_NAME` and `REPOSITORY_NAME` with a reference to your Helm chart registry and repository. For example, in the case of Bitnami, you need to use `REGISTRY_NAME=registry-1.docker.io` and `REPOSITORY_NAME=bitnamicharts`.
|
||||
> **Tip**: You can use the default [values.yaml](https://github.com/bitnami/charts/tree/main/bitnami/keycloak/values.yaml)
|
||||
|
||||
Keycloak realms, users and clients can be created from the Keycloak administration panel.
|
||||
|
||||
## Troubleshooting
|
||||
|
||||
Find more information about how to deal with common errors related to Bitnami's Helm charts in [this troubleshooting guide](https://docs.bitnami.com/general/how-to/troubleshoot-helm-chart-issues).
|
||||
|
||||
## Upgrading
|
||||
|
||||
### To 24.3.0
|
||||
|
||||
This version introduces image verification for security purposes. To disable it, set `global.security.allowInsecureImages` to `true`. More details at [GitHub issue](https://github.com/bitnami/charts/issues/30850).
|
||||
|
||||
### To 24.1.0
|
||||
|
||||
With this update the metrics service listening port is switched to 9000, the same as the keycloak management endpoint is using.
|
||||
This can be changed by setting `metrics.service.ports.http` to a different value, e.g. 8080 like before this change.
|
||||
|
||||
### To 23.0.0
|
||||
|
||||
This major updates the PostgreSQL subchart to its newest major, 16.0.0, which uses PostgreSQL 17.x. Follow the [official instructions](https://www.postgresql.org/docs/17/upgrading.html) to upgrade to 17.x.
|
||||
|
||||
### To 21.0.0
|
||||
|
||||
This major release updates the keycloak branch to its newest major, 24.x.x. Follow the [upstream documentation](https://www.keycloak.org/docs/latest/upgrading/index.html#migrating-to-24-0-0) for upgrade instructions.
|
||||
|
||||
### To 20.0.0
|
||||
|
||||
This major bump changes the following security defaults:
|
||||
|
||||
- `runAsGroup` is changed from `0` to `1001`
|
||||
- `readOnlyRootFilesystem` is set to `true`
|
||||
- `resourcesPreset` is changed from `none` to the minimum size working in our test suites (NOTE: `resourcesPreset` is not meant for production usage, but `resources` adapted to your use case).
|
||||
- `global.compatibility.openshift.adaptSecurityContext` is changed from `disabled` to `auto`.
|
||||
|
||||
This could potentially break any customization or init scripts used in your deployment. If this is the case, change the default values to the previous ones.
|
||||
|
||||
### To 19.0.0
|
||||
|
||||
This major release bumps the PostgreSQL chart version to [14.x.x](https://github.com/bitnami/charts/pull/22750); no major issues are expected during the upgrade.
|
||||
|
||||
### To 17.0.0
|
||||
|
||||
This major updates the PostgreSQL subchart to its newest major, 13.0.0. [Here](https://github.com/bitnami/charts/tree/master/bitnami/postgresql#to-1300) you can find more information about the changes introduced in that version.
|
||||
|
||||
### To 15.0.0
|
||||
|
||||
This major updates the default serviceType from `LoadBalancer` to `ClusterIP` to avoid inadvertently exposing Keycloak directly to the internet without an Ingress.
|
||||
|
||||
### To 12.0.0
|
||||
|
||||
This major updates the PostgreSQL subchart to its newest major, 12.0.0. [Here](https://github.com/bitnami/charts/tree/master/bitnami/postgresql#to-1200) you can find more information about the changes introduced in that version.
|
||||
|
||||
### To 10.0.0
|
||||
|
||||
This major release updates Keycloak to its major version `19`. Please, refer to the official [Keycloak migration documentation](https://www.keycloak.org/docs/latest/upgrading/index.html#migrating-to-19-0-0) for a complete list of changes and further information.
|
||||
|
||||
### To 9.0.0
|
||||
|
||||
This major release updates Keycloak to its major version `18`. Please, refer to the official [Keycloak migration documentation](https://www.keycloak.org/docs/latest/upgrading/index.html#migrating-to-18-0-0) for a complete list of changes and further information.
|
||||
|
||||
### To 8.0.0
|
||||
|
||||
This major release updates Keycloak to its major version `17`. Among other features, this new version has deprecated WildFly in favor of Quarkus, which introduces breaking changes like:
|
||||
|
||||
- Removal of `/auth` from the default context path.
|
||||
- Changes in the configuration and deployment of custom providers.
|
||||
- Significant changes in configuring Keycloak.
|
||||
|
||||
Please, refer to the official [Keycloak migration documentation](https://www.keycloak.org/docs/latest/upgrading/index.html#migrating-to-17-0-0) and [Migrating to Quarkus distribution document](https://www.keycloak.org/migration/migrating-to-quarkus) for a complete list of changes and further information.
|
||||
|
||||
### To 7.0.0
|
||||
|
||||
This major release updates the PostgreSQL subchart to its newest major *11.x.x*, which contain several changes in the supported values (check the [upgrade notes](https://github.com/bitnami/charts/tree/master/bitnami/postgresql#to-1100) to obtain more information).
|
||||
|
||||
#### Upgrading Instructions
|
||||
|
||||
To upgrade to *7.0.0* from *6.x*, it should be done reusing the PVC(s) used to hold the data on your previous release. To do so, follow the instructions below (the following example assumes that the release name is *keycloak* and the release namespace *default*):
|
||||
|
||||
1. Obtain the credentials and the names of the PVCs used to hold the data on your current release:
|
||||
|
||||
```console
|
||||
export KEYCLOAK_PASSWORD=$(kubectl get secret --namespace default keycloak -o jsonpath="{.data.admin-password}" | base64 --decode)
|
||||
export POSTGRESQL_PASSWORD=$(kubectl get secret --namespace default keycloak-postgresql -o jsonpath="{.data.postgresql-password}" | base64 --decode)
|
||||
export POSTGRESQL_PVC=$(kubectl get pvc -l app.kubernetes.io/instance=keycloak,app.kubernetes.io/name=postgresql,role=primary -o jsonpath="{.items[0].metadata.name}")
|
||||
```
|
||||
|
||||
1. Delete the PostgreSQL statefulset (notice the option *--cascade=false*) and secret:
|
||||
|
||||
```console
|
||||
kubectl delete statefulsets.apps --cascade=false keycloak-postgresql
|
||||
kubectl delete secret keycloak-postgresql --namespace default
|
||||
```
|
||||
|
||||
1. Upgrade your release using the same PostgreSQL version:
|
||||
|
||||
```console
|
||||
CURRENT_PG_VERSION=$(kubectl exec keycloak-postgresql-0 -- bash -c 'echo $BITNAMI_IMAGE_VERSION')
|
||||
helm upgrade keycloak bitnami/keycloak \
|
||||
--set auth.adminPassword=$KEYCLOAK_PASSWORD \
|
||||
--set postgresql.image.tag=$CURRENT_PG_VERSION \
|
||||
--set postgresql.auth.password=$POSTGRESQL_PASSWORD \
|
||||
--set postgresql.persistence.existingClaim=$POSTGRESQL_PVC
|
||||
```
|
||||
|
||||
1. Delete the existing PostgreSQL pods and the new statefulset will create a new one:
|
||||
|
||||
```console
|
||||
kubectl delete pod keycloak-postgresql-0
|
||||
```
|
||||
|
||||
### To 1.0.0
|
||||
|
||||
[On November 13, 2020, Helm v2 support was formally finished](https://github.com/helm/charts#status-of-the-project), this major version is the result of the required changes applied to the Helm Chart to be able to incorporate the different features added in Helm v3 and to be consistent with the Helm project itself regarding the Helm v2 EOL.
|
||||
|
||||
#### What changes were introduced in this major version?
|
||||
|
||||
- Previous versions of this Helm Chart use `apiVersion: v1` (installable by both Helm 2 and 3), this Helm Chart was updated to `apiVersion: v2` (installable by Helm 3 only). [Here](https://helm.sh/docs/topics/charts/#the-apiversion-field) you can find more information about the `apiVersion` field.
|
||||
- Move dependency information from the *requirements.yaml* to the *Chart.yaml*
|
||||
- After running *helm dependency update*, a *Chart.lock* file is generated containing the same structure used in the previous *requirements.lock*
|
||||
- The different fields present in the *Chart.yaml* file has been ordered alphabetically in a homogeneous way for all the Bitnami Helm Chart.
|
||||
|
||||
#### Considerations when upgrading to this version
|
||||
|
||||
- If you want to upgrade to this version using Helm v2, this scenario is not supported as this version does not support Helm v2 anymore.
|
||||
- If you installed the previous version with Helm v2 and wants to upgrade to this version with Helm v3, please refer to the [official Helm documentation](https://helm.sh/docs/topics/v2_v3_migration/#migration-use-cases) about migrating from Helm v2 to v3.
|
||||
|
||||
#### Useful links
|
||||
|
||||
- [Bitnami Tutorial](https://techdocs.broadcom.com/us/en/vmware-tanzu/application-catalog/tanzu-application-catalog/services/tac-doc/apps-tutorials-resolve-helm2-helm3-post-migration-issues-index.html)
|
||||
- [Helm docs](https://helm.sh/docs/topics/v2_v3_migration)
|
||||
- [Helm Blog](https://helm.sh/blog/migrate-from-helm-v2-to-helm-v3)
|
||||
|
||||
## License
|
||||
|
||||
Copyright © 2025 Broadcom. The term "Broadcom" refers to Broadcom Inc. and/or its subsidiaries.
|
||||
|
||||
Licensed under the Apache License, Version 2.0 (the "License");
|
||||
you may not use this file except in compliance with the License.
|
||||
You may obtain a copy of the License at
|
||||
|
||||
<http://www.apache.org/licenses/LICENSE-2.0>
|
||||
|
||||
Unless required by applicable law or agreed to in writing, software
|
||||
distributed under the License is distributed on an "AS IS" BASIS,
|
||||
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
See the License for the specific language governing permissions and
|
||||
limitations under the License.
|
||||
Binary file not shown.
Binary file not shown.
@@ -1,109 +0,0 @@
|
||||
CHART NAME: {{ .Chart.Name }}
|
||||
CHART VERSION: {{ .Chart.Version }}
|
||||
APP VERSION: {{ .Chart.AppVersion }}
|
||||
|
||||
⚠ WARNING: Since August 28th, 2025, only a limited subset of images/charts are available for free.
|
||||
Subscribe to Bitnami Secure Images to receive continued support and security updates.
|
||||
More info at https://bitnami.com and https://github.com/bitnami/containers/issues/83267
|
||||
|
||||
** Please be patient while the chart is being deployed **
|
||||
|
||||
Keycloak can be accessed through the following DNS name from within your cluster:
|
||||
|
||||
{{ include "common.names.fullname" . }}.{{ include "common.names.namespace" . }}.svc.{{ .Values.clusterDomain }} (port {{ coalesce .Values.service.ports.http .Values.service.port }})
|
||||
|
||||
To access Keycloak from outside the cluster execute the following commands:
|
||||
|
||||
{{- if .Values.ingress.enabled }}
|
||||
|
||||
1. Get the Keycloak URL and associate its hostname to your cluster external IP:
|
||||
|
||||
export CLUSTER_IP=$(minikube ip) # On Minikube. Use: `kubectl cluster-info` on others K8s clusters
|
||||
echo "Keycloak URL: http{{ if .Values.ingress.tls }}s{{ end }}://{{ (tpl .Values.ingress.hostname .) }}/"
|
||||
echo "$CLUSTER_IP {{ (tpl .Values.ingress.hostname .) }}" | sudo tee -a /etc/hosts
|
||||
|
||||
{{- if .Values.adminIngress.enabled }}
|
||||
The admin area of Keycloak has been configured to point to a different domain ({{ .Values.adminIngress.hostname }}). Please remember to update the `frontendUrl` property of the `{{ .Values.adminRealm | default "master" }}` (or any other) realm for it to work properly (see README for an example) :
|
||||
|
||||
echo "Keycloak admin URL: http{{ if .Values.adminIngress.tls }}s{{ end }}://{{ (tpl .Values.adminIngress.hostname .) }}/"
|
||||
echo "$CLUSTER_IP {{ (tpl .Values.adminIngress.hostname .) }}" | sudo tee -a /etc/hosts
|
||||
{{- end }}
|
||||
|
||||
{{- else }}
|
||||
|
||||
1. Get the Keycloak URL by running these commands:
|
||||
|
||||
{{- if contains "NodePort" .Values.service.type }}
|
||||
|
||||
export HTTP_NODE_PORT=$(kubectl get --namespace {{ include "common.names.namespace" . }} -o jsonpath="{.spec.ports[?(@.name=='http')].nodePort}" services {{ include "common.names.fullname" . }})
|
||||
{{- if .Values.tls.enabled }}
|
||||
export HTTPS_NODE_PORT=$(kubectl get --namespace {{ include "common.names.namespace" . }} -o jsonpath="{.spec.ports[?(@.name=='https')].nodePort}" services {{ include "common.names.fullname" . }})
|
||||
{{- end }}
|
||||
export NODE_IP=$(kubectl get nodes --namespace {{ include "common.names.namespace" . }} -o jsonpath="{.items[0].status.addresses[0].address}")
|
||||
|
||||
echo "http://${NODE_IP}:${HTTP_NODE_PORT}/"
|
||||
{{- if .Values.tls.enabled }}
|
||||
echo "https://${NODE_IP}:${HTTPS_NODE_PORT}/"
|
||||
{{- end }}
|
||||
|
||||
{{- else if contains "LoadBalancer" .Values.service.type }}
|
||||
|
||||
NOTE: It may take a few minutes for the LoadBalancer IP to be available.
|
||||
You can watch its status by running 'kubectl get --namespace {{ include "common.names.namespace" . }} svc -w {{ include "common.names.fullname" . }}'
|
||||
|
||||
export HTTP_SERVICE_PORT=$(kubectl get --namespace {{ include "common.names.namespace" . }} -o jsonpath="{.spec.ports[?(@.name=='http')].port}" services {{ include "common.names.fullname" . }})
|
||||
{{- if .Values.tls.enabled }}
|
||||
export HTTPS_SERVICE_PORT=$(kubectl get --namespace {{ include "common.names.namespace" . }} -o jsonpath="{.spec.ports[?(@.name=='https')].port}" services {{ include "common.names.fullname" . }})
|
||||
{{- end }}
|
||||
export SERVICE_IP=$(kubectl get svc --namespace {{ include "common.names.namespace" . }} {{ include "common.names.fullname" . }} -o jsonpath='{.status.loadBalancer.ingress[0].ip}')
|
||||
|
||||
echo "http://${SERVICE_IP}:${HTTP_SERVICE_PORT}/"
|
||||
{{- if .Values.tls.enabled }}
|
||||
echo "https://${SERVICE_IP}:${HTTPS_SERVICE_PORT}/"
|
||||
{{- end }}
|
||||
|
||||
{{- else if contains "ClusterIP" .Values.service.type }}
|
||||
|
||||
export HTTP_SERVICE_PORT=$(kubectl get --namespace {{ include "common.names.namespace" . }} -o jsonpath="{.spec.ports[?(@.name=='http')].port}" services {{ include "common.names.fullname" . }})
|
||||
{{- if .Values.tls.enabled }}
|
||||
export HTTPS_SERVICE_PORT=$(kubectl get --namespace {{ include "common.names.namespace" . }} -o jsonpath="{.spec.ports[?(@.name=='https')].port}" services {{ include "common.names.fullname" . }})
|
||||
kubectl port-forward --namespace {{ include "common.names.namespace" . }} svc/{{ include "common.names.fullname" . }} ${HTTP_SERVICE_PORT}:${HTTP_SERVICE_PORT} ${HTTPS_SERVICE_PORT}:${HTTPS_SERVICE_PORT} &
|
||||
{{- else }}
|
||||
kubectl port-forward --namespace {{ include "common.names.namespace" . }} svc/{{ include "common.names.fullname" . }} ${HTTP_SERVICE_PORT}:${HTTP_SERVICE_PORT} &
|
||||
{{- end }}
|
||||
|
||||
echo "http://127.0.0.1:${HTTP_SERVICE_PORT}/"
|
||||
{{- if .Values.tls.enabled }}
|
||||
echo "https://127.0.0.1:${HTTPS_SERVICE_PORT}/"
|
||||
{{- end }}
|
||||
|
||||
{{- end }}
|
||||
{{- end }}
|
||||
|
||||
2. Access Keycloak using the obtained URL.
|
||||
{{- if and .Values.auth.adminUser .Values.auth.adminPassword }}
|
||||
3. Access the Administration Console using the following credentials:
|
||||
|
||||
echo Username: {{ .Values.auth.adminUser }}
|
||||
echo Password: $(kubectl get secret --namespace {{ include "common.names.namespace" . }} {{ include "keycloak.secretName" . }} -o jsonpath="{.data.{{ include "keycloak.secretKey" .}}}" | base64 -d)
|
||||
{{- end }}
|
||||
{{- if .Values.metrics.enabled }}
|
||||
|
||||
You can access the Prometheus metrics following the steps below:
|
||||
|
||||
1. Get the Keycloak Prometheus metrics URL by running:
|
||||
|
||||
{{- $metricsPort := coalesce .Values.metrics.service.ports.metrics .Values.metrics.service.port | toString }}
|
||||
kubectl port-forward --namespace {{ include "common.names.namespace" . }} svc/{{ printf "%s-metrics" (include "common.names.fullname" .) }} {{ $metricsPort }}:{{ $metricsPort }} &
|
||||
echo "Keycloak Prometheus metrics URL: http://127.0.0.1:{{ $metricsPort }}/metrics"
|
||||
|
||||
2. Open a browser and access Keycloak Prometheus metrics using the obtained URL.
|
||||
|
||||
{{- end }}
|
||||
|
||||
{{- include "keycloak.validateValues" . }}
|
||||
{{- include "common.warnings.rollingTag" .Values.image }}
|
||||
{{- include "common.warnings.rollingTag" .Values.keycloakConfigCli.image }}
|
||||
{{- include "common.warnings.resources" (dict "sections" (list "keycloakConfigCli" "") "context" $) }}
|
||||
{{- include "common.warnings.modifiedImages" (dict "images" (list .Values.image .Values.keycloakConfigCli.image) "context" $) }}
|
||||
{{- include "common.errors.insecureImages" (dict "images" (list .Values.image .Values.keycloakConfigCli.image) "context" $) }}
|
||||
@@ -1,355 +0,0 @@
|
||||
{{/*
|
||||
Copyright Broadcom, Inc. All Rights Reserved.
|
||||
SPDX-License-Identifier: APACHE-2.0
|
||||
*/}}
|
||||
|
||||
{{/*
|
||||
Return the proper Keycloak image name
|
||||
*/}}
|
||||
{{- define "keycloak.image" -}}
|
||||
{{ include "common.images.image" (dict "imageRoot" .Values.image "global" .Values.global) }}
|
||||
{{- end -}}
|
||||
|
||||
{{/*
|
||||
Return the proper keycloak-config-cli image name
|
||||
*/}}
|
||||
{{- define "keycloak.keycloakConfigCli.image" -}}
|
||||
{{ include "common.images.image" (dict "imageRoot" .Values.keycloakConfigCli.image "global" .Values.global) }}
|
||||
{{- end -}}
|
||||
|
||||
{{/*
|
||||
Return the keycloak-config-cli configuration configmap.
|
||||
*/}}
|
||||
{{- define "keycloak.keycloakConfigCli.configmapName" -}}
|
||||
{{- if .Values.keycloakConfigCli.existingConfigmap -}}
|
||||
{{- printf "%s" (tpl .Values.keycloakConfigCli.existingConfigmap $) -}}
|
||||
{{- else -}}
|
||||
{{- printf "%s-keycloak-config-cli-configmap" (include "common.names.fullname" .) -}}
|
||||
{{- end -}}
|
||||
{{- end -}}
|
||||
|
||||
{{/*
|
||||
Return true if a configmap object should be created for keycloak-config-cli
|
||||
*/}}
|
||||
{{- define "keycloak.keycloakConfigCli.createConfigmap" -}}
|
||||
{{- if and .Values.keycloakConfigCli.enabled .Values.keycloakConfigCli.configuration (not .Values.keycloakConfigCli.existingConfigmap) -}}
|
||||
{{- true -}}
|
||||
{{- end -}}
|
||||
{{- end -}}
|
||||
|
||||
{{/*
|
||||
Return the proper Docker Image Registry Secret Names
|
||||
*/}}
|
||||
{{- define "keycloak.imagePullSecrets" -}}
|
||||
{{- include "common.images.renderPullSecrets" (dict "images" (list .Values.image .Values.keycloakConfigCli.image) "context" $) -}}
|
||||
{{- end -}}
|
||||
|
||||
{{/*
|
||||
Create a default fully qualified app name.
|
||||
We truncate at 63 chars because some Kubernetes name fields are limited to this (by the DNS naming spec).
|
||||
*/}}
|
||||
{{- define "keycloak.postgresql.fullname" -}}
|
||||
{{- include "common.names.dependency.fullname" (dict "chartName" "postgresql" "chartValues" .Values.postgresql "context" $) -}}
|
||||
{{- end -}}
|
||||
|
||||
{{/*
|
||||
Create the name of the service account to use
|
||||
*/}}
|
||||
{{- define "keycloak.serviceAccountName" -}}
|
||||
{{- if .Values.serviceAccount.create -}}
|
||||
{{ default (include "common.names.fullname" .) .Values.serviceAccount.name }}
|
||||
{{- else -}}
|
||||
{{ default "default" .Values.serviceAccount.name }}
|
||||
{{- end -}}
|
||||
{{- end -}}
|
||||
|
||||
{{/*
|
||||
Return the path Keycloak is hosted on. This looks at httpRelativePath and returns it with a trailing slash. For example:
|
||||
/ -> / (the default httpRelativePath)
|
||||
/auth -> /auth/ (trailing slash added)
|
||||
/custom/ -> /custom/ (unchanged)
|
||||
*/}}
|
||||
{{- define "keycloak.httpPath" -}}
|
||||
{{ ternary .Values.httpRelativePath (printf "%s%s" .Values.httpRelativePath "/") (hasSuffix "/" .Values.httpRelativePath) }}
|
||||
{{- end -}}
|
||||
|
||||
{{/*
|
||||
Return the Keycloak configuration configmap
|
||||
*/}}
|
||||
{{- define "keycloak.configmapName" -}}
|
||||
{{- if .Values.existingConfigmap -}}
|
||||
{{- printf "%s" (tpl .Values.existingConfigmap $) -}}
|
||||
{{- else -}}
|
||||
{{- printf "%s-configuration" (include "common.names.fullname" .) -}}
|
||||
{{- end -}}
|
||||
{{- end -}}
|
||||
|
||||
{{/*
|
||||
Return true if a configmap object should be created
|
||||
*/}}
|
||||
{{- define "keycloak.createConfigmap" -}}
|
||||
{{- if and .Values.configuration (not .Values.existingConfigmap) }}
|
||||
{{- true -}}
|
||||
{{- end -}}
|
||||
{{- end -}}
|
||||
|
||||
{{/*
|
||||
Return the Database hostname
|
||||
*/}}
|
||||
{{- define "keycloak.databaseHost" -}}
|
||||
{{- if eq .Values.postgresql.architecture "replication" }}
|
||||
{{- ternary (include "keycloak.postgresql.fullname" .) (tpl .Values.externalDatabase.host $) .Values.postgresql.enabled -}}-primary
|
||||
{{- else -}}
|
||||
{{- ternary (include "keycloak.postgresql.fullname" .) (tpl .Values.externalDatabase.host $) .Values.postgresql.enabled -}}
|
||||
{{- end -}}
|
||||
{{- end -}}
|
||||
|
||||
{{/*
|
||||
Return the Database port
|
||||
*/}}
|
||||
{{- define "keycloak.databasePort" -}}
|
||||
{{- ternary "5432" (tpl (.Values.externalDatabase.port | toString) $) .Values.postgresql.enabled | quote -}}
|
||||
{{- end -}}
|
||||
|
||||
{{/*
|
||||
Return the Database database name
|
||||
*/}}
|
||||
{{- define "keycloak.databaseName" -}}
|
||||
{{- if .Values.postgresql.enabled }}
|
||||
{{- if .Values.global.postgresql }}
|
||||
{{- if .Values.global.postgresql.auth }}
|
||||
{{- coalesce .Values.global.postgresql.auth.database .Values.postgresql.auth.database -}}
|
||||
{{- else -}}
|
||||
{{- .Values.postgresql.auth.database -}}
|
||||
{{- end -}}
|
||||
{{- else -}}
|
||||
{{- .Values.postgresql.auth.database -}}
|
||||
{{- end -}}
|
||||
{{- else -}}
|
||||
{{- tpl .Values.externalDatabase.database $ -}}
|
||||
{{- end -}}
|
||||
{{- end -}}
|
||||
|
||||
{{/*
|
||||
Return the Database port
|
||||
*/}}
|
||||
{{- define "keycloak.databaseSchema" -}}
|
||||
{{- ternary "public" (tpl (.Values.externalDatabase.schema | toString) $) .Values.postgresql.enabled | quote -}}
|
||||
{{- end -}}
|
||||
|
||||
{{/*
|
||||
Return the Database user
|
||||
*/}}
|
||||
{{- define "keycloak.databaseUser" -}}
|
||||
{{- if .Values.postgresql.enabled -}}
|
||||
{{- if .Values.global.postgresql -}}
|
||||
{{- if .Values.global.postgresql.auth -}}
|
||||
{{- coalesce .Values.global.postgresql.auth.username .Values.postgresql.auth.username -}}
|
||||
{{- else -}}
|
||||
{{- .Values.postgresql.auth.username -}}
|
||||
{{- end -}}
|
||||
{{- else -}}
|
||||
{{- .Values.postgresql.auth.username -}}
|
||||
{{- end -}}
|
||||
{{- else -}}
|
||||
{{- tpl .Values.externalDatabase.user $ -}}
|
||||
{{- end -}}
|
||||
{{- end -}}
|
||||
|
||||
{{/*
|
||||
Return the Database encrypted password
|
||||
*/}}
|
||||
{{- define "keycloak.databaseSecretName" -}}
|
||||
{{- if .Values.postgresql.enabled -}}
|
||||
{{- if .Values.global.postgresql -}}
|
||||
{{- if .Values.global.postgresql.auth -}}
|
||||
{{- if .Values.global.postgresql.auth.existingSecret -}}
|
||||
{{- tpl .Values.global.postgresql.auth.existingSecret $ -}}
|
||||
{{- else -}}
|
||||
{{- default (include "keycloak.postgresql.fullname" .) (tpl .Values.postgresql.auth.existingSecret $) -}}
|
||||
{{- end -}}
|
||||
{{- else -}}
|
||||
{{- default (include "keycloak.postgresql.fullname" .) (tpl .Values.postgresql.auth.existingSecret $) -}}
|
||||
{{- end -}}
|
||||
{{- else -}}
|
||||
{{- default (include "keycloak.postgresql.fullname" .) (tpl .Values.postgresql.auth.existingSecret $) -}}
|
||||
{{- end -}}
|
||||
{{- else -}}
|
||||
{{- default (printf "%s-externaldb" (include "common.names.fullname" .)) (tpl .Values.externalDatabase.existingSecret $) -}}
|
||||
{{- end -}}
|
||||
{{- end -}}
|
||||
|
||||
{{/*
|
||||
Add environment variables to configure database values
|
||||
*/}}
|
||||
{{- define "keycloak.databaseSecretPasswordKey" -}}
|
||||
{{- if .Values.postgresql.enabled -}}
|
||||
{{- printf "%s" (.Values.postgresql.auth.secretKeys.userPasswordKey | default "password") -}}
|
||||
{{- else -}}
|
||||
{{- if .Values.externalDatabase.existingSecret -}}
|
||||
{{- if .Values.externalDatabase.existingSecretPasswordKey -}}
|
||||
{{- printf "%s" .Values.externalDatabase.existingSecretPasswordKey -}}
|
||||
{{- else -}}
|
||||
{{- print "db-password" -}}
|
||||
{{- end -}}
|
||||
{{- else -}}
|
||||
{{- print "db-password" -}}
|
||||
{{- end -}}
|
||||
{{- end -}}
|
||||
{{- end -}}
|
||||
|
||||
{{- define "keycloak.databaseSecretHostKey" -}}
|
||||
{{- if .Values.externalDatabase.existingSecretHostKey -}}
|
||||
{{- printf "%s" .Values.externalDatabase.existingSecretHostKey -}}
|
||||
{{- else -}}
|
||||
{{- print "db-host" -}}
|
||||
{{- end -}}
|
||||
{{- end -}}
|
||||
{{- define "keycloak.databaseSecretPortKey" -}}
|
||||
{{- if .Values.externalDatabase.existingSecretPortKey -}}
|
||||
{{- printf "%s" .Values.externalDatabase.existingSecretPortKey -}}
|
||||
{{- else -}}
|
||||
{{- print "db-port" -}}
|
||||
{{- end -}}
|
||||
{{- end -}}
|
||||
{{- define "keycloak.databaseSecretUserKey" -}}
|
||||
{{- if .Values.externalDatabase.existingSecretUserKey -}}
|
||||
{{- printf "%s" .Values.externalDatabase.existingSecretUserKey -}}
|
||||
{{- else -}}
|
||||
{{- print "db-user" -}}
|
||||
{{- end -}}
|
||||
{{- end -}}
|
||||
{{- define "keycloak.databaseSecretDatabaseKey" -}}
|
||||
{{- if .Values.externalDatabase.existingSecretDatabaseKey -}}
|
||||
{{- printf "%s" .Values.externalDatabase.existingSecretDatabaseKey -}}
|
||||
{{- else -}}
|
||||
{{- print "db-database" -}}
|
||||
{{- end -}}
|
||||
{{- end -}}
|
||||
|
||||
{{/*
|
||||
Return the Keycloak initdb scripts configmap
|
||||
*/}}
|
||||
{{- define "keycloak.initdbScriptsCM" -}}
|
||||
{{- if .Values.initdbScriptsConfigMap -}}
|
||||
{{- printf "%s" .Values.initdbScriptsConfigMap -}}
|
||||
{{- else -}}
|
||||
{{- printf "%s-init-scripts" (include "common.names.fullname" .) -}}
|
||||
{{- end -}}
|
||||
{{- end -}}
|
||||
|
||||
{{/*
|
||||
Return the secret containing the Keycloak admin password
|
||||
*/}}
|
||||
{{- define "keycloak.secretName" -}}
|
||||
{{- $secretName := .Values.auth.existingSecret -}}
|
||||
{{- if $secretName -}}
|
||||
{{- printf "%s" (tpl $secretName $) -}}
|
||||
{{- else -}}
|
||||
{{- printf "%s" (include "common.names.fullname" .) | trunc 63 | trimSuffix "-" -}}
|
||||
{{- end -}}
|
||||
{{- end -}}
|
||||
|
||||
{{/*
|
||||
Return the secret key that contains the Keycloak admin password
|
||||
*/}}
|
||||
{{- define "keycloak.secretKey" -}}
|
||||
{{- $secretName := .Values.auth.existingSecret -}}
|
||||
{{- if and $secretName .Values.auth.passwordSecretKey -}}
|
||||
{{- printf "%s" .Values.auth.passwordSecretKey -}}
|
||||
{{- else -}}
|
||||
{{- print "admin-password" -}}
|
||||
{{- end -}}
|
||||
{{- end -}}
|
||||
|
||||
{{/*
|
||||
Return the secret containing Keycloak HTTPS/TLS certificates
|
||||
*/}}
|
||||
{{- define "keycloak.tlsSecretName" -}}
|
||||
{{- $secretName := .Values.tls.existingSecret -}}
|
||||
{{- if $secretName -}}
|
||||
{{- printf "%s" (tpl $secretName $) -}}
|
||||
{{- else -}}
|
||||
{{- printf "%s-crt" (include "common.names.fullname" .) -}}
|
||||
{{- end -}}
|
||||
{{- end -}}
|
||||
|
||||
{{/*
|
||||
Return the secret containing Keycloak HTTPS/TLS keystore and truststore passwords
|
||||
*/}}
|
||||
{{- define "keycloak.tlsPasswordsSecretName" -}}
|
||||
{{- $secretName := .Values.tls.passwordsSecret -}}
|
||||
{{- if $secretName -}}
|
||||
{{- printf "%s" (tpl $secretName $) -}}
|
||||
{{- else -}}
|
||||
{{- printf "%s-tls-passwords" (include "common.names.fullname" .) | trunc 63 | trimSuffix "-" -}}
|
||||
{{- end -}}
|
||||
{{- end -}}
|
||||
|
||||
{{/*
|
||||
Return the secret containing Keycloak SPI TLS certificates
|
||||
*/}}
|
||||
{{- define "keycloak.spiPasswordsSecretName" -}}
|
||||
{{- $secretName := .Values.spi.passwordsSecret -}}
|
||||
{{- if $secretName -}}
|
||||
{{- printf "%s" (tpl $secretName $) -}}
|
||||
{{- else -}}
|
||||
{{- printf "%s-spi-passwords" (include "common.names.fullname" .) | trunc 63 | trimSuffix "-" -}}
|
||||
{{- end -}}
|
||||
{{- end -}}
|
||||
|
||||
{{/*
|
||||
Return true if a TLS secret object should be created
|
||||
*/}}
|
||||
{{- define "keycloak.createTlsSecret" -}}
|
||||
{{- if and .Values.tls.enabled .Values.tls.autoGenerated (not .Values.tls.existingSecret) }}
|
||||
{{- true -}}
|
||||
{{- end -}}
|
||||
{{- end -}}
|
||||
|
||||
{{/*
|
||||
Compile all warnings into a single message.
|
||||
*/}}
|
||||
{{- define "keycloak.validateValues" -}}
|
||||
{{- $messages := list -}}
|
||||
{{- $messages := append $messages (include "keycloak.validateValues.database" .) -}}
|
||||
{{- $messages := append $messages (include "keycloak.validateValues.tls" .) -}}
|
||||
{{- $messages := append $messages (include "keycloak.validateValues.production" .) -}}
|
||||
{{- $messages := without $messages "" -}}
|
||||
{{- $message := join "\n" $messages -}}
|
||||
|
||||
{{- if $message -}}
|
||||
{{- printf "\nVALUES VALIDATION:\n%s" $message | fail -}}
|
||||
{{- end -}}
|
||||
{{- end -}}
|
||||
|
||||
{{/* Validate values of Keycloak - database */}}
|
||||
{{- define "keycloak.validateValues.database" -}}
|
||||
{{- if and (not .Values.postgresql.enabled) (not .Values.externalDatabase.host) (and (not .Values.externalDatabase.password) (not .Values.externalDatabase.existingSecret)) -}}
|
||||
keycloak: database
|
||||
You disabled the PostgreSQL sub-chart but did not specify an external PostgreSQL host.
|
||||
Either deploy the PostgreSQL sub-chart (--set postgresql.enabled=true),
|
||||
or set a value for the external database host (--set externalDatabase.host=FOO)
|
||||
and set a value for the external database password (--set externalDatabase.password=BAR)
|
||||
or existing secret (--set externalDatabase.existingSecret=BAR).
|
||||
{{- end -}}
|
||||
{{- end -}}
|
||||
|
||||
{{/* Validate values of Keycloak - TLS enabled */}}
|
||||
{{- define "keycloak.validateValues.tls" -}}
|
||||
{{- if and .Values.tls.enabled (not .Values.tls.autoGenerated) (not .Values.tls.existingSecret) }}
|
||||
keycloak: tls.enabled
|
||||
In order to enable TLS, you also need to provide
|
||||
an existing secret containing the Keystore and Truststore or
|
||||
enable auto-generated certificates.
|
||||
{{- end -}}
|
||||
{{- end -}}
|
||||
|
||||
{{/* Validate values of Keycloak - Production mode enabled */}}
|
||||
{{- define "keycloak.validateValues.production" -}}
|
||||
{{- if and .Values.production (not .Values.tls.enabled) (not (eq .Values.proxy "edge")) (empty .Values.proxyHeaders) -}}
|
||||
keycloak: production
|
||||
In order to enable Production mode, you also need to enable HTTPS/TLS
|
||||
using the value 'tls.enabled' and providing an existing secret containing the Keystore and Trustore.
|
||||
{{- end -}}
|
||||
{{- end -}}
|
||||
@@ -1,57 +0,0 @@
|
||||
{{- /*
|
||||
Copyright Broadcom, Inc. All Rights Reserved.
|
||||
SPDX-License-Identifier: APACHE-2.0
|
||||
*/}}
|
||||
|
||||
{{- if .Values.adminIngress.enabled }}
|
||||
apiVersion: {{ include "common.capabilities.ingress.apiVersion" . }}
|
||||
kind: Ingress
|
||||
metadata:
|
||||
name: {{ include "common.names.fullname" . }}-admin
|
||||
namespace: {{ include "common.names.namespace" . | quote }}
|
||||
{{- $labels := include "common.tplvalues.merge" ( dict "values" ( list .Values.adminIngress.labels .Values.commonLabels ) "context" . ) }}
|
||||
labels: {{- include "common.labels.standard" ( dict "customLabels" $labels "context" $ ) | nindent 4 }}
|
||||
app.kubernetes.io/component: keycloak
|
||||
{{- if or .Values.adminIngress.annotations .Values.commonAnnotations }}
|
||||
{{- $annotations := include "common.tplvalues.merge" ( dict "values" ( list .Values.adminIngress.annotations .Values.commonAnnotations ) "context" . ) }}
|
||||
annotations: {{- include "common.tplvalues.render" ( dict "value" $annotations "context" $) | nindent 4 }}
|
||||
{{- end }}
|
||||
spec:
|
||||
{{- if .Values.adminIngress.ingressClassName }}
|
||||
ingressClassName: {{ include "common.tplvalues.render" ( dict "value" .Values.adminIngress.ingressClassName "context" $ ) | quote }}
|
||||
{{- end }}
|
||||
rules:
|
||||
{{- if .Values.adminIngress.hostname }}
|
||||
- host: {{ (tpl .Values.adminIngress.hostname .) | quote }}
|
||||
http:
|
||||
paths:
|
||||
{{- if .Values.adminIngress.extraPaths }}
|
||||
{{- toYaml .Values.adminIngress.extraPaths | nindent 10 }}
|
||||
{{- end }}
|
||||
- path: {{ include "common.tplvalues.render" ( dict "value" .Values.adminIngress.path "context" $) }}
|
||||
pathType: {{ .Values.adminIngress.pathType }}
|
||||
backend: {{- include "common.ingress.backend" (dict "serviceName" (include "common.names.fullname" .) "servicePort" .Values.adminIngress.servicePort "context" $) | nindent 14 }}
|
||||
{{- end }}
|
||||
{{- range .Values.adminIngress.extraHosts }}
|
||||
- host: {{ (tpl .name $) }}
|
||||
http:
|
||||
paths:
|
||||
- path: {{ default "/" .path }}
|
||||
pathType: {{ default "ImplementationSpecific" .pathType }}
|
||||
backend: {{- include "common.ingress.backend" (dict "serviceName" (include "common.names.fullname" $) "servicePort" $.Values.adminIngress.servicePort "context" $) | nindent 14 }}
|
||||
{{- end }}
|
||||
{{- if .Values.adminIngress.extraRules }}
|
||||
{{- include "common.tplvalues.render" (dict "value" .Values.adminIngress.extraRules "context" $) | nindent 4 }}
|
||||
{{- end }}
|
||||
{{- if or (and .Values.adminIngress.tls (or (include "common.ingress.certManagerRequest" ( dict "annotations" .Values.adminIngress.annotations )) .Values.adminIngress.selfSigned .Values.adminIngress.secrets )) .Values.adminIngress.extraTls }}
|
||||
tls:
|
||||
{{- if and .Values.adminIngress.tls (or (include "common.ingress.certManagerRequest" ( dict "annotations" .Values.adminIngress.annotations )) .Values.adminIngress.secrets .Values.adminIngress.selfSigned) }}
|
||||
- hosts:
|
||||
- {{ (tpl .Values.adminIngress.hostname .) | quote }}
|
||||
secretName: {{ printf "%s-tls" (tpl .Values.adminIngress.hostname .) }}
|
||||
{{- end }}
|
||||
{{- if .Values.adminIngress.extraTls }}
|
||||
{{- include "common.tplvalues.render" (dict "value" .Values.adminIngress.extraTls "context" $) | nindent 4 }}
|
||||
{{- end }}
|
||||
{{- end }}
|
||||
{{- end }}
|
||||
@@ -1,109 +0,0 @@
|
||||
{{- /*
|
||||
Copyright Broadcom, Inc. All Rights Reserved.
|
||||
SPDX-License-Identifier: APACHE-2.0
|
||||
*/}}
|
||||
|
||||
apiVersion: v1
|
||||
kind: ConfigMap
|
||||
metadata:
|
||||
name: {{ printf "%s-env-vars" (include "common.names.fullname" .) }}
|
||||
namespace: {{ include "common.names.namespace" . | quote }}
|
||||
labels: {{- include "common.labels.standard" ( dict "customLabels" .Values.commonLabels "context" $ ) | nindent 4 }}
|
||||
app.kubernetes.io/component: keycloak
|
||||
{{- if .Values.commonAnnotations }}
|
||||
annotations: {{- include "common.tplvalues.render" ( dict "value" .Values.commonAnnotations "context" $ ) | nindent 4 }}
|
||||
{{- end }}
|
||||
data:
|
||||
KC_BOOTSTRAP_ADMIN_USERNAME: {{ .Values.auth.adminUser | quote }}
|
||||
KEYCLOAK_HTTP_PORT: {{ .Values.containerPorts.http | quote }}
|
||||
{{- if and .Values.proxy (empty .Values.proxyHeaders) }}
|
||||
KEYCLOAK_PROXY_HEADERS: {{ ternary "" "xforwarded" (eq .Values.proxy "passthrough") | quote }}
|
||||
{{- else }}
|
||||
KEYCLOAK_PROXY_HEADERS: {{ .Values.proxyHeaders | quote }}
|
||||
{{- end }}
|
||||
{{- if and .Values.adminIngress.enabled .Values.adminIngress.hostname }}
|
||||
KEYCLOAK_HOSTNAME_ADMIN: |-
|
||||
{{ ternary "https://" "http://" ( or .Values.adminIngress.tls (eq .Values.proxy "edge") (not (empty .Values.proxyHeaders)) ) -}} {{- include "common.tplvalues.render" (dict "value" .Values.adminIngress.hostname "context" $) -}}
|
||||
{{- if eq .Values.adminIngress.controller "default" }}
|
||||
{{- include "common.tplvalues.render" (dict "value" .Values.adminIngress.path "context" $) }}
|
||||
{{- else if eq .Values.adminIngress.controller "gce" }}
|
||||
{{- $path := .Values.adminIngress.path -}}
|
||||
{{- if hasSuffix "*" $path -}}
|
||||
{{- $path = trimSuffix "*" $path -}}
|
||||
{{- end -}}
|
||||
{{- include "common.tplvalues.render" (dict "value" $path "context" $) }}
|
||||
{{- end }}
|
||||
{{- end }}
|
||||
{{- if and .Values.ingress.enabled .Values.ingress.hostname }}
|
||||
KEYCLOAK_HOSTNAME: |-
|
||||
{{ ternary "https://" "http://" ( or .Values.ingress.tls (eq .Values.proxy "edge") (not (empty .Values.proxyHeaders)) ) -}} {{- include "common.tplvalues.render" (dict "value" .Values.ingress.hostname "context" $) -}}
|
||||
{{- if eq .Values.ingress.controller "default" }}
|
||||
{{- include "common.tplvalues.render" (dict "value" .Values.ingress.path "context" $) }}
|
||||
{{- else if eq .Values.ingress.controller "gce" }}
|
||||
{{- $path := .Values.ingress.path -}}
|
||||
{{- if hasSuffix "*" $path -}}
|
||||
{{- $path = trimSuffix "*" $path -}}
|
||||
{{- end -}}
|
||||
{{- include "common.tplvalues.render" (dict "value" $path "context" $) }}
|
||||
{{- end }}
|
||||
{{- end }}
|
||||
{{- if .Values.ingress.enabled }}
|
||||
KEYCLOAK_HOSTNAME_STRICT: {{ ternary "true" "false" .Values.ingress.hostnameStrict | quote }}
|
||||
{{- end }}
|
||||
KEYCLOAK_ENABLE_STATISTICS: {{ ternary "true" "false" .Values.metrics.enabled | quote }}
|
||||
{{- if not .Values.externalDatabase.existingSecretHostKey }}
|
||||
KEYCLOAK_DATABASE_HOST: {{ include "keycloak.databaseHost" . | quote }}
|
||||
{{- end }}
|
||||
{{- if not .Values.externalDatabase.existingSecretPortKey }}
|
||||
KEYCLOAK_DATABASE_PORT: {{ include "keycloak.databasePort" . }}
|
||||
{{- end }}
|
||||
{{- if not .Values.externalDatabase.existingSecretDatabaseKey }}
|
||||
KEYCLOAK_DATABASE_NAME: {{ include "keycloak.databaseName" . | quote }}
|
||||
{{- end }}
|
||||
KEYCLOAK_DATABASE_SCHEMA: {{ include "keycloak.databaseSchema" . }}
|
||||
{{- if not .Values.externalDatabase.existingSecretUserKey }}
|
||||
KEYCLOAK_DATABASE_USER: {{ include "keycloak.databaseUser" . | quote }}
|
||||
{{- end }}
|
||||
KEYCLOAK_PRODUCTION: {{ ternary "true" "false" .Values.production | quote }}
|
||||
KEYCLOAK_ENABLE_HTTPS: {{ ternary "true" "false" .Values.tls.enabled | quote }}
|
||||
{{- if .Values.customCaExistingSecret }}
|
||||
KC_TRUSTSTORE_PATHS: "/opt/bitnami/keycloak/custom-ca"
|
||||
{{- end }}
|
||||
{{- if .Values.tls.enabled }}
|
||||
KEYCLOAK_HTTPS_PORT: {{ .Values.containerPorts.https | quote }}
|
||||
KEYCLOAK_HTTPS_USE_PEM: {{ ternary "true" "false" (or .Values.tls.usePem .Values.tls.autoGenerated) | quote }}
|
||||
{{- if or .Values.tls.usePem .Values.tls.autoGenerated }}
|
||||
KEYCLOAK_HTTPS_CERTIFICATE_FILE: "/opt/bitnami/keycloak/certs/tls.crt"
|
||||
KEYCLOAK_HTTPS_CERTIFICATE_KEY_FILE: "/opt/bitnami/keycloak/certs/tls.key"
|
||||
{{- else }}
|
||||
KEYCLOAK_HTTPS_KEY_STORE_FILE: {{ printf "/opt/bitnami/keycloak/certs/%s" .Values.tls.keystoreFilename | quote }}
|
||||
KEYCLOAK_HTTPS_TRUST_STORE_FILE: {{ printf "/opt/bitnami/keycloak/certs/%s" .Values.tls.truststoreFilename | quote }}
|
||||
{{- end }}
|
||||
{{- end }}
|
||||
{{- if .Values.spi.existingSecret }}
|
||||
{{- if .Values.spi.hostnameVerificationPolicy }}
|
||||
KEYCLOAK_SPI_TRUSTSTORE_FILE_HOSTNAME_VERIFICATION_POLICY: {{ .Values.spi.hostnameVerificationPolicy | quote }}
|
||||
{{- end }}
|
||||
KEYCLOAK_SPI_TRUSTSTORE_FILE: {{ printf "/opt/bitnami/keycloak/spi-certs/%s" .Values.spi.truststoreFilename }}
|
||||
{{- end }}
|
||||
{{- if .Values.cache.enabled }}
|
||||
KC_CACHE_TYPE: "ispn"
|
||||
{{- if .Values.cache.stack }}
|
||||
KC_CACHE_STACK: {{ .Values.cache.stack | quote }}
|
||||
{{- end }}
|
||||
{{- if .Values.cache.configFile }}
|
||||
KC_CACHE_CONFIG_FILE: {{ .Values.cache.configFile | quote }}
|
||||
{{- end }}
|
||||
{{- if .Values.cache.useHeadlessServiceWithAppVersion }}
|
||||
JAVA_OPTS_APPEND: {{ printf "-Djgroups.dns.query=%s-headless-ispn-%s.%s.svc.%s" (include "common.names.fullname" .) (replace "." "-" .Chart.AppVersion) (include "common.names.namespace" .) .Values.clusterDomain | quote }}
|
||||
{{- else }}
|
||||
JAVA_OPTS_APPEND: {{ printf "-Djgroups.dns.query=%s-headless.%s.svc.%s" (include "common.names.fullname" .) (include "common.names.namespace" .) .Values.clusterDomain | quote }}
|
||||
{{- end }}
|
||||
{{- else }}
|
||||
KC_CACHE_TYPE: "local"
|
||||
{{- end }}
|
||||
{{- if .Values.logging }}
|
||||
KEYCLOAK_LOG_OUTPUT: {{ .Values.logging.output | quote }}
|
||||
KEYCLOAK_LOG_LEVEL: {{ .Values.logging.level | quote }}
|
||||
{{- end }}
|
||||
|
||||
@@ -1,43 +0,0 @@
|
||||
{{- /*
|
||||
Copyright Broadcom, Inc. All Rights Reserved.
|
||||
SPDX-License-Identifier: APACHE-2.0
|
||||
*/}}
|
||||
|
||||
{{- if and .Values.cache.enabled .Values.cache.useHeadlessServiceWithAppVersion }}
|
||||
apiVersion: v1
|
||||
kind: Service
|
||||
metadata:
|
||||
name: {{ printf "%s-headless-ispn-%s" (include "common.names.fullname" .) (replace "." "-" .Chart.AppVersion) | trunc 63 | trimSuffix "-" }}
|
||||
namespace: {{ include "common.names.namespace" . | quote }}
|
||||
labels: {{- include "common.labels.standard" ( dict "customLabels" .Values.commonLabels "context" $ ) | nindent 4 }}
|
||||
app.kubernetes.io/component: keycloak
|
||||
{{- if or .Values.commonAnnotations .Values.service.headless.annotations }}
|
||||
{{- $annotations := include "common.tplvalues.merge" ( dict "values" ( list .Values.service.headless.annotations .Values.commonAnnotations ) "context" . ) }}
|
||||
annotations: {{- include "common.tplvalues.render" ( dict "value" $annotations "context" $) | nindent 4 }}
|
||||
{{- end }}
|
||||
spec:
|
||||
type: ClusterIP
|
||||
clusterIP: None
|
||||
ports:
|
||||
- name: http
|
||||
port: {{ .Values.containerPorts.http }}
|
||||
protocol: TCP
|
||||
targetPort: http
|
||||
{{- if .Values.tls.enabled }}
|
||||
- name: https
|
||||
port: {{ .Values.containerPorts.https }}
|
||||
protocol: TCP
|
||||
targetPort: https
|
||||
{{- end }}
|
||||
{{- if .Values.service.extraHeadlessPorts }}
|
||||
{{- include "common.tplvalues.render" (dict "value" .Values.service.extraHeadlessPorts "context" $) | nindent 4 }}
|
||||
{{- end }}
|
||||
{{- if .Values.service.headless.extraPorts }}
|
||||
{{- include "common.tplvalues.render" (dict "value" .Values.service.headless.extraPorts "context" $) | nindent 4 }}
|
||||
{{- end }}
|
||||
publishNotReadyAddresses: true
|
||||
{{- $podLabels := include "common.tplvalues.merge" ( dict "values" ( list .Values.podLabels .Values.commonLabels ) "context" . ) }}
|
||||
selector: {{- include "common.labels.matchLabels" ( dict "customLabels" $podLabels "context" $ ) | nindent 4 }}
|
||||
app.kubernetes.io/component: keycloak
|
||||
app.kubernetes.io/app-version: {{ .Chart.AppVersion }}
|
||||
{{- end }}
|
||||
@@ -1,40 +0,0 @@
|
||||
{{- /*
|
||||
Copyright Broadcom, Inc. All Rights Reserved.
|
||||
SPDX-License-Identifier: APACHE-2.0
|
||||
*/}}
|
||||
|
||||
apiVersion: v1
|
||||
kind: Service
|
||||
metadata:
|
||||
name: {{ printf "%s-headless" (include "common.names.fullname" .) | trunc 63 | trimSuffix "-" }}
|
||||
namespace: {{ include "common.names.namespace" . | quote }}
|
||||
labels: {{- include "common.labels.standard" ( dict "customLabels" .Values.commonLabels "context" $ ) | nindent 4 }}
|
||||
app.kubernetes.io/component: keycloak
|
||||
{{- if or .Values.commonAnnotations .Values.service.headless.annotations }}
|
||||
{{- $annotations := include "common.tplvalues.merge" ( dict "values" ( list .Values.service.headless.annotations .Values.commonAnnotations ) "context" . ) }}
|
||||
annotations: {{- include "common.tplvalues.render" ( dict "value" $annotations "context" $) | nindent 4 }}
|
||||
{{- end }}
|
||||
spec:
|
||||
type: ClusterIP
|
||||
clusterIP: None
|
||||
ports:
|
||||
- name: http
|
||||
port: {{ .Values.containerPorts.http }}
|
||||
protocol: TCP
|
||||
targetPort: http
|
||||
{{- if .Values.tls.enabled }}
|
||||
- name: https
|
||||
port: {{ .Values.containerPorts.https }}
|
||||
protocol: TCP
|
||||
targetPort: https
|
||||
{{- end }}
|
||||
{{- if .Values.service.extraHeadlessPorts }}
|
||||
{{- include "common.tplvalues.render" (dict "value" .Values.service.extraHeadlessPorts "context" $) | nindent 4 }}
|
||||
{{- end }}
|
||||
{{- if .Values.service.headless.extraPorts }}
|
||||
{{- include "common.tplvalues.render" (dict "value" .Values.service.headless.extraPorts "context" $) | nindent 4 }}
|
||||
{{- end }}
|
||||
publishNotReadyAddresses: true
|
||||
{{- $podLabels := include "common.tplvalues.merge" ( dict "values" ( list .Values.podLabels .Values.commonLabels ) "context" . ) }}
|
||||
selector: {{- include "common.labels.matchLabels" ( dict "customLabels" $podLabels "context" $ ) | nindent 4 }}
|
||||
app.kubernetes.io/component: keycloak
|
||||
@@ -1,58 +0,0 @@
|
||||
{{- /*
|
||||
Copyright Broadcom, Inc. All Rights Reserved.
|
||||
SPDX-License-Identifier: APACHE-2.0
|
||||
*/}}
|
||||
|
||||
{{- if .Values.autoscaling.enabled }}
|
||||
apiVersion: {{ include "common.capabilities.hpa.apiVersion" ( dict "context" $ ) }}
|
||||
kind: HorizontalPodAutoscaler
|
||||
metadata:
|
||||
name: {{ template "common.names.fullname" . }}
|
||||
namespace: {{ include "common.names.namespace" . | quote }}
|
||||
labels: {{- include "common.labels.standard" ( dict "customLabels" .Values.commonLabels "context" $ ) | nindent 4 }}
|
||||
app.kubernetes.io/component: keycloak
|
||||
{{- if .Values.commonAnnotations }}
|
||||
annotations: {{- include "common.tplvalues.render" ( dict "value" .Values.commonAnnotations "context" $ ) | nindent 4 }}
|
||||
{{- end }}
|
||||
spec:
|
||||
scaleTargetRef:
|
||||
apiVersion: {{ include "common.capabilities.statefulset.apiVersion" . }}
|
||||
kind: StatefulSet
|
||||
name: {{ template "common.names.fullname" . }}
|
||||
minReplicas: {{ .Values.autoscaling.minReplicas }}
|
||||
maxReplicas: {{ .Values.autoscaling.maxReplicas }}
|
||||
metrics:
|
||||
{{- if .Values.autoscaling.targetCPU }}
|
||||
- type: Resource
|
||||
resource:
|
||||
name: cpu
|
||||
target:
|
||||
type: Utilization
|
||||
averageUtilization: {{ .Values.autoscaling.targetCPU }}
|
||||
{{- end }}
|
||||
{{- if .Values.autoscaling.targetMemory }}
|
||||
- type: Resource
|
||||
resource:
|
||||
name: memory
|
||||
target:
|
||||
type: Utilization
|
||||
averageUtilization: {{ .Values.autoscaling.targetMemory }}
|
||||
{{- end }}
|
||||
{{- if or .Values.autoscaling.behavior.scaleDown.policies .Values.autoscaling.behavior.scaleUp.policies }}
|
||||
behavior:
|
||||
{{- if .Values.autoscaling.behavior.scaleDown.policies }}
|
||||
scaleDown:
|
||||
stabilizationWindowSeconds: {{ .Values.autoscaling.behavior.scaleDown.stabilizationWindowSeconds }}
|
||||
selectPolicy: {{ .Values.autoscaling.behavior.scaleDown.selectPolicy }}
|
||||
policies:
|
||||
{{- toYaml .Values.autoscaling.behavior.scaleDown.policies | nindent 8 }}
|
||||
{{- end }}
|
||||
{{- if .Values.autoscaling.behavior.scaleUp.policies }}
|
||||
scaleUp:
|
||||
stabilizationWindowSeconds: {{ .Values.autoscaling.behavior.scaleUp.stabilizationWindowSeconds }}
|
||||
selectPolicy: {{ .Values.autoscaling.behavior.scaleUp.selectPolicy }}
|
||||
policies:
|
||||
{{- toYaml .Values.autoscaling.behavior.scaleUp.policies | nindent 8 }}
|
||||
{{- end }}
|
||||
{{- end }}
|
||||
{{- end }}
|
||||
@@ -1,57 +0,0 @@
|
||||
{{- /*
|
||||
Copyright Broadcom, Inc. All Rights Reserved.
|
||||
SPDX-License-Identifier: APACHE-2.0
|
||||
*/}}
|
||||
|
||||
{{- if .Values.ingress.enabled }}
|
||||
apiVersion: {{ include "common.capabilities.ingress.apiVersion" . }}
|
||||
kind: Ingress
|
||||
metadata:
|
||||
name: {{ include "common.names.fullname" . }}
|
||||
namespace: {{ include "common.names.namespace" . | quote }}
|
||||
{{- $labels := include "common.tplvalues.merge" ( dict "values" ( list .Values.ingress.labels .Values.commonLabels ) "context" . ) }}
|
||||
labels: {{- include "common.labels.standard" ( dict "customLabels" $labels "context" $ ) | nindent 4 }}
|
||||
app.kubernetes.io/component: keycloak
|
||||
{{- if or .Values.ingress.annotations .Values.commonAnnotations }}
|
||||
{{- $annotations := include "common.tplvalues.merge" ( dict "values" ( list .Values.ingress.annotations .Values.commonAnnotations ) "context" . ) }}
|
||||
annotations: {{- include "common.tplvalues.render" ( dict "value" $annotations "context" $) | nindent 4 }}
|
||||
{{- end }}
|
||||
spec:
|
||||
{{- if .Values.ingress.ingressClassName }}
|
||||
ingressClassName: {{ include "common.tplvalues.render" ( dict "value" .Values.ingress.ingressClassName "context" $ ) | quote }}
|
||||
{{- end }}
|
||||
rules:
|
||||
{{- if .Values.ingress.hostname }}
|
||||
- host: {{ (tpl .Values.ingress.hostname .) | quote }}
|
||||
http:
|
||||
paths:
|
||||
{{- if .Values.ingress.extraPaths }}
|
||||
{{- toYaml .Values.ingress.extraPaths | nindent 10 }}
|
||||
{{- end }}
|
||||
- path: {{ include "common.tplvalues.render" ( dict "value" .Values.ingress.path "context" $) }}
|
||||
pathType: {{ .Values.ingress.pathType }}
|
||||
backend: {{- include "common.ingress.backend" (dict "serviceName" (include "common.names.fullname" .) "servicePort" .Values.ingress.servicePort "context" $) | nindent 14 }}
|
||||
{{- end }}
|
||||
{{- range .Values.ingress.extraHosts }}
|
||||
- host: {{ (tpl .name $) }}
|
||||
http:
|
||||
paths:
|
||||
- path: {{ default "/" .path }}
|
||||
pathType: {{ default "ImplementationSpecific" .pathType }}
|
||||
backend: {{- include "common.ingress.backend" (dict "serviceName" (include "common.names.fullname" $) "servicePort" $.Values.ingress.servicePort "context" $) | nindent 14 }}
|
||||
{{- end }}
|
||||
{{- if .Values.ingress.extraRules }}
|
||||
{{- include "common.tplvalues.render" (dict "value" .Values.ingress.extraRules "context" $) | nindent 4 }}
|
||||
{{- end }}
|
||||
{{- if or (and .Values.ingress.tls (or (include "common.ingress.certManagerRequest" ( dict "annotations" .Values.ingress.annotations )) .Values.ingress.selfSigned .Values.ingress.secrets )) .Values.ingress.extraTls }}
|
||||
tls:
|
||||
{{- if and .Values.ingress.tls (or (include "common.ingress.certManagerRequest" ( dict "annotations" .Values.ingress.annotations )) .Values.ingress.secrets .Values.ingress.selfSigned) }}
|
||||
- hosts:
|
||||
- {{ (tpl .Values.ingress.hostname .) | quote }}
|
||||
secretName: {{ printf "%s-tls" (tpl .Values.ingress.hostname .) }}
|
||||
{{- end }}
|
||||
{{- if .Values.ingress.extraTls }}
|
||||
{{- include "common.tplvalues.render" (dict "value" .Values.ingress.extraTls "context" $) | nindent 4 }}
|
||||
{{- end }}
|
||||
{{- end }}
|
||||
{{- end }}
|
||||
@@ -1,23 +0,0 @@
|
||||
{{- /*
|
||||
Copyright Broadcom, Inc. All Rights Reserved.
|
||||
SPDX-License-Identifier: APACHE-2.0
|
||||
*/}}
|
||||
|
||||
{{- if (include "keycloak.keycloakConfigCli.createConfigmap" .) }}
|
||||
apiVersion: v1
|
||||
kind: ConfigMap
|
||||
metadata:
|
||||
name: {{ include "keycloak.keycloakConfigCli.configmapName" . }}
|
||||
namespace: {{ include "common.names.namespace" . | quote }}
|
||||
labels: {{- include "common.labels.standard" ( dict "customLabels" .Values.commonLabels "context" $ ) | nindent 4 }}
|
||||
app.kubernetes.io/component: keycloak-config-cli
|
||||
data:
|
||||
{{- range $fileName, $fileContent := .Values.keycloakConfigCli.configuration }}
|
||||
{{- if $fileContent }}
|
||||
{{ $fileName }}: |
|
||||
{{- include "common.tplvalues.render" (dict "value" $fileContent "context" $) | nindent 4 }}
|
||||
{{- else }}
|
||||
{{- ($.Files.Glob $fileName).AsConfig | nindent 2 }}
|
||||
{{- end }}
|
||||
{{- end }}
|
||||
{{- end }}
|
||||
@@ -1,142 +0,0 @@
|
||||
{{- /*
|
||||
Copyright Broadcom, Inc. All Rights Reserved.
|
||||
SPDX-License-Identifier: APACHE-2.0
|
||||
*/}}
|
||||
|
||||
{{- if .Values.keycloakConfigCli.enabled }}
|
||||
apiVersion: batch/v1
|
||||
kind: Job
|
||||
metadata:
|
||||
name: {{ printf "%s-keycloak-config-cli" (include "common.names.fullname" .) | trunc 63 | trimSuffix "-" }}
|
||||
namespace: {{ include "common.names.namespace" . | quote }}
|
||||
labels: {{- include "common.labels.standard" ( dict "customLabels" .Values.commonLabels "context" $ ) | nindent 4 }}
|
||||
app.kubernetes.io/component: keycloak-config-cli
|
||||
{{- if or .Values.keycloakConfigCli.annotations .Values.commonAnnotations }}
|
||||
{{- $annotations := include "common.tplvalues.merge" ( dict "values" ( list .Values.keycloakConfigCli.annotations .Values.commonAnnotations ) "context" . ) }}
|
||||
annotations: {{- include "common.tplvalues.render" ( dict "value" $annotations "context" $) | nindent 4 }}
|
||||
{{- end }}
|
||||
spec:
|
||||
backoffLimit: {{ .Values.keycloakConfigCli.backoffLimit }}
|
||||
{{- if .Values.keycloakConfigCli.cleanupAfterFinished.enabled }}
|
||||
ttlSecondsAfterFinished: {{ .Values.keycloakConfigCli.cleanupAfterFinished.seconds }}
|
||||
{{- end }}
|
||||
template:
|
||||
metadata:
|
||||
{{- $podLabels := include "common.tplvalues.merge" ( dict "values" ( list .Values.keycloakConfigCli.podLabels .Values.commonLabels ) "context" . ) }}
|
||||
labels: {{- include "common.labels.standard" ( dict "customLabels" $podLabels "context" $ ) | nindent 8 }}
|
||||
app.kubernetes.io/component: keycloak-config-cli
|
||||
annotations:
|
||||
{{- if (include "keycloak.keycloakConfigCli.createConfigmap" .) }}
|
||||
checksum/configuration: {{ include (print $.Template.BasePath "/keycloak-config-cli-configmap.yaml") . | sha256sum }}
|
||||
{{- end }}
|
||||
{{- if .Values.keycloakConfigCli.podAnnotations }}
|
||||
{{- include "common.tplvalues.render" (dict "value" .Values.keycloakConfigCli.podAnnotations "context" $) | nindent 8 }}
|
||||
{{- end }}
|
||||
spec:
|
||||
serviceAccountName: {{ template "keycloak.serviceAccountName" . }}
|
||||
{{- include "keycloak.imagePullSecrets" . | nindent 6 }}
|
||||
restartPolicy: Never
|
||||
{{- if .Values.keycloakConfigCli.podSecurityContext.enabled }}
|
||||
securityContext: {{- include "common.compatibility.renderSecurityContext" (dict "secContext" .Values.keycloakConfigCli.podSecurityContext "context" $) | nindent 8 }}
|
||||
{{- end }}
|
||||
automountServiceAccountToken: {{ .Values.keycloakConfigCli.automountServiceAccountToken }}
|
||||
{{- if .Values.keycloakConfigCli.hostAliases }}
|
||||
hostAliases: {{- include "common.tplvalues.render" (dict "value" .Values.keycloakConfigCli.hostAliases "context" $) | nindent 8 }}
|
||||
{{- end }}
|
||||
{{- if .Values.keycloakConfigCli.nodeSelector }}
|
||||
nodeSelector: {{- include "common.tplvalues.render" (dict "value" .Values.keycloakConfigCli.nodeSelector "context" $) | nindent 8 }}
|
||||
{{- end }}
|
||||
{{- if .Values.keycloakConfigCli.podTolerations }}
|
||||
tolerations: {{- include "common.tplvalues.render" (dict "value" .Values.keycloakConfigCli.podTolerations "context" .) | nindent 8 }}
|
||||
{{- end }}
|
||||
{{- if .Values.keycloakConfigCli.initContainers }}
|
||||
initContainers:
|
||||
{{- include "common.tplvalues.render" (dict "value" .Values.keycloakConfigCli.initContainers "context" $) | nindent 8 }}
|
||||
{{- end }}
|
||||
containers:
|
||||
- name: keycloak-config-cli
|
||||
image: {{ template "keycloak.keycloakConfigCli.image" . }}
|
||||
imagePullPolicy: {{ .Values.keycloakConfigCli.image.pullPolicy }}
|
||||
{{- if .Values.keycloakConfigCli.command }}
|
||||
command: {{- include "common.tplvalues.render" (dict "value" .Values.keycloakConfigCli.command "context" $) | nindent 12 }}
|
||||
{{- else }}
|
||||
command:
|
||||
- java
|
||||
- -jar
|
||||
- /opt/bitnami/keycloak-config-cli/keycloak-config-cli.jar
|
||||
{{- end }}
|
||||
{{- if .Values.keycloakConfigCli.args }}
|
||||
args: {{- include "common.tplvalues.render" (dict "value" .Values.keycloakConfigCli.args "context" $) | nindent 12 }}
|
||||
{{- end }}
|
||||
{{- if .Values.keycloakConfigCli.containerSecurityContext.enabled }}
|
||||
securityContext: {{- include "common.compatibility.renderSecurityContext" (dict "secContext" .Values.keycloakConfigCli.containerSecurityContext "context" $) | nindent 12 }}
|
||||
{{- end }}
|
||||
env:
|
||||
- name: KEYCLOAK_URL
|
||||
value: {{ printf "http://%s-headless:%d%s" (include "common.names.fullname" .) (.Values.containerPorts.http | int) (.Values.httpRelativePath) }}
|
||||
- name: KEYCLOAK_USER
|
||||
value: {{ .Values.auth.adminUser | quote }}
|
||||
- name: KEYCLOAK_PASSWORD
|
||||
valueFrom:
|
||||
secretKeyRef:
|
||||
name: {{ include "keycloak.secretName" . }}
|
||||
key: {{ include "keycloak.secretKey" . }}
|
||||
{{- if or .Values.keycloakConfigCli.configuration .Values.keycloakConfigCli.existingConfigmap }}
|
||||
- name: IMPORT_FILES_LOCATIONS
|
||||
value: /config/*
|
||||
{{- end }}
|
||||
- name: KEYCLOAK_AVAILABILITYCHECK_ENABLED
|
||||
value: {{ .Values.keycloakConfigCli.availabilityCheck.enabled | quote }}
|
||||
{{- if and .Values.keycloakConfigCli.availabilityCheck.enabled .Values.keycloakConfigCli.availabilityCheck.timeout }}
|
||||
- name: KEYCLOAK_AVAILABILITYCHECK_TIMEOUT
|
||||
value: {{ .Values.keycloakConfigCli.availabilityCheck.timeout }}
|
||||
{{- end }}
|
||||
{{- if .Values.keycloakConfigCli.extraEnvVars }}
|
||||
{{- include "common.tplvalues.render" (dict "value" .Values.keycloakConfigCli.extraEnvVars "context" $) | nindent 12 }}
|
||||
{{- end }}
|
||||
{{- if or .Values.keycloakConfigCli.extraEnvVarsCM .Values.keycloakConfigCli.extraEnvVarsSecret }}
|
||||
envFrom:
|
||||
{{- if .Values.keycloakConfigCli.extraEnvVarsCM }}
|
||||
- configMapRef:
|
||||
name: {{ include "common.tplvalues.render" (dict "value" .Values.keycloakConfigCli.extraEnvVarsCM "context" $) }}
|
||||
{{- end }}
|
||||
{{- if .Values.keycloakConfigCli.extraEnvVarsSecret }}
|
||||
- secretRef:
|
||||
name: {{ include "common.tplvalues.render" (dict "value" .Values.keycloakConfigCli.extraEnvVarsSecret "context" $) }}
|
||||
{{- end }}
|
||||
{{- end }}
|
||||
{{- if or .Values.keycloakConfigCli.configuration .Values.keycloakConfigCli.existingConfigmap .Values.keycloakConfigCli.extraVolumeMounts }}
|
||||
volumeMounts:
|
||||
- name: empty-dir
|
||||
mountPath: /tmp
|
||||
subPath: tmp-dir
|
||||
{{- if or .Values.keycloakConfigCli.configuration .Values.keycloakConfigCli.existingConfigmap }}
|
||||
- name: config-volume
|
||||
mountPath: /config
|
||||
{{- end }}
|
||||
{{- if .Values.keycloakConfigCli.extraVolumeMounts }}
|
||||
{{- include "common.tplvalues.render" (dict "value" .Values.keycloakConfigCli.extraVolumeMounts "context" $) | nindent 12 }}
|
||||
{{- end }}
|
||||
{{- end }}
|
||||
{{- if .Values.keycloakConfigCli.resources }}
|
||||
resources: {{- toYaml .Values.keycloakConfigCli.resources | nindent 12 }}
|
||||
{{- else if ne .Values.keycloakConfigCli.resourcesPreset "none" }}
|
||||
resources: {{- include "common.resources.preset" (dict "type" .Values.keycloakConfigCli.resourcesPreset) | nindent 12 }}
|
||||
{{- end }}
|
||||
{{- if .Values.keycloakConfigCli.sidecars }}
|
||||
{{- include "common.tplvalues.render" ( dict "value" .Values.keycloakConfigCli.sidecars "context" $) | nindent 8 }}
|
||||
{{- end }}
|
||||
{{- if or .Values.keycloakConfigCli.configuration .Values.keycloakConfigCli.existingConfigmap .Values.keycloakConfigCli.extraVolumes }}
|
||||
volumes:
|
||||
- name: empty-dir
|
||||
emptyDir: {}
|
||||
{{- if or .Values.keycloakConfigCli.configuration .Values.keycloakConfigCli.existingConfigmap }}
|
||||
- name: config-volume
|
||||
configMap:
|
||||
name: {{ include "keycloak.keycloakConfigCli.configmapName" . }}
|
||||
{{- end }}
|
||||
{{- if .Values.keycloakConfigCli.extraVolumes }}
|
||||
{{- include "common.tplvalues.render" (dict "value" .Values.keycloakConfigCli.extraVolumes "context" $) | nindent 8 }}
|
||||
{{- end }}
|
||||
{{- end }}
|
||||
{{- end }}
|
||||
@@ -1,41 +0,0 @@
|
||||
{{- /*
|
||||
Copyright Broadcom, Inc. All Rights Reserved.
|
||||
SPDX-License-Identifier: APACHE-2.0
|
||||
*/}}
|
||||
|
||||
{{- if .Values.metrics.enabled }}
|
||||
apiVersion: v1
|
||||
kind: Service
|
||||
metadata:
|
||||
name: {{ printf "%s-metrics" (include "common.names.fullname" .) }}
|
||||
namespace: {{ include "common.names.namespace" . | quote }}
|
||||
labels: {{- include "common.labels.standard" ( dict "customLabels" .Values.commonLabels "context" $ ) | nindent 4 }}
|
||||
app.kubernetes.io/component: metrics
|
||||
{{- if or .Values.metrics.service.annotations .Values.commonAnnotations }}
|
||||
{{- $annotations := include "common.tplvalues.merge" ( dict "values" ( list .Values.metrics.service.annotations .Values.commonAnnotations ) "context" . ) }}
|
||||
annotations: {{- include "common.tplvalues.render" ( dict "value" $annotations "context" $) | nindent 4 }}
|
||||
{{- end }}
|
||||
spec:
|
||||
type: ClusterIP
|
||||
ports:
|
||||
- name: metrics
|
||||
port: {{ .Values.metrics.service.ports.metrics }}
|
||||
protocol: TCP
|
||||
targetPort: {{ .Values.containerPorts.metrics }}
|
||||
- name: http
|
||||
port: {{ .Values.metrics.service.ports.http }}
|
||||
protocol: TCP
|
||||
targetPort: {{ .Values.containerPorts.http }}
|
||||
{{- if .Values.tls.enabled }}
|
||||
- name: https
|
||||
port: {{ .Values.metrics.service.ports.https }}
|
||||
protocol: TCP
|
||||
targetPort: {{ .Values.containerPorts.https }}
|
||||
{{- end }}
|
||||
{{- if .Values.metrics.service.extraPorts }}
|
||||
{{- include "common.tplvalues.render" (dict "value" .Values.metrics.service.extraPorts "context" $) | nindent 4 }}
|
||||
{{- end }}
|
||||
{{- $podLabels := include "common.tplvalues.merge" ( dict "values" ( list .Values.podLabels .Values.commonLabels ) "context" . ) }}
|
||||
selector: {{- include "common.labels.matchLabels" ( dict "customLabels" $podLabels "context" $ ) | nindent 4 }}
|
||||
app.kubernetes.io/component: keycloak
|
||||
{{- end }}
|
||||
@@ -1,19 +0,0 @@
|
||||
{{- /*
|
||||
Copyright Broadcom, Inc. All Rights Reserved.
|
||||
SPDX-License-Identifier: APACHE-2.0
|
||||
*/}}
|
||||
|
||||
{{- if and (not .Values.postgresql.enabled) (not .Values.externalDatabase.existingSecret) (not .Values.postgresql.existingSecret) }}
|
||||
apiVersion: v1
|
||||
kind: Secret
|
||||
metadata:
|
||||
name: {{ printf "%s-externaldb" (include "common.names.fullname" .) }}
|
||||
namespace: {{ include "common.names.namespace" . | quote }}
|
||||
labels: {{- include "common.labels.standard" (dict "customLabels" .Values.commonLabels "context" $) | nindent 4 }}
|
||||
{{- if or .Values.externalDatabase.annotations .Values.commonAnnotations }}
|
||||
annotations: {{- include "common.tplvalues.merge" (dict "values" (list .Values.externalDatabase.annotations .Values.commonAnnotations) "context" $) | nindent 4 }}
|
||||
{{- end }}
|
||||
type: Opaque
|
||||
data:
|
||||
db-password: {{ include "common.secrets.passwords.manage" (dict "secret" (printf "%s-externaldb" (include "common.names.fullname" .)) "key" "db-password" "length" 10 "providedValues" (list "externalDatabase.password") "context" $) }}
|
||||
{{- end }}
|
||||
@@ -1,20 +0,0 @@
|
||||
{{- /*
|
||||
Copyright Broadcom, Inc. All Rights Reserved.
|
||||
SPDX-License-Identifier: APACHE-2.0
|
||||
*/}}
|
||||
|
||||
{{- if not .Values.auth.existingSecret }}
|
||||
apiVersion: v1
|
||||
kind: Secret
|
||||
metadata:
|
||||
name: {{ printf "%s" (include "common.names.fullname" .) | trunc 63 | trimSuffix "-" }}
|
||||
namespace: {{ include "common.names.namespace" . | quote }}
|
||||
labels: {{- include "common.labels.standard" (dict "customLabels" .Values.commonLabels "context" $) | nindent 4 }}
|
||||
app.kubernetes.io/component: keycloak
|
||||
{{- if or .Values.auth.annotations .Values.commonAnnotations }}
|
||||
annotations: {{- include "common.tplvalues.merge" (dict "values" (list .Values.auth.annotations .Values.commonAnnotations) "context" $) | nindent 4 }}
|
||||
{{- end }}
|
||||
type: Opaque
|
||||
data:
|
||||
admin-password: {{ include "common.secrets.passwords.manage" (dict "secret" (printf "%s" (include "common.names.fullname" .) | trunc 63 | trimSuffix "-") "key" "admin-password" "length" 10 "providedValues" (list "auth.adminPassword") "context" $) }}
|
||||
{{- end }}
|
||||
@@ -1,65 +0,0 @@
|
||||
{{- /*
|
||||
Copyright Broadcom, Inc. All Rights Reserved.
|
||||
SPDX-License-Identifier: APACHE-2.0
|
||||
*/}}
|
||||
|
||||
apiVersion: v1
|
||||
kind: Service
|
||||
metadata:
|
||||
name: {{ template "common.names.fullname" . }}
|
||||
namespace: {{ include "common.names.namespace" . | quote }}
|
||||
labels: {{- include "common.labels.standard" ( dict "customLabels" .Values.commonLabels "context" $ ) | nindent 4 }}
|
||||
app.kubernetes.io/component: keycloak
|
||||
{{- if or .Values.service.annotations .Values.commonAnnotations }}
|
||||
{{- $annotations := include "common.tplvalues.merge" ( dict "values" ( list .Values.service.annotations .Values.commonAnnotations ) "context" . ) }}
|
||||
annotations: {{- include "common.tplvalues.render" ( dict "value" $annotations "context" $) | nindent 4 }}
|
||||
{{- end }}
|
||||
spec:
|
||||
type: {{ .Values.service.type }}
|
||||
{{- if and .Values.service.clusterIP (eq .Values.service.type "ClusterIP") }}
|
||||
clusterIP: {{ .Values.service.clusterIP }}
|
||||
{{- end }}
|
||||
{{- if or (eq .Values.service.type "LoadBalancer") (eq .Values.service.type "NodePort") }}
|
||||
externalTrafficPolicy: {{ .Values.service.externalTrafficPolicy | quote }}
|
||||
{{- end }}
|
||||
{{- if and (eq .Values.service.type "LoadBalancer") (not (empty .Values.service.loadBalancerSourceRanges)) }}
|
||||
loadBalancerSourceRanges: {{ .Values.service.loadBalancerSourceRanges }}
|
||||
{{- end }}
|
||||
{{- if and (eq .Values.service.type "LoadBalancer") (not (empty .Values.service.loadBalancerIP)) }}
|
||||
loadBalancerIP: {{ .Values.service.loadBalancerIP }}
|
||||
{{- end }}
|
||||
{{- if .Values.service.sessionAffinity }}
|
||||
sessionAffinity: {{ .Values.service.sessionAffinity }}
|
||||
{{- end }}
|
||||
{{- if .Values.service.sessionAffinityConfig }}
|
||||
sessionAffinityConfig: {{- include "common.tplvalues.render" (dict "value" .Values.service.sessionAffinityConfig "context" $) | nindent 4 }}
|
||||
{{- end }}
|
||||
ports:
|
||||
{{- if .Values.service.http.enabled }}
|
||||
- name: http
|
||||
port: {{ coalesce .Values.service.ports.http .Values.service.port }}
|
||||
protocol: TCP
|
||||
targetPort: http
|
||||
{{- if (and (or (eq .Values.service.type "NodePort") (eq .Values.service.type "LoadBalancer")) (not (empty .Values.service.nodePorts.http))) }}
|
||||
nodePort: {{ .Values.service.nodePorts.http }}
|
||||
{{- else if eq .Values.service.type "ClusterIP" }}
|
||||
nodePort: null
|
||||
{{- end }}
|
||||
{{- end }}
|
||||
{{- if .Values.tls.enabled }}
|
||||
- name: https
|
||||
port: {{ coalesce .Values.service.ports.https .Values.service.httpsPort }}
|
||||
protocol: TCP
|
||||
targetPort: https
|
||||
{{- if (and (or (eq .Values.service.type "NodePort") (eq .Values.service.type "LoadBalancer")) (not (empty .Values.service.nodePorts.https))) }}
|
||||
nodePort: {{ .Values.service.nodePorts.https }}
|
||||
{{- else if eq .Values.service.type "ClusterIP" }}
|
||||
nodePort: null
|
||||
{{- end }}
|
||||
{{- end }}
|
||||
{{- if .Values.service.extraPorts }}
|
||||
{{- include "common.tplvalues.render" (dict "value" .Values.service.extraPorts "context" $) | nindent 4 }}
|
||||
{{- end }}
|
||||
{{- $podLabels := include "common.tplvalues.merge" ( dict "values" ( list .Values.podLabels .Values.commonLabels ) "context" . ) }}
|
||||
selector: {{- include "common.labels.matchLabels" ( dict "customLabels" $podLabels "context" $ ) | nindent 4 }}
|
||||
app.kubernetes.io/component: keycloak
|
||||
@@ -1,58 +0,0 @@
|
||||
{{- /*
|
||||
Copyright Broadcom, Inc. All Rights Reserved.
|
||||
SPDX-License-Identifier: APACHE-2.0
|
||||
*/}}
|
||||
|
||||
{{- if and .Values.metrics.enabled .Values.metrics.serviceMonitor.enabled }}
|
||||
apiVersion: monitoring.coreos.com/v1
|
||||
kind: ServiceMonitor
|
||||
metadata:
|
||||
name: {{ template "common.names.fullname" . }}
|
||||
namespace: {{ default (include "common.names.namespace" .) .Values.metrics.serviceMonitor.namespace }}
|
||||
{{- $labels := include "common.tplvalues.merge" ( dict "values" ( list .Values.metrics.serviceMonitor.labels .Values.commonLabels ) "context" . ) }}
|
||||
labels: {{- include "common.labels.standard" ( dict "customLabels" $labels "context" $ ) | nindent 4 }}
|
||||
app.kubernetes.io/component: keycloak
|
||||
{{- if .Values.commonAnnotations }}
|
||||
annotations: {{- include "common.tplvalues.render" ( dict "value" .Values.commonAnnotations "context" $ ) | nindent 4 }}
|
||||
{{- end }}
|
||||
spec:
|
||||
{{- if .Values.metrics.serviceMonitor.jobLabel }}
|
||||
jobLabel: {{ .Values.metrics.serviceMonitor.jobLabel }}
|
||||
{{- end }}
|
||||
endpoints:
|
||||
{{- $defaultEndpoint := pick .Values.metrics.serviceMonitor "port" "scheme" "tlsConfig" "interval" "scrapeTimeout" "relabelings" "metricRelabelings" "honorLabels" }}
|
||||
{{- $endpoints := ternary (.Values.metrics.serviceMonitor.endpoints) (list (dict "path" .Values.metrics.serviceMonitor.path)) (empty .Values.metrics.serviceMonitor.path) }}
|
||||
{{- range $endpoints }}
|
||||
{{- $endpoint := merge . $defaultEndpoint }}
|
||||
- port: {{ $endpoint.port | quote }}
|
||||
scheme: {{ $endpoint.scheme | quote }}
|
||||
{{- if $endpoint.tlsConfig }}
|
||||
tlsConfig: {{- include "common.tplvalues.render" ( dict "value" $endpoint.tlsConfig "context" $) | nindent 8 }}
|
||||
{{- end }}
|
||||
path: {{ include "common.tplvalues.render" ( dict "value" $endpoint.path "context" $) }}
|
||||
{{- if $endpoint.interval }}
|
||||
interval: {{ $endpoint.interval }}
|
||||
{{- end }}
|
||||
{{- if $endpoint.scrapeTimeout }}
|
||||
scrapeTimeout: {{ $endpoint.scrapeTimeout }}
|
||||
{{- end }}
|
||||
{{- if $endpoint.relabelings }}
|
||||
relabelings: {{- include "common.tplvalues.render" ( dict "value" $endpoint.relabelings "context" $) | nindent 6 }}
|
||||
{{- end }}
|
||||
{{- if $endpoint.metricRelabelings }}
|
||||
metricRelabelings: {{- include "common.tplvalues.render" ( dict "value" $endpoint.metricRelabelings "context" $) | nindent 6 }}
|
||||
{{- end }}
|
||||
{{- if $endpoint.honorLabels }}
|
||||
honorLabels: {{ $endpoint.honorLabels }}
|
||||
{{- end }}
|
||||
{{- end }}
|
||||
namespaceSelector:
|
||||
matchNames:
|
||||
- {{ include "common.names.namespace" . | quote }}
|
||||
selector:
|
||||
matchLabels: {{- include "common.labels.matchLabels" ( dict "customLabels" .Values.commonLabels "context" $ ) | nindent 6 }}
|
||||
{{- if .Values.metrics.serviceMonitor.selector }}
|
||||
{{- include "common.tplvalues.render" (dict "value" .Values.metrics.serviceMonitor.selector "context" $) | nindent 6 }}
|
||||
{{- end }}
|
||||
app.kubernetes.io/component: metrics
|
||||
{{- end }}
|
||||
@@ -1,449 +0,0 @@
|
||||
{{- /*
|
||||
Copyright Broadcom, Inc. All Rights Reserved.
|
||||
SPDX-License-Identifier: APACHE-2.0
|
||||
*/}}
|
||||
|
||||
apiVersion: {{ include "common.capabilities.statefulset.apiVersion" . }}
|
||||
kind: StatefulSet
|
||||
metadata:
|
||||
name: {{ template "common.names.fullname" . }}
|
||||
namespace: {{ include "common.names.namespace" . | quote }}
|
||||
labels: {{- include "common.labels.standard" ( dict "customLabels" .Values.commonLabels "context" $ ) | nindent 4 }}
|
||||
app.kubernetes.io/component: keycloak
|
||||
{{- if or .Values.statefulsetAnnotations .Values.commonAnnotations }}
|
||||
annotations: {{- include "common.tplvalues.merge" ( dict "values" ( list .Values.statefulsetAnnotations .Values.commonAnnotations ) "context" $ ) | nindent 4 }}
|
||||
{{- end }}
|
||||
spec:
|
||||
{{- if not .Values.autoscaling.enabled }}
|
||||
replicas: {{ .Values.replicaCount }}
|
||||
{{- end }}
|
||||
revisionHistoryLimit: {{ .Values.revisionHistoryLimitCount }}
|
||||
podManagementPolicy: {{ .Values.podManagementPolicy }}
|
||||
serviceName: {{ printf "%s-headless" (include "common.names.fullname" .) | trunc 63 | trimSuffix "-" }}
|
||||
updateStrategy:
|
||||
{{- include "common.tplvalues.render" (dict "value" .Values.updateStrategy "context" $ ) | nindent 4 }}
|
||||
{{- if .Values.minReadySeconds }}
|
||||
minReadySeconds: {{ .Values.minReadySeconds }}
|
||||
{{- end }}
|
||||
{{- $podLabels := include "common.tplvalues.merge" ( dict "values" ( list .Values.podLabels .Values.commonLabels ) "context" . ) }}
|
||||
selector:
|
||||
matchLabels: {{- include "common.labels.matchLabels" ( dict "customLabels" $podLabels "context" $ ) | nindent 6 }}
|
||||
app.kubernetes.io/component: keycloak
|
||||
template:
|
||||
metadata:
|
||||
annotations:
|
||||
checksum/configmap-env-vars: {{ include (print $.Template.BasePath "/configmap-env-vars.yaml") . | sha256sum }}
|
||||
{{- if not .Values.auth.existingSecret }}
|
||||
checksum/secrets: {{ include (print $.Template.BasePath "/secrets.yaml") . | sha256sum }}
|
||||
{{- end }}
|
||||
{{- if (include "keycloak.createConfigmap" .) }}
|
||||
checksum/configuration: {{ include (print $.Template.BasePath "/configmap.yaml") . | sha256sum }}
|
||||
{{- end }}
|
||||
{{- if .Values.podAnnotations }}
|
||||
{{- include "common.tplvalues.render" (dict "value" .Values.podAnnotations "context" $) | nindent 8 }}
|
||||
{{- end }}
|
||||
labels: {{- include "common.labels.standard" ( dict "customLabels" $podLabels "context" $ ) | nindent 8 }}
|
||||
app.kubernetes.io/component: keycloak
|
||||
app.kubernetes.io/app-version: {{ .Chart.AppVersion }}
|
||||
spec:
|
||||
serviceAccountName: {{ template "keycloak.serviceAccountName" . }}
|
||||
{{- include "keycloak.imagePullSecrets" . | nindent 6 }}
|
||||
automountServiceAccountToken: {{ .Values.automountServiceAccountToken }}
|
||||
{{- if .Values.hostAliases }}
|
||||
hostAliases: {{- include "common.tplvalues.render" (dict "value" .Values.hostAliases "context" $) | nindent 8 }}
|
||||
{{- end }}
|
||||
{{- if .Values.affinity }}
|
||||
affinity: {{- include "common.tplvalues.render" ( dict "value" .Values.affinity "context" $) | nindent 8 }}
|
||||
{{- else }}
|
||||
affinity:
|
||||
podAffinity: {{- include "common.affinities.pods" (dict "type" .Values.podAffinityPreset "customLabels" $podLabels "context" $) | nindent 10 }}
|
||||
podAntiAffinity: {{- include "common.affinities.pods" (dict "type" .Values.podAntiAffinityPreset "customLabels" $podLabels "context" $) | nindent 10 }}
|
||||
nodeAffinity: {{- include "common.affinities.nodes" (dict "type" .Values.nodeAffinityPreset.type "key" .Values.nodeAffinityPreset.key "values" .Values.nodeAffinityPreset.values) | nindent 10 }}
|
||||
{{- end }}
|
||||
{{- if .Values.nodeSelector }}
|
||||
nodeSelector: {{- include "common.tplvalues.render" ( dict "value" .Values.nodeSelector "context" $) | nindent 8 }}
|
||||
{{- end }}
|
||||
{{- if .Values.tolerations }}
|
||||
tolerations: {{- include "common.tplvalues.render" (dict "value" .Values.tolerations "context" .) | nindent 8 }}
|
||||
{{- end }}
|
||||
{{- if .Values.topologySpreadConstraints }}
|
||||
topologySpreadConstraints: {{- include "common.tplvalues.render" (dict "value" .Values.topologySpreadConstraints "context" .) | nindent 8 }}
|
||||
{{- end }}
|
||||
{{- if .Values.priorityClassName }}
|
||||
priorityClassName: {{ .Values.priorityClassName | quote }}
|
||||
{{- end }}
|
||||
{{- if .Values.schedulerName }}
|
||||
schedulerName: {{ .Values.schedulerName }}
|
||||
{{- end }}
|
||||
{{- if .Values.podSecurityContext.enabled }}
|
||||
securityContext: {{- include "common.compatibility.renderSecurityContext" (dict "secContext" .Values.podSecurityContext "context" $) | nindent 8 }}
|
||||
{{- end }}
|
||||
{{- if .Values.dnsPolicy }}
|
||||
dnsPolicy: {{ .Values.dnsPolicy }}
|
||||
{{- end }}
|
||||
{{- if .Values.dnsConfig }}
|
||||
dnsConfig: {{- include "common.tplvalues.render" (dict "value" .Values.dnsConfig "context" .) | nindent 8 }}
|
||||
{{- end }}
|
||||
enableServiceLinks: {{ .Values.enableServiceLinks }}
|
||||
{{- if .Values.terminationGracePeriodSeconds }}
|
||||
terminationGracePeriodSeconds: {{ .Values.terminationGracePeriodSeconds }}
|
||||
{{- end }}
|
||||
{{- if or .Values.enableDefaultInitContainers .Values.initContainers }}
|
||||
initContainers:
|
||||
{{- if .Values.enableDefaultInitContainers }}
|
||||
- name: prepare-write-dirs
|
||||
image: {{ template "keycloak.image" . }}
|
||||
imagePullPolicy: {{ .Values.image.pullPolicy }}
|
||||
command:
|
||||
- /bin/bash
|
||||
args:
|
||||
- -ec
|
||||
- |
|
||||
. /opt/bitnami/scripts/liblog.sh
|
||||
|
||||
info "Copying writable dirs to empty dir"
|
||||
# In order to not break the application functionality we need to make some
|
||||
# directories writable, so we need to copy it to an empty dir volume
|
||||
cp -r --preserve=mode,timestamps /opt/bitnami/keycloak/lib/quarkus /emptydir/app-quarkus-dir
|
||||
cp -r --preserve=mode,timestamps /opt/bitnami/keycloak/data /emptydir/app-data-dir
|
||||
cp -r --preserve=mode,timestamps /opt/bitnami/keycloak/providers /emptydir/app-providers-dir
|
||||
cp -r --preserve=mode,timestamps /opt/bitnami/keycloak/themes /emptydir/app-themes-dir
|
||||
info "Copy operation completed"
|
||||
{{- if .Values.containerSecurityContext.enabled }}
|
||||
securityContext: {{- include "common.compatibility.renderSecurityContext" (dict "secContext" .Values.containerSecurityContext "context" $) | nindent 12 }}
|
||||
{{- end }}
|
||||
{{- if .Values.resources }}
|
||||
resources: {{- toYaml .Values.resources | nindent 12 }}
|
||||
{{- else if ne .Values.resourcesPreset "none" }}
|
||||
resources: {{- include "common.resources.preset" (dict "type" .Values.resourcesPreset) | nindent 12 }}
|
||||
{{- end }}
|
||||
volumeMounts:
|
||||
- name: empty-dir
|
||||
mountPath: /emptydir
|
||||
{{- end }}
|
||||
{{- if .Values.initContainers }}
|
||||
{{- include "common.tplvalues.render" (dict "value" .Values.initContainers "context" $) | nindent 8 }}
|
||||
{{- end }}
|
||||
{{- end }}
|
||||
containers:
|
||||
- name: keycloak
|
||||
image: {{ template "keycloak.image" . }}
|
||||
imagePullPolicy: {{ .Values.image.pullPolicy }}
|
||||
{{- if .Values.lifecycleHooks }}
|
||||
lifecycle: {{- include "common.tplvalues.render" (dict "value" .Values.lifecycleHooks "context" $) | nindent 12 }}
|
||||
{{- end }}
|
||||
{{- if .Values.containerSecurityContext.enabled }}
|
||||
securityContext: {{- include "common.compatibility.renderSecurityContext" (dict "secContext" .Values.containerSecurityContext "context" $) | nindent 12 }}
|
||||
{{- end }}
|
||||
{{- if .Values.diagnosticMode.enabled }}
|
||||
command: {{- include "common.tplvalues.render" (dict "value" .Values.diagnosticMode.command "context" $) | nindent 12 }}
|
||||
{{- else if .Values.command }}
|
||||
command: {{- include "common.tplvalues.render" (dict "value" .Values.command "context" $) | nindent 12 }}
|
||||
{{- end }}
|
||||
{{- if .Values.diagnosticMode.enabled }}
|
||||
args: {{- include "common.tplvalues.render" (dict "value" .Values.diagnosticMode.args "context" $) | nindent 12 }}
|
||||
{{- else if .Values.args }}
|
||||
args: {{- include "common.tplvalues.render" (dict "value" .Values.args "context" $) | nindent 12 }}
|
||||
{{- end }}
|
||||
env:
|
||||
- name: KUBERNETES_NAMESPACE
|
||||
valueFrom:
|
||||
fieldRef:
|
||||
apiVersion: v1
|
||||
fieldPath: metadata.namespace
|
||||
- name: BITNAMI_DEBUG
|
||||
value: {{ ternary "true" "false" .Values.image.debug | quote }}
|
||||
{{- if .Values.usePasswordFiles }}
|
||||
- name: KC_BOOTSTRAP_ADMIN_PASSWORD_FILE
|
||||
value: {{ printf "/opt/bitnami/keycloak/secrets/%s" (include "keycloak.secretKey" .) }}
|
||||
- name: KEYCLOAK_DATABASE_PASSWORD_FILE
|
||||
value: {{ printf "/opt/bitnami/keycloak/secrets/db-%s" (include "keycloak.databaseSecretPasswordKey" .) }}
|
||||
{{- if .Values.externalDatabase.existingSecretHostKey }}
|
||||
- name: KEYCLOAK_DATABASE_HOST_FILE
|
||||
value: {{ printf "/opt/bitnami/keycloak/secrets/db-%s" (include "keycloak.databaseSecretHostKey" .) }}
|
||||
{{- end }}
|
||||
{{- if .Values.externalDatabase.existingSecretPortKey }}
|
||||
- name: KEYCLOAK_DATABASE_PORT_FILE
|
||||
value: {{ printf "/opt/bitnami/keycloak/secrets/db-%s" (include "keycloak.databaseSecretPortKey" .) }}
|
||||
{{- end }}
|
||||
{{- if .Values.externalDatabase.existingSecretUserKey }}
|
||||
- name: KEYCLOAK_DATABASE_USER_FILE
|
||||
value: {{ printf "/opt/bitnami/keycloak/secrets/db-%s" (include "keycloak.databaseSecretUserKey" .) }}
|
||||
{{- end }}
|
||||
{{- if .Values.externalDatabase.existingSecretDatabaseKey }}
|
||||
- name: KEYCLOAK_DATABASE_NAME_FILE
|
||||
value: {{ printf "/opt/bitnami/keycloak/secrets/db-%s" (include "keycloak.databaseSecretDatabaseKey" .) }}
|
||||
{{- end }}
|
||||
{{- if and .Values.tls.enabled (or .Values.tls.keystorePassword .Values.tls.passwordsSecret) }}
|
||||
- name: KEYCLOAK_HTTPS_KEY_STORE_PASSWORD_FILE
|
||||
value: "/opt/bitnami/keycloak/secrets/tls-keystore-password"
|
||||
{{- end }}
|
||||
{{- if and .Values.tls.enabled (or .Values.tls.truststorePassword .Values.tls.passwordsSecret) }}
|
||||
- name: KEYCLOAK_HTTPS_TRUST_STORE_PASSWORD_FILE
|
||||
value: "/opt/bitnami/keycloak/secrets/tls-truststore-password"
|
||||
{{- end }}
|
||||
{{- if and .Values.spi.existingSecret (or .Values.spi.truststorePassword .Values.spi.passwordsSecret) }}
|
||||
- name: KEYCLOAK_SPI_TRUSTSTORE_PASSWORD_FILE
|
||||
value: "/opt/bitnami/keycloak/secrets/spi-truststore-password"
|
||||
{{- end }}
|
||||
{{- else }}
|
||||
- name: KC_BOOTSTRAP_ADMIN_PASSWORD
|
||||
valueFrom:
|
||||
secretKeyRef:
|
||||
name: {{ include "keycloak.secretName" . }}
|
||||
key: {{ include "keycloak.secretKey" . }}
|
||||
- name: KEYCLOAK_DATABASE_PASSWORD
|
||||
valueFrom:
|
||||
secretKeyRef:
|
||||
name: {{ include "keycloak.databaseSecretName" . }}
|
||||
key: {{ include "keycloak.databaseSecretPasswordKey" . }}
|
||||
{{- if .Values.externalDatabase.existingSecretHostKey }}
|
||||
- name: KEYCLOAK_DATABASE_HOST
|
||||
valueFrom:
|
||||
secretKeyRef:
|
||||
name: {{ include "keycloak.databaseSecretName" . }}
|
||||
key: {{ include "keycloak.databaseSecretHostKey" . }}
|
||||
{{- end }}
|
||||
{{- if .Values.externalDatabase.existingSecretPortKey }}
|
||||
- name: KEYCLOAK_DATABASE_PORT
|
||||
valueFrom:
|
||||
secretKeyRef:
|
||||
name: {{ include "keycloak.databaseSecretName" . }}
|
||||
key: {{ include "keycloak.databaseSecretPortKey" . }}
|
||||
{{- end }}
|
||||
{{- if .Values.externalDatabase.existingSecretUserKey }}
|
||||
- name: KEYCLOAK_DATABASE_USER
|
||||
valueFrom:
|
||||
secretKeyRef:
|
||||
name: {{ include "keycloak.databaseSecretName" . }}
|
||||
key: {{ include "keycloak.databaseSecretUserKey" . }}
|
||||
{{- end }}
|
||||
{{- if .Values.externalDatabase.existingSecretDatabaseKey }}
|
||||
- name: KEYCLOAK_DATABASE_NAME
|
||||
valueFrom:
|
||||
secretKeyRef:
|
||||
name: {{ include "keycloak.databaseSecretName" . }}
|
||||
key: {{ include "keycloak.databaseSecretDatabaseKey" . }}
|
||||
{{- end }}
|
||||
{{- if and .Values.tls.enabled (or .Values.tls.keystorePassword .Values.tls.passwordsSecret) }}
|
||||
- name: KEYCLOAK_HTTPS_KEY_STORE_PASSWORD
|
||||
valueFrom:
|
||||
secretKeyRef:
|
||||
name: {{ include "keycloak.tlsPasswordsSecretName" . }}
|
||||
key: "tls-keystore-password"
|
||||
{{- end }}
|
||||
{{- if and .Values.tls.enabled (or .Values.tls.truststorePassword .Values.tls.passwordsSecret) }}
|
||||
- name: KEYCLOAK_HTTPS_TRUST_STORE_PASSWORD
|
||||
valueFrom:
|
||||
secretKeyRef:
|
||||
name: {{ include "keycloak.tlsPasswordsSecretName" . }}
|
||||
key: "tls-truststore-password"
|
||||
{{- end }}
|
||||
{{- if and .Values.spi.existingSecret (or .Values.spi.truststorePassword .Values.spi.passwordsSecret) }}
|
||||
- name: KEYCLOAK_SPI_TRUSTSTORE_PASSWORD
|
||||
valueFrom:
|
||||
secretKeyRef:
|
||||
name: {{ include "keycloak.spiPasswordsSecretName" . }}
|
||||
key: "spi-truststore-password"
|
||||
{{- end }}
|
||||
{{- end }}
|
||||
- name: KEYCLOAK_HTTP_RELATIVE_PATH
|
||||
value: {{ .Values.httpRelativePath | quote }}
|
||||
{{- if .Values.extraStartupArgs }}
|
||||
- name: KEYCLOAK_EXTRA_ARGS
|
||||
value: {{ .Values.extraStartupArgs | quote }}
|
||||
{{- end }}
|
||||
{{- if .Values.adminRealm }}
|
||||
- name: KC_SPI_ADMIN_REALM
|
||||
value: "{{ .Values.adminRealm }}"
|
||||
{{- end }}
|
||||
{{- if .Values.extraEnvVars }}
|
||||
{{- include "common.tplvalues.render" (dict "value" .Values.extraEnvVars "context" $) | nindent 12 }}
|
||||
{{- end }}
|
||||
envFrom:
|
||||
- configMapRef:
|
||||
name: {{ printf "%s-env-vars" (include "common.names.fullname" .) }}
|
||||
{{- if .Values.extraEnvVarsCM }}
|
||||
- configMapRef:
|
||||
name: {{ include "common.tplvalues.render" (dict "value" .Values.extraEnvVarsCM "context" $) }}
|
||||
{{- end }}
|
||||
{{- if .Values.extraEnvVarsSecret }}
|
||||
- secretRef:
|
||||
name: {{ include "common.tplvalues.render" (dict "value" .Values.extraEnvVarsSecret "context" $) }}
|
||||
{{- end }}
|
||||
{{- if .Values.resources }}
|
||||
resources: {{- toYaml .Values.resources | nindent 12 }}
|
||||
{{- else if ne .Values.resourcesPreset "none" }}
|
||||
resources: {{- include "common.resources.preset" (dict "type" .Values.resourcesPreset) | nindent 12 }}
|
||||
{{- end }}
|
||||
ports:
|
||||
- name: http
|
||||
containerPort: {{ .Values.containerPorts.http }}
|
||||
protocol: TCP
|
||||
{{- if .Values.tls.enabled }}
|
||||
- name: https
|
||||
containerPort: {{ .Values.containerPorts.https }}
|
||||
protocol: TCP
|
||||
{{- end }}
|
||||
{{- if and (.Values.metrics.enabled) (not (eq (.Values.containerPorts.http | int) (.Values.containerPorts.metrics | int) )) }}
|
||||
- name: metrics
|
||||
containerPort: {{ .Values.containerPorts.metrics }}
|
||||
protocol: TCP
|
||||
{{- end}}
|
||||
{{- /* Constant in code: https://github.com/keycloak/keycloak/blob/ce8e925c1ad9bf7a3180d1496e181aeea0ab5f8a/operator/src/main/java/org/keycloak/operator/Constants.java#L60 */}}
|
||||
- name: discovery
|
||||
containerPort: 7800
|
||||
{{- if .Values.extraContainerPorts }}
|
||||
{{- include "common.tplvalues.render" (dict "value" .Values.extraContainerPorts "context" $) | nindent 12 }}
|
||||
{{- end }}
|
||||
{{- if not .Values.diagnosticMode.enabled }}
|
||||
{{- if .Values.customStartupProbe }}
|
||||
startupProbe: {{- include "common.tplvalues.render" (dict "value" .Values.customStartupProbe "context" $) | nindent 12 }}
|
||||
{{- else if .Values.startupProbe.enabled }}
|
||||
startupProbe: {{- omit .Values.startupProbe "enabled" | toYaml | nindent 12 }}
|
||||
httpGet:
|
||||
path: {{ .Values.httpRelativePath }}
|
||||
port: http
|
||||
{{- end }}
|
||||
{{- if .Values.customLivenessProbe }}
|
||||
livenessProbe: {{- include "common.tplvalues.render" (dict "value" .Values.customLivenessProbe "context" $) | nindent 12 }}
|
||||
{{- else if .Values.livenessProbe.enabled }}
|
||||
livenessProbe: {{- omit .Values.livenessProbe "enabled" | toYaml | nindent 12 }}
|
||||
tcpSocket:
|
||||
port: http
|
||||
{{- end }}
|
||||
{{- if .Values.customReadinessProbe }}
|
||||
readinessProbe: {{- include "common.tplvalues.render" (dict "value" .Values.customReadinessProbe "context" $) | nindent 12 }}
|
||||
{{- else if .Values.readinessProbe.enabled }}
|
||||
readinessProbe: {{- omit .Values.readinessProbe "enabled" | toYaml | nindent 12 }}
|
||||
httpGet:
|
||||
path: {{ .Values.httpRelativePath }}realms/{{ .Values.adminRealm | default "master" }}
|
||||
port: http
|
||||
{{- end }}
|
||||
{{- end }}
|
||||
volumeMounts:
|
||||
- name: empty-dir
|
||||
mountPath: /tmp
|
||||
subPath: tmp-dir
|
||||
- name: empty-dir
|
||||
mountPath: /bitnami/keycloak
|
||||
subPath: app-volume-dir
|
||||
- name: empty-dir
|
||||
mountPath: /opt/bitnami/keycloak/conf
|
||||
subPath: app-conf-dir
|
||||
- name: empty-dir
|
||||
mountPath: /opt/bitnami/keycloak/lib/quarkus
|
||||
subPath: app-quarkus-dir
|
||||
- name: empty-dir
|
||||
mountPath: /opt/bitnami/keycloak/data
|
||||
subPath: app-data-dir
|
||||
- name: empty-dir
|
||||
mountPath: /opt/bitnami/keycloak/providers
|
||||
subPath: app-providers-dir
|
||||
- name: empty-dir
|
||||
mountPath: /opt/bitnami/keycloak/themes
|
||||
subPath: app-themes-dir
|
||||
{{- if .Values.usePasswordFiles }}
|
||||
- name: keycloak-secrets
|
||||
mountPath: /opt/bitnami/keycloak/secrets
|
||||
{{- end }}
|
||||
{{- if or .Values.configuration .Values.existingConfigmap }}
|
||||
- name: keycloak-config
|
||||
mountPath: /bitnami/keycloak/conf/keycloak.conf
|
||||
subPath: keycloak.conf
|
||||
{{- end }}
|
||||
{{- if .Values.tls.enabled }}
|
||||
- name: certificates
|
||||
mountPath: /opt/bitnami/keycloak/certs
|
||||
readOnly: true
|
||||
{{- end }}
|
||||
{{- if .Values.customCaExistingSecret }}
|
||||
- name: custom-ca
|
||||
mountPath: /opt/bitnami/keycloak/custom-ca
|
||||
readOnly: true
|
||||
{{- end }}
|
||||
{{- if .Values.spi.existingSecret }}
|
||||
- name: spi-certificates
|
||||
mountPath: /opt/bitnami/keycloak/spi-certs
|
||||
readOnly: true
|
||||
{{- end }}
|
||||
{{- if or .Values.initdbScriptsConfigMap .Values.initdbScripts }}
|
||||
- name: custom-init-scripts
|
||||
mountPath: /docker-entrypoint-initdb.d
|
||||
{{- end }}
|
||||
{{- if .Values.extraVolumeMounts }}
|
||||
{{- include "common.tplvalues.render" (dict "value" .Values.extraVolumeMounts "context" $) | nindent 12 }}
|
||||
{{- end }}
|
||||
{{- if .Values.sidecars }}
|
||||
{{- include "common.tplvalues.render" ( dict "value" .Values.sidecars "context" $) | nindent 8 }}
|
||||
{{- end }}
|
||||
volumes:
|
||||
- name: empty-dir
|
||||
emptyDir: {}
|
||||
{{- if .Values.usePasswordFiles }}
|
||||
- name: keycloak-secrets
|
||||
projected:
|
||||
sources:
|
||||
- secret:
|
||||
name: {{ include "keycloak.secretName" . }}
|
||||
- secret:
|
||||
name: {{ include "keycloak.databaseSecretName" . }}
|
||||
items:
|
||||
- key: {{ include "keycloak.databaseSecretPasswordKey" . }}
|
||||
path: {{ printf "db-%s" (include "keycloak.databaseSecretPasswordKey" .) }}
|
||||
{{- if .Values.externalDatabase.existingSecretHostKey }}
|
||||
- key: {{ include "keycloak.databaseSecretHostKey" . }}
|
||||
path: {{ printf "db-%s" (include "keycloak.databaseSecretHostKey" .) }}
|
||||
{{- end }}
|
||||
{{- if .Values.externalDatabase.existingSecretPortKey }}
|
||||
- key: {{ include "keycloak.databaseSecretPortKey" . }}
|
||||
path: {{ printf "db-%s" (include "keycloak.databaseSecretPortKey" .) }}
|
||||
{{- end }}
|
||||
{{- if .Values.externalDatabase.existingSecretUserKey }}
|
||||
- key: {{ include "keycloak.databaseSecretUserKey" . }}
|
||||
path: {{ printf "db-%s" (include "keycloak.databaseSecretUserKey" .) }}
|
||||
{{- end }}
|
||||
{{- if .Values.externalDatabase.existingSecretDatabaseKey }}
|
||||
- key: {{ include "keycloak.databaseSecretDatabaseKey" . }}
|
||||
path: {{ printf "db-%s" (include "keycloak.databaseSecretDatabaseKey" .) }}
|
||||
{{- end }}
|
||||
{{- if and .Values.tls.enabled (or .Values.tls.keystorePassword .Values.tls.truststorePassword .Values.tls.passwordsSecret) }}
|
||||
- secret:
|
||||
name: {{ include "keycloak.tlsPasswordsSecretName" . }}
|
||||
{{- end }}
|
||||
{{- if and .Values.spi.existingSecret (or .Values.spi.truststorePassword .Values.spi.passwordsSecret) }}
|
||||
- secret:
|
||||
name: {{ include "keycloak.spiPasswordsSecretName" . }}
|
||||
{{- end }}
|
||||
{{- end }}
|
||||
{{- if or .Values.configuration .Values.existingConfigmap }}
|
||||
- name: keycloak-config
|
||||
configMap:
|
||||
name: {{ include "keycloak.configmapName" . }}
|
||||
{{- end }}
|
||||
{{- if .Values.tls.enabled }}
|
||||
- name: certificates
|
||||
secret:
|
||||
secretName: {{ include "keycloak.tlsSecretName" . }}
|
||||
defaultMode: 420
|
||||
{{- end }}
|
||||
{{- if .Values.customCaExistingSecret }}
|
||||
- name: custom-ca
|
||||
secret:
|
||||
secretName: {{ .Values.customCaExistingSecret }}
|
||||
defaultMode: 420
|
||||
{{- end }}
|
||||
{{- if .Values.spi.existingSecret }}
|
||||
- name: spi-certificates
|
||||
secret:
|
||||
secretName: {{ .Values.spi.existingSecret }}
|
||||
defaultMode: 420
|
||||
{{- end }}
|
||||
{{- if or .Values.initdbScriptsConfigMap .Values.initdbScripts }}
|
||||
- name: custom-init-scripts
|
||||
configMap:
|
||||
name: {{ include "keycloak.initdbScriptsCM" . }}
|
||||
{{- end }}
|
||||
{{- if .Values.extraVolumes }}
|
||||
{{- include "common.tplvalues.render" (dict "value" .Values.extraVolumes "context" $) | nindent 8 }}
|
||||
{{- end }}
|
||||
@@ -1,43 +0,0 @@
|
||||
{{- /*
|
||||
Copyright Broadcom, Inc. All Rights Reserved.
|
||||
SPDX-License-Identifier: APACHE-2.0
|
||||
*/}}
|
||||
|
||||
{{- if and (or .Values.tls.keystorePassword .Values.tls.truststorePassword) (not .Values.tls.passwordsSecret) }}
|
||||
apiVersion: v1
|
||||
kind: Secret
|
||||
metadata:
|
||||
name: {{ printf "%s-tls-passwords" (include "common.names.fullname" .) | trunc 63 | trimSuffix "-" }}
|
||||
namespace: {{ include "common.names.namespace" . | quote }}
|
||||
labels: {{- include "common.labels.standard" ( dict "customLabels" .Values.commonLabels "context" $ ) | nindent 4 }}
|
||||
app.kubernetes.io/component: keycloak
|
||||
{{- if .Values.commonAnnotations }}
|
||||
annotations: {{- include "common.tplvalues.render" ( dict "value" .Values.commonAnnotations "context" $ ) | nindent 4 }}
|
||||
{{- end }}
|
||||
type: Opaque
|
||||
data:
|
||||
{{- if .Values.tls.keystorePassword }}
|
||||
tls-keystore-password: {{ .Values.tls.keystorePassword | b64enc | quote }}
|
||||
{{- end }}
|
||||
{{- if .Values.tls.truststorePassword }}
|
||||
tls-truststore-password: {{ .Values.tls.truststorePassword | b64enc | quote }}
|
||||
{{- end }}
|
||||
---
|
||||
{{- end }}
|
||||
{{- if and .Values.spi.truststorePassword (not .Values.spi.passwordsSecret) }}
|
||||
apiVersion: v1
|
||||
kind: Secret
|
||||
metadata:
|
||||
name: {{ printf "%s-spi-passwords" (include "common.names.fullname" .) | trunc 63 | trimSuffix "-" }}
|
||||
namespace: {{ include "common.names.namespace" . | quote }}
|
||||
labels: {{- include "common.labels.standard" ( dict "customLabels" .Values.commonLabels "context" $ ) | nindent 4 }}
|
||||
app.kubernetes.io/component: keycloak
|
||||
{{- if .Values.commonAnnotations }}
|
||||
annotations: {{- include "common.tplvalues.render" ( dict "value" .Values.commonAnnotations "context" $ ) | nindent 4 }}
|
||||
{{- end }}
|
||||
type: Opaque
|
||||
data:
|
||||
{{- if .Values.spi.truststorePassword }}
|
||||
spi-truststore-password: {{ .Values.spi.truststorePassword | b64enc | quote }}
|
||||
{{- end }}
|
||||
{{- end }}
|
||||
@@ -1,71 +0,0 @@
|
||||
{{- /*
|
||||
Copyright Broadcom, Inc. All Rights Reserved.
|
||||
SPDX-License-Identifier: APACHE-2.0
|
||||
*/}}
|
||||
|
||||
{{- if .Values.ingress.enabled }}
|
||||
{{- if .Values.ingress.secrets }}
|
||||
{{- range .Values.ingress.secrets }}
|
||||
apiVersion: v1
|
||||
kind: Secret
|
||||
metadata:
|
||||
name: {{ include "common.tplvalues.render" ( dict "value" .name "context" $ ) }}
|
||||
namespace: {{ include "common.names.namespace" $ | quote }}
|
||||
labels: {{- include "common.labels.standard" ( dict "customLabels" $.Values.commonLabels "context" $ ) | nindent 4 }}
|
||||
{{- if $.Values.commonAnnotations }}
|
||||
annotations: {{- include "common.tplvalues.render" ( dict "value" $.Values.commonAnnotations "context" $ ) | nindent 4 }}
|
||||
{{- end }}
|
||||
type: kubernetes.io/tls
|
||||
data:
|
||||
tls.crt: {{ include "common.tplvalues.render" ( dict "value" .certificate "context" $ ) | b64enc }}
|
||||
tls.key: {{ include "common.tplvalues.render" ( dict "value" .key "context" $ ) | b64enc }}
|
||||
---
|
||||
{{- end }}
|
||||
{{- end }}
|
||||
{{- if and .Values.ingress.tls .Values.ingress.selfSigned }}
|
||||
{{- $secretName := printf "%s-tls" .Values.ingress.hostname }}
|
||||
{{- $ca := genCA "keycloak-ca" 365 }}
|
||||
{{- $cert := genSignedCert (tpl .Values.ingress.hostname .) nil (list (tpl .Values.ingress.hostname .)) 365 $ca }}
|
||||
apiVersion: v1
|
||||
kind: Secret
|
||||
metadata:
|
||||
name: {{ $secretName }}
|
||||
namespace: {{ include "common.names.namespace" . | quote }}
|
||||
labels: {{- include "common.labels.standard" ( dict "customLabels" .Values.commonLabels "context" $ ) | nindent 4 }}
|
||||
{{- if .Values.commonAnnotations }}
|
||||
annotations: {{- include "common.tplvalues.render" ( dict "value" .Values.commonAnnotations "context" $ ) | nindent 4 }}
|
||||
{{- end }}
|
||||
type: kubernetes.io/tls
|
||||
data:
|
||||
tls.crt: {{ include "common.secrets.lookup" (dict "secret" $secretName "key" "tls.crt" "defaultValue" $cert.Cert "context" $) }}
|
||||
tls.key: {{ include "common.secrets.lookup" (dict "secret" $secretName "key" "tls.key" "defaultValue" $cert.Key "context" $) }}
|
||||
ca.crt: {{ include "common.secrets.lookup" (dict "secret" $secretName "key" "ca.crt" "defaultValue" $ca.Cert "context" $) }}
|
||||
{{- end }}
|
||||
{{- end }}
|
||||
{{- if (include "keycloak.createTlsSecret" $) }}
|
||||
{{- $secretName := printf "%s-crt" (include "common.names.fullname" .) }}
|
||||
{{- $ca := genCA "keycloak-ca" 365 }}
|
||||
{{- $releaseNamespace := include "common.names.namespace" . }}
|
||||
{{- $clusterDomain := .Values.clusterDomain }}
|
||||
---
|
||||
apiVersion: v1
|
||||
kind: Secret
|
||||
metadata:
|
||||
name: {{ $secretName }}
|
||||
namespace: {{ include "common.names.namespace" . | quote }}
|
||||
labels: {{- include "common.labels.standard" ( dict "customLabels" .Values.commonLabels "context" $ ) | nindent 4 }}
|
||||
app.kubernetes.io/component: keycloak
|
||||
{{- if .Values.commonAnnotations }}
|
||||
annotations: {{- include "common.tplvalues.render" ( dict "value" .Values.commonAnnotations "context" $ ) | nindent 4 }}
|
||||
{{- end }}
|
||||
type: Opaque
|
||||
data:
|
||||
{{- $replicaCount := int .Values.replicaCount }}
|
||||
{{- $svcName := include "common.names.fullname" . }}
|
||||
{{- $altNames := list (printf "%s.%s.svc.%s" $svcName $releaseNamespace $clusterDomain) (printf "%s.%s" $svcName $releaseNamespace) $svcName }}
|
||||
{{- $cert := genSignedCert $svcName nil $altNames 365 $ca }}
|
||||
tls.crt: {{ include "common.secrets.lookup" (dict "secret" $secretName "key" "tls.crt" "defaultValue" $cert.Cert "context" $) }}
|
||||
tls.key: {{ include "common.secrets.lookup" (dict "secret" $secretName "key" "tls.key" "defaultValue" $cert.Key "context" $) }}
|
||||
ca.crt: {{ include "common.secrets.lookup" (dict "secret" $secretName "key" "ca.crt" "defaultValue" $ca.Cert "context" $) }}
|
||||
{{- end }}
|
||||
|
||||
File diff suppressed because it is too large
Load Diff
25
charts/paperless-ngx/.helmignore
Normal file
25
charts/paperless-ngx/.helmignore
Normal file
@@ -0,0 +1,25 @@
|
||||
# Patterns to ignore when building packages.
|
||||
# This supports shell glob matching, relative path matching, and
|
||||
# negation (prefixed with !). Only one pattern per line.
|
||||
.DS_Store
|
||||
# Common VCS dirs
|
||||
.git/
|
||||
.gitignore
|
||||
.bzr/
|
||||
.bzrignore
|
||||
.hg/
|
||||
.hgignore
|
||||
.svn/
|
||||
# Common backup files
|
||||
*.swp
|
||||
*.bak
|
||||
*.tmp
|
||||
*.orig
|
||||
*~
|
||||
# Various IDEs
|
||||
.project
|
||||
.idea/
|
||||
*.tmproj
|
||||
.vscode/
|
||||
# helm-docs templates
|
||||
*.gotmpl
|
||||
15
charts/paperless-ngx/Chart.lock
Normal file
15
charts/paperless-ngx/Chart.lock
Normal file
@@ -0,0 +1,15 @@
|
||||
dependencies:
|
||||
- name: common
|
||||
repository: https://bjw-s.github.io/helm-charts
|
||||
version: 1.5.1
|
||||
- name: postgresql
|
||||
repository: https://charts.bitnami.com/bitnami
|
||||
version: 14.0.5
|
||||
- name: mariadb
|
||||
repository: https://charts.bitnami.com/bitnami
|
||||
version: 20.1.1
|
||||
- name: redis
|
||||
repository: https://charts.bitnami.com/bitnami
|
||||
version: 20.7.0
|
||||
digest: sha256:393ade0c071a39f76cc62844ef6d14d85eeb674f099de016e1adac207f04d643
|
||||
generated: "2025-02-04T16:09:39.211839317Z"
|
||||
42
charts/paperless-ngx/Chart.yaml
Normal file
42
charts/paperless-ngx/Chart.yaml
Normal file
@@ -0,0 +1,42 @@
|
||||
annotations:
|
||||
artifacthub.io/alternativeName: paperless
|
||||
artifacthub.io/changes: |-
|
||||
- kind: fixed
|
||||
description: Allow for custom db secrets name
|
||||
artifacthub.io/links: |-
|
||||
- name: App Source
|
||||
url: https://github.com/paperless-ngx/paperless-ngx
|
||||
- name: Chart Source
|
||||
url: https://github.com/gabe565/charts/tree/main/charts/paperless-ngx
|
||||
apiVersion: v2
|
||||
appVersion: 2.14.7
|
||||
dependencies:
|
||||
- name: common
|
||||
repository: https://bjw-s.github.io/helm-charts
|
||||
version: 1.5.1
|
||||
- condition: postgresql.enabled
|
||||
name: postgresql
|
||||
repository: https://charts.bitnami.com/bitnami
|
||||
version: 14.0.5
|
||||
- condition: mariadb.enabled
|
||||
name: mariadb
|
||||
repository: https://charts.bitnami.com/bitnami
|
||||
version: 20.1.1
|
||||
- condition: redis.enabled
|
||||
name: redis
|
||||
repository: https://charts.bitnami.com/bitnami
|
||||
version: 20.7.0
|
||||
description: 'A community-supported supercharged version of paperless: scan, index
|
||||
and archive all your physical documents'
|
||||
home: https://charts.gabe565.com/charts/paperless-ngx/
|
||||
icon: https://raw.githubusercontent.com/paperless-ngx/paperless-ngx/b948750/src-ui/src/assets/logo-notext.svg
|
||||
keywords:
|
||||
- documents
|
||||
- ocr
|
||||
- paper
|
||||
kubeVersion: '>=1.22.0-0'
|
||||
name: paperless-ngx
|
||||
sources:
|
||||
- https://github.com/paperless-ngx/paperless-ngx
|
||||
type: application
|
||||
version: 0.25.1
|
||||
108
charts/paperless-ngx/README.md
Normal file
108
charts/paperless-ngx/README.md
Normal file
@@ -0,0 +1,108 @@
|
||||
# Paperless-ngx
|
||||
|
||||

|
||||

|
||||

|
||||
|
||||
A community-supported supercharged version of paperless: scan, index and archive all your physical documents
|
||||
|
||||
**Homepage:** <https://charts.gabe565.com/charts/paperless-ngx/>
|
||||
|
||||
**This chart is not maintained by the upstream project and any issues with the chart should be raised
|
||||
[here](https://github.com/gabe565/charts/issues/new?assignees=gabe565&labels=bug&template=bug_report.yaml&name=paperless-ngx&version=0.24.1)**
|
||||
|
||||
## Source Code
|
||||
|
||||
* <https://github.com/paperless-ngx/paperless-ngx>
|
||||
|
||||
## Requirements
|
||||
|
||||
Kubernetes: `>=1.22.0-0`
|
||||
|
||||
## Dependencies
|
||||
|
||||
| Repository | Name | Version |
|
||||
|------------|------|---------|
|
||||
| <https://bjw-s.github.io/helm-charts> | common | 1.5.1 |
|
||||
| <https://charts.bitnami.com/bitnami> | mariadb | 20.1.1 |
|
||||
| <https://charts.bitnami.com/bitnami> | postgresql | 14.0.5 |
|
||||
| <https://charts.bitnami.com/bitnami> | redis | 20.7.0 |
|
||||
|
||||
## Installing the Chart
|
||||
|
||||
To install the chart with the release name `paperless-ngx`
|
||||
|
||||
### OCI (Recommended)
|
||||
|
||||
```console
|
||||
helm install paperless-ngx oci://ghcr.io/gabe565/charts/paperless-ngx
|
||||
```
|
||||
|
||||
### Traditional
|
||||
|
||||
```console
|
||||
helm repo add gabe565 https://charts.gabe565.com
|
||||
helm repo update
|
||||
helm install paperless-ngx gabe565/paperless-ngx
|
||||
```
|
||||
|
||||
## Uninstalling the Chart
|
||||
|
||||
To uninstall the `paperless-ngx` deployment
|
||||
|
||||
```console
|
||||
helm uninstall paperless-ngx
|
||||
```
|
||||
|
||||
The command removes all the Kubernetes components associated with the chart **including persistent volumes** and deletes the release.
|
||||
|
||||
## Configuration
|
||||
|
||||
Read through the [values.yaml](./values.yaml) file. It has several commented out suggested values.
|
||||
Other values may be used from the [values.yaml](https://github.com/bjw-s/helm-charts/tree/a081de5/charts/library/common/values.yaml) from the [bjw-s common library](https://github.com/bjw-s/helm-charts/tree/a081de5/charts/library/common).
|
||||
|
||||
Specify each parameter using the `--set key=value[,key=value]` argument to `helm install`.
|
||||
|
||||
```console
|
||||
helm install paperless-ngx \
|
||||
--set env.TZ="America/New York" \
|
||||
gabe565/paperless-ngx
|
||||
```
|
||||
|
||||
Alternatively, a YAML file that specifies the values for the above parameters can be provided while installing the chart.
|
||||
|
||||
```console
|
||||
helm install paperless-ngx gabe565/paperless-ngx -f values.yaml
|
||||
```
|
||||
|
||||
## Custom configuration
|
||||
|
||||
### Database Installation
|
||||
|
||||
Paperless-ngx supports PostgreSQL and MariaDB.
|
||||
This chart can install PostgreSQL or MariaDB and configure Paperless-ngx automatically.
|
||||
See each database section in [`values.yaml`](./values.yaml) for configuration examples.
|
||||
|
||||
## Values
|
||||
|
||||
**Important**: When deploying an application Helm chart you can add more values from the bjw-s common library chart [here](https://github.com/bjw-s/helm-charts/tree/a081de5/charts/library/common)
|
||||
|
||||
| Key | Type | Default | Description |
|
||||
|-----|------|---------|-------------|
|
||||
| env | object | See [values.yaml](./values.yaml) | Environment variables [[ref]](https://docs.paperless-ngx.com/configuration/) |
|
||||
| env.TZ | string | `"UTC"` | Set the container timezone |
|
||||
| image.pullPolicy | string | `"IfNotPresent"` | Image pull policy |
|
||||
| image.repository | string | `"ghcr.io/paperless-ngx/paperless-ngx"` | Image repository |
|
||||
| image.tag | string | `"2.14.7"` | Image tag |
|
||||
| ingress.main | object | See [values.yaml](./values.yaml) | Enable and configure ingress settings for the chart under this key. |
|
||||
| mariadb | object | See [values.yaml](./values.yaml) | Enable and configure mariadb database subchart under this key. If enabled, the app's db envs will be set for you. [[ref]](https://github.com/bitnami/charts/tree/main/bitnami/mariadb) |
|
||||
| persistence.consume | object | See [values.yaml](./values.yaml) | Configure consume volume settings for the chart under this key. |
|
||||
| persistence.data | object | See [values.yaml](./values.yaml) | Configure data volume settings for the chart under this key. |
|
||||
| persistence.export | object | See [values.yaml](./values.yaml) | Configure export volume settings for the chart under this key. |
|
||||
| persistence.media | object | See [values.yaml](./values.yaml) | Configure media volume settings for the chart under this key. |
|
||||
| postgresql | object | See [values.yaml](./values.yaml) | Enable and configure postgresql database subchart under this key. If enabled, the app's db envs will be set for you. [[ref]](https://github.com/bitnami/charts/tree/main/bitnami/postgresql) |
|
||||
| redis | object | See [values.yaml](./values.yaml) | Enable and configure redis subchart under this key. If enabled, the app's Redis env will be set for you. [[ref]](https://github.com/bitnami/charts/tree/main/bitnami/redis) |
|
||||
| service.main | object | See [values.yaml](./values.yaml) | Configures service settings for the chart. |
|
||||
|
||||
---
|
||||
Autogenerated from chart metadata using [helm-docs](https://github.com/norwoodj/helm-docs)
|
||||
28
charts/paperless-ngx/charts/common/.helmignore
Normal file
28
charts/paperless-ngx/charts/common/.helmignore
Normal file
@@ -0,0 +1,28 @@
|
||||
# Patterns to ignore when building packages.
|
||||
# This supports shell glob matching, relative path matching, and
|
||||
# negation (prefixed with !). Only one pattern per line.
|
||||
.DS_Store
|
||||
# Common VCS dirs
|
||||
.git/
|
||||
.gitignore
|
||||
.bzr/
|
||||
.bzrignore
|
||||
.hg/
|
||||
.hgignore
|
||||
.svn/
|
||||
# Common backup files
|
||||
*.swp
|
||||
*.bak
|
||||
*.tmp
|
||||
*~
|
||||
# Various IDEs
|
||||
.project
|
||||
.idea/
|
||||
*.tmproj
|
||||
.vscode/
|
||||
# OWNERS file for Kubernetes
|
||||
OWNERS
|
||||
# helm-docs templates
|
||||
*.gotmpl
|
||||
# Test files
|
||||
tests/
|
||||
23
charts/paperless-ngx/charts/common/Chart.yaml
Normal file
23
charts/paperless-ngx/charts/common/Chart.yaml
Normal file
@@ -0,0 +1,23 @@
|
||||
annotations:
|
||||
artifacthub.io/changes: |-
|
||||
- kind: fixed
|
||||
description: Ingress secret name template is evaluated before deciding whether to omit it
|
||||
- kind: changed
|
||||
description: Updated code-server image tag to v4.13.0
|
||||
- kind: changed
|
||||
description: Updated netshoot image tag to v0.11
|
||||
- kind: changed
|
||||
description: Updated gluetun image tag to v3.34.3
|
||||
apiVersion: v2
|
||||
description: Function library for Helm charts
|
||||
home: https://github.com/bjw-s/helm-charts/tree/main/charts/library/common
|
||||
keywords:
|
||||
- common
|
||||
- library
|
||||
kubeVersion: '>=1.22.0-0'
|
||||
maintainers:
|
||||
- email: me@bjw-s.dev
|
||||
name: bjw-s
|
||||
name: common
|
||||
type: library
|
||||
version: 1.5.1
|
||||
255
charts/paperless-ngx/charts/common/README.md
Normal file
255
charts/paperless-ngx/charts/common/README.md
Normal file
@@ -0,0 +1,255 @@
|
||||
# common
|
||||
|
||||
 
|
||||
|
||||
Function library for Helm charts
|
||||
|
||||
Since a lot of the bjw-s charts follow a similar pattern, this library was built to reduce maintenance cost between the charts that use it and try achieve a goal of being DRY.
|
||||
|
||||
## Requirements
|
||||
|
||||
Kubernetes: `>=1.22.0-0`
|
||||
|
||||
## Dependencies
|
||||
|
||||
| Repository | Name | Version |
|
||||
|------------|------|---------|
|
||||
|
||||
## Installing the Chart
|
||||
|
||||
This is a [Helm Library Chart](https://helm.sh/docs/topics/library_charts/#helm).
|
||||
|
||||
**WARNING: THIS CHART IS NOT MEANT TO BE INSTALLED DIRECTLY**
|
||||
|
||||
## Using this library
|
||||
|
||||
Include this chart as a dependency in your `Chart.yaml` e.g.
|
||||
|
||||
```yaml
|
||||
# Chart.yaml
|
||||
dependencies:
|
||||
- name: common
|
||||
version: 1.5.0
|
||||
repository: https://bjw-s.github.io/helm-charts/
|
||||
```
|
||||
|
||||
For more information, take a look at the [Docs](http://bjw-s.github.io/helm-charts/docs/common-library/introduction/).
|
||||
|
||||
## Configuration
|
||||
|
||||
Read through the [values.yaml](./values.yaml) file. It has several commented out suggested values.
|
||||
|
||||
## Custom configuration
|
||||
|
||||
N/A
|
||||
|
||||
## Values
|
||||
|
||||
**Important**: When deploying an application Helm chart you can add more values from our common library chart [here](https://github.com/bjw-s/helm-charts/tree/main/charts/library/common)
|
||||
|
||||
| Key | Type | Default | Description |
|
||||
|-----|------|---------|-------------|
|
||||
| addons | object | See below | The common chart supports several add-ons. These can be configured under this key. |
|
||||
| addons.codeserver | object | See values.yaml | The common library supports adding a code-server add-on to access files. It can be configured under this key. |
|
||||
| addons.codeserver.args | list | `["--auth","none"]` | Set codeserver command line arguments. Consider setting --user-data-dir to a persistent location to preserve code-server setting changes |
|
||||
| addons.codeserver.enabled | bool | `false` | Enable running a code-server container in the pod |
|
||||
| addons.codeserver.env | object | `{}` | Set any environment variables for code-server here |
|
||||
| addons.codeserver.git | object | See below | Optionally allow access a Git repository by passing in a private SSH key |
|
||||
| addons.codeserver.git.deployKey | string | `""` | Raw SSH private key |
|
||||
| addons.codeserver.git.deployKeyBase64 | string | `""` | Base64-encoded SSH private key. When both variables are set, the raw SSH key takes precedence. |
|
||||
| addons.codeserver.git.deployKeySecret | string | `""` | Existing secret containing SSH private key The chart expects it to be present under the `id_rsa` key. |
|
||||
| addons.codeserver.image.pullPolicy | string | `"IfNotPresent"` | Specify the code-server image pull policy |
|
||||
| addons.codeserver.image.repository | string | `"ghcr.io/coder/code-server"` | Specify the code-server image |
|
||||
| addons.codeserver.image.tag | string | `"4.12.0"` | Specify the code-server image tag |
|
||||
| addons.codeserver.ingress.enabled | bool | `false` | Enable an ingress for the code-server add-on. |
|
||||
| addons.codeserver.ingress.ingressClassName | string | `nil` | Set the ingressClass that is used for this ingress. |
|
||||
| addons.codeserver.service.enabled | bool | `true` | Enable a service for the code-server add-on. |
|
||||
| addons.codeserver.volumeMounts | list | `[]` | Specify a list of volumes that get mounted in the code-server container. At least 1 volumeMount is required! |
|
||||
| addons.codeserver.workingDir | string | `""` | Specify the working dir that will be opened when code-server starts If not given, the app will default to the mountpah of the first specified volumeMount |
|
||||
| addons.netshoot | object | See values.yaml | The common library supports adding a netshoot add-on to troubleshoot network issues within a Pod. It can be configured under this key. |
|
||||
| addons.netshoot.enabled | bool | `false` | Enable running a netshoot container in the pod |
|
||||
| addons.netshoot.env | object | `{}` | Set any environment variables for netshoot here |
|
||||
| addons.netshoot.image.pullPolicy | string | `"IfNotPresent"` | Specify the netshoot image pull policy |
|
||||
| addons.netshoot.image.repository | string | `"ghcr.io/nicolaka/netshoot"` | Specify the netshoot image |
|
||||
| addons.netshoot.image.tag | string | `"v0.10"` | Specify the netshoot image tag |
|
||||
| addons.vpn | object | See values.yaml | The common chart supports adding a VPN add-on. It can be configured under this key. |
|
||||
| addons.vpn.args | list | `[]` | Override the args for the vpn sidecar container |
|
||||
| addons.vpn.configFile | string | `nil` | Provide a customized vpn configuration file to be used by the VPN. |
|
||||
| addons.vpn.configFileSecret | string | `nil` | Reference an existing secret that contains the VPN configuration file The chart expects it to be present under the `vpnConfigfile` key. |
|
||||
| addons.vpn.enabled | bool | `false` | Enable running a VPN in the pod to route traffic through a VPN |
|
||||
| addons.vpn.env | object | `{}` | All variables specified here will be added to the vpn sidecar container See the documentation of the VPN image for all config values |
|
||||
| addons.vpn.gluetun | object | See below | Make sure to read the [documentation](https://github.com/qdm12/gluetun/wiki) to see how to configure this addon! |
|
||||
| addons.vpn.gluetun.image.pullPolicy | string | `"IfNotPresent"` | Specify the Gluetun image pull policy |
|
||||
| addons.vpn.gluetun.image.repository | string | `"docker.io/qmcgaw/gluetun"` | Specify the Gluetun image |
|
||||
| addons.vpn.gluetun.image.tag | string | `"v3.33.0"` | Specify the Gluetun image tag |
|
||||
| addons.vpn.livenessProbe | object | `{}` | Optionally specify a livenessProbe, e.g. to check if the connection is still being protected by the VPN |
|
||||
| addons.vpn.networkPolicy.annotations | object | `{}` | Provide additional annotations which may be required. |
|
||||
| addons.vpn.networkPolicy.egress | string | `nil` | The egress configuration for your network policy, All outbound traffic from the pod will be blocked unless specified here. [[ref]](https://kubernetes.io/docs/concepts/services-networking/network-policies/) [[recipes]](https://github.com/ahmetb/kubernetes-network-policy-recipes) |
|
||||
| addons.vpn.networkPolicy.enabled | bool | `false` | If set to true, will deploy a network policy that blocks all outbound traffic except traffic specified as allowed |
|
||||
| addons.vpn.networkPolicy.labels | object | `{}` | Provide additional labels which may be required. |
|
||||
| addons.vpn.networkPolicy.podSelectorLabels | object | `{}` | Provide additional podSelector labels which may be required. |
|
||||
| addons.vpn.scripts | object | See values.yaml | Provide custom up/down scripts that can be used by the vpn configuration. |
|
||||
| addons.vpn.securityContext | object | See values.yaml | Set the VPN container securityContext |
|
||||
| addons.vpn.type | string | `"gluetun"` | Specify the VPN type. Valid options are `gluetun`. |
|
||||
| affinity | object | `{}` | Defines affinity constraint rules. [[ref]](https://kubernetes.io/docs/concepts/scheduling-eviction/assign-pod-node/#affinity-and-anti-affinity) |
|
||||
| args | list | `[]` | Override the args for the default container |
|
||||
| automountServiceAccountToken | bool | `true` | Specifies whether a service account token should be automatically mounted. |
|
||||
| command | list | `[]` | Override the command(s) for the default container |
|
||||
| configMaps | object | See below | Configure configMaps for the chart here. Additional configMaps can be added by adding a dictionary key similar to the 'config' object. |
|
||||
| configMaps.config.annotations | object | `{}` | Annotations to add to the configMap |
|
||||
| configMaps.config.data | object | `{}` | configMap data content. Helm template enabled. |
|
||||
| configMaps.config.enabled | bool | `false` | Enables or disables the configMap |
|
||||
| configMaps.config.labels | object | `{}` | Labels to add to the configMap |
|
||||
| controller.annotations | object | `{}` | Set annotations on the deployment/statefulset/daemonset/cronjob |
|
||||
| controller.cronjob | object | See below | CronJob configuration. Required only when using `controller.type: cronjob`. |
|
||||
| controller.cronjob.backoffLimit | int | `6` | Limits the number of times a failed job will be retried |
|
||||
| controller.cronjob.concurrencyPolicy | string | `"Forbid"` | Specifies how to treat concurrent executions of a job that is created by this cron job valid values are Allow, Forbid or Replace |
|
||||
| controller.cronjob.failedJobsHistory | int | `1` | The number of failed Jobs to keep |
|
||||
| controller.cronjob.schedule | string | `"*/20 * * * *"` | Sets the CronJob time when to execute your jobs |
|
||||
| controller.cronjob.startingDeadlineSeconds | int | `30` | The deadline in seconds for starting the job if it misses its scheduled time for any reason |
|
||||
| controller.cronjob.successfulJobsHistory | int | `1` | The number of succesful Jobs to keep |
|
||||
| controller.cronjob.ttlSecondsAfterFinished | string | `nil` | If this field is set, ttlSecondsAfterFinished after the Job finishes, it is eligible to be automatically deleted. |
|
||||
| controller.enabled | bool | `true` | enable the controller. |
|
||||
| controller.labels | object | `{}` | Set labels on the deployment/statefulset/daemonset/cronjob |
|
||||
| controller.podManagementPolicy | string | `nil` | Set statefulset podManagementPolicy, valid values are Parallel and OrderedReady (default). |
|
||||
| controller.replicas | int | `1` | Number of desired pods. When using a HorizontalPodAutoscaler, set this to `null`. |
|
||||
| controller.restartPolicy | string | `Always`. When `controller.type` is `cronjob` it defaults to `Never`. | Set Container restart policy. |
|
||||
| controller.revisionHistoryLimit | int | `3` | ReplicaSet revision history limit |
|
||||
| controller.rollingUpdate.partition | string | `nil` | Set statefulset RollingUpdate partition |
|
||||
| controller.rollingUpdate.surge | string | `nil` | Set deployment RollingUpdate max surge |
|
||||
| controller.rollingUpdate.unavailable | string | `nil` | Set deployment RollingUpdate max unavailable |
|
||||
| controller.strategy | string | `nil` | Set the controller upgrade strategy For Deployments, valid values are Recreate (default) and RollingUpdate. For StatefulSets, valid values are OnDelete and RollingUpdate (default). DaemonSets/CronJobs ignore this. |
|
||||
| controller.type | string | `"deployment"` | Set the controller type. Valid options are deployment, daemonset, statefulset or cronjob |
|
||||
| dnsConfig | object | `{}` | Configuring the ndots option may resolve nslookup issues on some Kubernetes setups. |
|
||||
| dnsPolicy | string | `nil` | Defaults to "ClusterFirst" if hostNetwork is false and "ClusterFirstWithHostNet" if hostNetwork is true. |
|
||||
| enableServiceLinks | bool | `true` | Enable/disable the generation of environment variables for services. [[ref]](https://kubernetes.io/docs/concepts/services-networking/connect-applications-service/#accessing-the-service) |
|
||||
| env | string | `nil` | Main environment variables. Template enabled. Syntax options: A) TZ: UTC B) PASSWD: '{{ .Release.Name }}' C) PASSWD: configMapKeyRef: name: config-map-name key: key-name D) PASSWD: valueFrom: secretKeyRef: name: secret-name key: key-name ... E) - name: TZ value: UTC F) - name: TZ value: '{{ .Release.Name }}' |
|
||||
| envFrom | list | `[]` | Secrets and/or ConfigMaps that will be loaded as environment variables. [[ref]](https://unofficial-kubernetes.readthedocs.io/en/latest/tasks/configure-pod-container/configmap/#use-case-consume-configmap-in-environment-variables) |
|
||||
| global.annotations | object | `{}` | Set additional global annotations. Helm templates can be used. |
|
||||
| global.fullnameOverride | string | `nil` | Set the entire name definition |
|
||||
| global.labels | object | `{}` | Set additional global labels. Helm templates can be used. |
|
||||
| global.nameOverride | string | `nil` | Set an override for the prefix of the fullname |
|
||||
| hostAliases | list | `[]` | Use hostAliases to add custom entries to /etc/hosts - mapping IP addresses to hostnames. [[ref]](https://kubernetes.io/docs/concepts/services-networking/add-entries-to-pod-etc-hosts-with-host-aliases/) |
|
||||
| hostIPC | bool | `false` | Use the host's ipc namespace |
|
||||
| hostNetwork | bool | `false` | When using hostNetwork make sure you set dnsPolicy to `ClusterFirstWithHostNet` |
|
||||
| hostPID | bool | `false` | Use the host's pid namespace |
|
||||
| hostname | string | `nil` | Allows specifying explicit hostname setting |
|
||||
| image.pullPolicy | string | `nil` | image pull policy |
|
||||
| image.repository | string | `nil` | image repository |
|
||||
| image.tag | string | `nil` | image tag |
|
||||
| imagePullSecrets | list | `[]` | Set image pull secrets |
|
||||
| ingress | object | See below | Configure the ingresses for the chart here. Additional ingresses can be added by adding a dictionary key similar to the 'main' ingress. |
|
||||
| ingress.main.annotations | object | `{}` | Provide additional annotations which may be required. |
|
||||
| ingress.main.enabled | bool | `false` | Enables or disables the ingress |
|
||||
| ingress.main.hosts[0].host | string | `"chart-example.local"` | Host address. Helm template can be passed. |
|
||||
| ingress.main.hosts[0].paths[0].path | string | `"/"` | Path. Helm template can be passed. |
|
||||
| ingress.main.hosts[0].paths[0].service.name | string | `nil` | Overrides the service name reference for this path |
|
||||
| ingress.main.hosts[0].paths[0].service.port | string | `nil` | Overrides the service port reference for this path |
|
||||
| ingress.main.ingressClassName | string | `nil` | Set the ingressClass that is used for this ingress. |
|
||||
| ingress.main.labels | object | `{}` | Provide additional labels which may be required. |
|
||||
| ingress.main.nameOverride | string | `nil` | Override the name suffix that is used for this ingress. |
|
||||
| ingress.main.primary | bool | `true` | Make this the primary ingress (used in probes, notes, etc...). If there is more than 1 ingress, make sure that only 1 ingress is marked as primary. |
|
||||
| ingress.main.tls | list | `[]` | Configure TLS for the ingress. Both secretName and hosts can process a Helm template. |
|
||||
| initContainers | object | `{}` | Specify any initContainers here as dictionary items. Each initContainer should have its own key. The dictionary item key will determine the order. Helm templates can be used. |
|
||||
| lifecycle | object | `{}` | Configure the lifecycle for the main container |
|
||||
| nodeSelector | object | `{}` | Node selection constraint [[ref]](https://kubernetes.io/docs/concepts/scheduling-eviction/assign-pod-node/#nodeselector) |
|
||||
| persistence | object | See below | Configure persistence for the chart here. Additional items can be added by adding a dictionary key similar to the 'config' key. [[ref]](https://bjw-s.github.io/helm-charts/docs/common-library/common-library-storage) |
|
||||
| persistence.config | object | See below | Default persistence for configuration files. |
|
||||
| persistence.config.accessMode | string | `"ReadWriteOnce"` | AccessMode for the persistent volume. Make sure to select an access mode that is supported by your storage provider! [[ref]](https://kubernetes.io/docs/concepts/storage/persistent-volumes/#access-modes) |
|
||||
| persistence.config.enabled | bool | `false` | Enables or disables the persistence item |
|
||||
| persistence.config.existingClaim | string | `nil` | If you want to reuse an existing claim, the name of the existing PVC can be passed here. |
|
||||
| persistence.config.mountPath | string | `nil` | Where to mount the volume in the main container. Defaults to `/<name_of_the_volume>`, setting to '-' creates the volume but disables the volumeMount. |
|
||||
| persistence.config.nameOverride | string | `nil` | Override the name suffix that is used for this volume. |
|
||||
| persistence.config.readOnly | bool | `false` | Specify if the volume should be mounted read-only. |
|
||||
| persistence.config.retain | bool | `false` | Set to true to retain the PVC upon `helm uninstall` |
|
||||
| persistence.config.size | string | `"1Gi"` | The amount of storage that is requested for the persistent volume. |
|
||||
| persistence.config.storageClass | string | `nil` | Storage Class for the config volume. If set to `-`, dynamic provisioning is disabled. If set to something else, the given storageClass is used. If undefined (the default) or set to null, no storageClassName spec is set, choosing the default provisioner. |
|
||||
| persistence.config.subPath | string | `nil` | Used in conjunction with `existingClaim`. Specifies a sub-path inside the referenced volume instead of its root |
|
||||
| persistence.config.type | string | `"pvc"` | Sets the persistence type Valid options are pvc, emptyDir, hostPath, secret, configMap or custom |
|
||||
| persistence.shared | object | See below | Create an emptyDir volume to share between all containers [[ref]]https://kubernetes.io/docs/concepts/storage/volumes/#emptydir) |
|
||||
| persistence.shared.medium | string | `nil` | Set the medium to "Memory" to mount a tmpfs (RAM-backed filesystem) instead of the storage medium that backs the node. |
|
||||
| persistence.shared.sizeLimit | string | `nil` | If the `SizeMemoryBackedVolumes` feature gate is enabled, you can specify a size for memory backed volumes. |
|
||||
| podAnnotations | object | `{}` | Set annotations on the pod |
|
||||
| podLabels | object | `{}` | Set labels on the pod |
|
||||
| podSecurityContext | object | `{}` | Configure the Security Context for the Pod |
|
||||
| priorityClassName | string | `nil` | Custom priority class for different treatment by the scheduler |
|
||||
| probes | object | See below | [[ref]](https://kubernetes.io/docs/tasks/configure-pod-container/configure-liveness-readiness-startup-probes/) |
|
||||
| probes.liveness | object | See below | Liveness probe configuration |
|
||||
| probes.liveness.custom | bool | `false` | Set this to `true` if you wish to specify your own livenessProbe |
|
||||
| probes.liveness.enabled | bool | `true` | Enable the liveness probe |
|
||||
| probes.liveness.spec | object | See below | The spec field contains the values for the default livenessProbe. If you selected `custom: true`, this field holds the definition of the livenessProbe. |
|
||||
| probes.liveness.type | string | "TCP" | sets the probe type when not using a custom probe |
|
||||
| probes.readiness | object | See below | Redainess probe configuration |
|
||||
| probes.readiness.custom | bool | `false` | Set this to `true` if you wish to specify your own readinessProbe |
|
||||
| probes.readiness.enabled | bool | `true` | Enable the readiness probe |
|
||||
| probes.readiness.spec | object | See below | The spec field contains the values for the default readinessProbe. If you selected `custom: true`, this field holds the definition of the readinessProbe. |
|
||||
| probes.readiness.type | string | "TCP" | sets the probe type when not using a custom probe |
|
||||
| probes.startup | object | See below | Startup probe configuration |
|
||||
| probes.startup.custom | bool | `false` | Set this to `true` if you wish to specify your own startupProbe |
|
||||
| probes.startup.enabled | bool | `true` | Enable the startup probe |
|
||||
| probes.startup.spec | object | See below | The spec field contains the values for the default startupProbe. If you selected `custom: true`, this field holds the definition of the startupProbe. |
|
||||
| probes.startup.type | string | "TCP" | sets the probe type when not using a custom probe |
|
||||
| resources | object | `{}` | Set the resource requests / limits for the main container. |
|
||||
| route | object | See below | Configure the gateway routes for the chart here. Additional routes can be added by adding a dictionary key similar to the 'main' route. [[ref]](https://gateway-api.sigs.k8s.io/references/spec/#gateway.networking.k8s.io%2fv1alpha2) |
|
||||
| route.main.annotations | object | `{}` | Provide additional annotations which may be required. |
|
||||
| route.main.enabled | bool | `false` | Enables or disables the route |
|
||||
| route.main.hostnames | list | `[]` | Host addresses |
|
||||
| route.main.kind | string | `"HTTPRoute"` | Set the route kind Valid options are GRPCRoute, HTTPRoute, TCPRoute, TLSRoute, UDPRoute |
|
||||
| route.main.labels | object | `{}` | Provide additional labels which may be required. |
|
||||
| route.main.nameOverride | string | `nil` | Override the name suffix that is used for this route. |
|
||||
| route.main.parentRefs | list | `[{"group":"gateway.networking.k8s.io","kind":"Gateway","name":null,"namespace":null,"sectionName":null}]` | Configure the resource the route attaches to. |
|
||||
| route.main.rules | list | `[{"backendRefs":[{"group":"","kind":"Service","name":null,"namespace":null,"port":null,"weight":1}],"matches":[{"path":{"type":"PathPrefix","value":"/"}}]}]` | Configure rules for routing. Defaults to the primary service. |
|
||||
| route.main.rules[0].backendRefs | list | `[{"group":"","kind":"Service","name":null,"namespace":null,"port":null,"weight":1}]` | Configure backends where matching requests should be sent. |
|
||||
| runtimeClassName | string | `nil` | Allow specifying a runtimeClassName other than the default one (ie: nvidia) |
|
||||
| schedulerName | string | `nil` | Allows specifying a custom scheduler name |
|
||||
| secrets | object | See below | Use this to populate secrets with the values you specify. Be aware that these values are not encrypted by default, and could therefore visible to anybody with access to the values.yaml file. Additional Secrets can be added by adding a dictionary key similar to the 'secret' object. |
|
||||
| secrets.secret.annotations | object | `{}` | Annotations to add to the Secret |
|
||||
| secrets.secret.enabled | bool | `false` | Enables or disables the Secret |
|
||||
| secrets.secret.labels | object | `{}` | Labels to add to the Secret |
|
||||
| secrets.secret.stringData | object | `{}` | Secret stringData content. Helm template enabled. |
|
||||
| securityContext | object | `{}` | Configure the Security Context for the main container |
|
||||
| service | object | See below | Configure the services for the chart here. Additional services can be added by adding a dictionary key similar to the 'main' service. |
|
||||
| service.main.annotations | object | `{}` | Provide additional annotations which may be required. |
|
||||
| service.main.enabled | bool | `true` | Enables or disables the service |
|
||||
| service.main.externalTrafficPolicy | string | `nil` | [[ref](https://kubernetes.io/docs/tutorials/services/source-ip/)] |
|
||||
| service.main.ipFamilies | list | `[]` | The ip families that should be used. Options: IPv4, IPv6 |
|
||||
| service.main.ipFamilyPolicy | string | `nil` | Specify the ip policy. Options: SingleStack, PreferDualStack, RequireDualStack |
|
||||
| service.main.labels | object | `{}` | Provide additional labels which may be required. |
|
||||
| service.main.nameOverride | string | `nil` | Override the name suffix that is used for this service |
|
||||
| service.main.ports | object | See below | Configure the Service port information here. Additional ports can be added by adding a dictionary key similar to the 'http' service. |
|
||||
| service.main.ports.http.enabled | bool | `true` | Enables or disables the port |
|
||||
| service.main.ports.http.extraSelectorLabels | object | `{}` | Allow adding additional match labels |
|
||||
| service.main.ports.http.nodePort | string | `nil` | Specify the nodePort value for the LoadBalancer and NodePort service types. [[ref]](https://kubernetes.io/docs/concepts/services-networking/service/#type-nodeport) |
|
||||
| service.main.ports.http.port | string | `nil` | The port number |
|
||||
| service.main.ports.http.primary | bool | `true` | Make this the primary port (used in probes, notes, etc...) If there is more than 1 service, make sure that only 1 port is marked as primary. |
|
||||
| service.main.ports.http.protocol | string | `"HTTP"` | Port protocol. Support values are `HTTP`, `HTTPS`, `TCP` and `UDP`. HTTPS and HTTPS spawn a TCP service and get used for internal URL and name generation |
|
||||
| service.main.ports.http.targetPort | string | `nil` | Specify a service targetPort if you wish to differ the service port from the application port. If `targetPort` is specified, this port number is used in the container definition instead of the `port` value. Therefore named ports are not supported for this field. |
|
||||
| service.main.primary | bool | `true` | Make this the primary service (used in probes, notes, etc...). If there is more than 1 service, make sure that only 1 service is marked as primary. |
|
||||
| service.main.type | string | `"ClusterIP"` | Set the service type |
|
||||
| serviceAccount.annotations | object | `{}` | Annotations to add to the service account |
|
||||
| serviceAccount.create | bool | `false` | Specifies whether a service account should be created |
|
||||
| serviceAccount.name | string | `""` | The name of the service account to use. If not set and create is true, a name is generated using the fullname template |
|
||||
| serviceMonitor | object | See below | Configure the ServiceMonitors for the chart here. Additional ServiceMonitors can be added by adding a dictionary key similar to the 'main' ServiceMonitors. |
|
||||
| serviceMonitor.main.annotations | object | `{}` | Provide additional annotations which may be required. |
|
||||
| serviceMonitor.main.enabled | bool | `false` | Enables or disables the serviceMonitor. |
|
||||
| serviceMonitor.main.endpoints | list | See values.yaml | Configures the endpoints for the serviceMonitor. |
|
||||
| serviceMonitor.main.labels | object | `{}` | Provide additional labels which may be required. |
|
||||
| serviceMonitor.main.nameOverride | string | `nil` | Override the name suffix that is used for this serviceMonitor. |
|
||||
| serviceMonitor.main.selector | object | `{}` | Configures a custom selector for the serviceMonitor, this takes precedence over specifying a service name. Helm templates can be used. |
|
||||
| serviceMonitor.main.serviceName | string | `"{{ include \"bjw-s.common.lib.chart.names.fullname\" $ }}"` | Configures the target Service for the serviceMonitor. Helm templates can be used. |
|
||||
| sidecars | object | `{}` | Specify any sidecar containers here as dictionary items. Each sidecar container should have its own key. The dictionary item key will determine the order. Helm templates can be used. |
|
||||
| termination.gracePeriodSeconds | string | `nil` | [[ref](https://kubernetes.io/docs/reference/kubernetes-api/workload-resources/pod-v1/#lifecycle)] |
|
||||
| termination.messagePath | string | `nil` | [[ref](https://kubernetes.io/docs/reference/kubernetes-api/workload-resources/pod-v1/#lifecycle-1)] |
|
||||
| termination.messagePolicy | string | `nil` | [[ref](https://kubernetes.io/docs/reference/kubernetes-api/workload-resources/pod-v1/#lifecycle-1)] |
|
||||
| tolerations | list | `[]` | Specify taint tolerations [[ref]](https://kubernetes.io/docs/concepts/scheduling-eviction/taint-and-toleration/) |
|
||||
| topologySpreadConstraints | list | `[]` | Defines topologySpreadConstraint rules. [[ref]](https://kubernetes.io/docs/concepts/workloads/pods/pod-topology-spread-constraints/) |
|
||||
| volumeClaimTemplates | list | `[]` | Used in conjunction with `controller.type: statefulset` to create individual disks for each instance. |
|
||||
|
||||
## Support
|
||||
|
||||
- See the [Docs](http://bjw-s.github.io/helm-charts/docs/)
|
||||
- Open an [issue](https://github.com/bjw-s/helm-charts/issues/new/choose)
|
||||
- Join the k8s-at-home [Discord](https://discord.gg/sTMX7Vh) community
|
||||
|
||||
----------------------------------------------
|
||||
Autogenerated from chart metadata using [helm-docs v1.11.0](https://github.com/norwoodj/helm-docs/releases/v1.11.0)
|
||||
@@ -0,0 +1,46 @@
|
||||
{{/*
|
||||
Template to render code-server addon
|
||||
It will include / inject the required templates based on the given values.
|
||||
*/}}
|
||||
{{- define "bjw-s.common.addon.codeserver" -}}
|
||||
{{- if .Values.addons.codeserver.enabled -}}
|
||||
{{/* Append the code-server container to the sidecars */}}
|
||||
{{- $container := include "bjw-s.common.addon.codeserver.container" . | fromYaml -}}
|
||||
{{- if $container -}}
|
||||
{{- $_ := set .Values.sidecars "addon-codeserver" $container -}}
|
||||
{{- end -}}
|
||||
|
||||
{{/* Include the deployKeySecret if not empty */}}
|
||||
{{- if or .Values.addons.codeserver.git.deployKey .Values.addons.codeserver.git.deployKeyBase64 -}}
|
||||
{{- $deployKeySecret := include "bjw-s.common.addon.codeserver.deployKeySecret" . -}}
|
||||
{{- if $deployKeySecret -}}
|
||||
{{- $_ := set .Values.secrets "addon-codeserver-deploykey" (dict "enabled" true "stringData" ($deployKeySecret | fromYaml)) -}}
|
||||
{{- end -}}
|
||||
{{- end -}}
|
||||
|
||||
{{/* Append the secret volume to the volumes */}}
|
||||
{{- if or .Values.addons.codeserver.git.deployKey .Values.addons.codeserver.git.deployKeyBase64 .Values.addons.codeserver.git.deployKeySecret }}
|
||||
{{- $volume := include "bjw-s.common.addon.codeserver.deployKeyVolumeSpec" . | fromYaml -}}
|
||||
{{- if $volume -}}
|
||||
{{- $_ := set .Values.persistence "deploykey" (dict "enabled" true "mountPath" "-" "type" "custom" "volumeSpec" $volume) -}}
|
||||
{{- end -}}
|
||||
{{- end -}}
|
||||
|
||||
{{/* Add the code-server service */}}
|
||||
{{- if .Values.addons.codeserver.service.enabled -}}
|
||||
{{- $serviceValues := .Values.addons.codeserver.service -}}
|
||||
{{- $_ := set $serviceValues "nameOverride" "addon-codeserver" -}}
|
||||
{{- $_ := set $ "ObjectValues" (dict "service" $serviceValues) -}}
|
||||
{{- include "bjw-s.common.class.service" $ -}}
|
||||
{{- $_ := unset $.ObjectValues "service" -}}
|
||||
{{- end -}}
|
||||
|
||||
{{/* Add the code-server ingress */}}
|
||||
{{- $svcName := printf "%v-addon-codeserver" (include "bjw-s.common.lib.chart.names.fullname" .) -}}
|
||||
{{- $svcPort := .Values.addons.codeserver.service.ports.codeserver.port -}}
|
||||
{{- range $_, $host := .Values.addons.codeserver.ingress.hosts -}}
|
||||
{{- $_ := set (index $host.paths 0) "service" (dict "name" $svcName "port" $svcPort) -}}
|
||||
{{- end -}}
|
||||
{{- $_ := set .Values.ingress "addon-codeserver" .Values.addons.codeserver.ingress -}}
|
||||
{{- end -}}
|
||||
{{- end -}}
|
||||
@@ -0,0 +1,46 @@
|
||||
{{/*
|
||||
The code-server sidecar container to be inserted.
|
||||
*/}}
|
||||
{{- define "bjw-s.common.addon.codeserver.container" -}}
|
||||
{{- if lt (len .Values.addons.codeserver.volumeMounts) 1 }}
|
||||
{{- fail "At least 1 volumeMount is required for codeserver container" }}
|
||||
{{- end -}}
|
||||
name: codeserver
|
||||
image: "{{ .Values.addons.codeserver.image.repository }}:{{ .Values.addons.codeserver.image.tag }}"
|
||||
imagePullPolicy: {{ .Values.addons.codeserver.pullPolicy }}
|
||||
{{- with .Values.addons.codeserver.securityContext }}
|
||||
securityContext:
|
||||
{{- toYaml . | nindent 2 }}
|
||||
{{- end }}
|
||||
{{- with .Values.addons.codeserver.env }}
|
||||
env:
|
||||
{{- range $k, $v := . }}
|
||||
- name: {{ $k }}
|
||||
value: {{ $v | quote }}
|
||||
{{- end }}
|
||||
{{- end }}
|
||||
ports:
|
||||
- name: codeserver
|
||||
containerPort: {{ .Values.addons.codeserver.service.ports.codeserver.port }}
|
||||
protocol: TCP
|
||||
args:
|
||||
{{- range .Values.addons.codeserver.args }}
|
||||
- {{ . | quote }}
|
||||
{{- end }}
|
||||
- "--port"
|
||||
- "{{ .Values.addons.codeserver.service.ports.codeserver.port }}"
|
||||
- {{ .Values.addons.codeserver.workingDir | default (first .Values.addons.codeserver.volumeMounts).mountPath }}
|
||||
volumeMounts:
|
||||
{{- with .Values.addons.codeserver.volumeMounts }}
|
||||
{{- toYaml . | nindent 2 }}
|
||||
{{- end }}
|
||||
{{- if or .Values.addons.codeserver.git.deployKey .Values.addons.codeserver.git.deployKeyBase64 .Values.addons.codeserver.git.deployKeySecret }}
|
||||
- name: deploykey
|
||||
mountPath: /root/.ssh/id_rsa
|
||||
subPath: id_rsa
|
||||
{{- end }}
|
||||
{{- with .Values.addons.codeserver.resources }}
|
||||
resources:
|
||||
{{- toYaml . | nindent 2 }}
|
||||
{{- end }}
|
||||
{{- end -}}
|
||||
@@ -0,0 +1,10 @@
|
||||
{{/*
|
||||
The deployKey secret to be included.
|
||||
*/}}
|
||||
{{- define "bjw-s.common.addon.codeserver.deployKeySecret" -}}
|
||||
{{- $deployKeyValue := .Values.addons.codeserver.git.deployKey -}}
|
||||
{{- if .Values.addons.codeserver.git.deployKeyBase64 -}}
|
||||
{{- $deployKeyValue = .Values.addons.codeserver.git.deployKeyBase64 | b64dec -}}
|
||||
{{- end -}}
|
||||
id_rsa: {{ $deployKeyValue | quote }}
|
||||
{{- end -}}
|
||||
@@ -0,0 +1,15 @@
|
||||
{{/*
|
||||
The volume (referencing git deploykey) to be inserted into additionalVolumes.
|
||||
*/}}
|
||||
{{- define "bjw-s.common.addon.codeserver.deployKeyVolumeSpec" -}}
|
||||
secret:
|
||||
{{- if .Values.addons.codeserver.git.deployKeySecret }}
|
||||
secretName: {{ .Values.addons.codeserver.git.deployKeySecret }}
|
||||
{{- else }}
|
||||
secretName: {{ include "bjw-s.common.lib.chart.names.fullname" . }}-addon-codeserver-deploykey
|
||||
{{- end }}
|
||||
defaultMode: {{ "0400" | toDecimal }}
|
||||
items:
|
||||
- key: id_rsa
|
||||
path: id_rsa
|
||||
{{- end -}}
|
||||
@@ -0,0 +1,13 @@
|
||||
{{/*
|
||||
Template to render netshoot addon
|
||||
It will include / inject the required templates based on the given values.
|
||||
*/}}
|
||||
{{- define "bjw-s.common.addon.netshoot" -}}
|
||||
{{- if .Values.addons.netshoot.enabled -}}
|
||||
{{/* Append the netshoot container to the sidecars */}}
|
||||
{{- $container := include "bjw-s.common.addon.netshoot.container" . | fromYaml -}}
|
||||
{{- if $container -}}
|
||||
{{- $_ := set .Values.sidecars "addon-netshoot" $container -}}
|
||||
{{- end -}}
|
||||
{{- end -}}
|
||||
{{- end -}}
|
||||
@@ -0,0 +1,27 @@
|
||||
{{/*
|
||||
The netshoot sidecar container to be inserted.
|
||||
*/}}
|
||||
{{- define "bjw-s.common.addon.netshoot.container" -}}
|
||||
name: netshoot
|
||||
image: "{{ .Values.addons.netshoot.image.repository }}:{{ .Values.addons.netshoot.image.tag }}"
|
||||
imagePullPolicy: {{ .Values.addons.netshoot.pullPolicy }}
|
||||
{{- with .Values.addons.netshoot.securityContext }}
|
||||
securityContext:
|
||||
{{- toYaml . | nindent 2 }}
|
||||
{{- end }}
|
||||
{{- with .Values.addons.netshoot.env }}
|
||||
env:
|
||||
{{- range $k, $v := . }}
|
||||
- name: {{ $k }}
|
||||
value: {{ $v | quote }}
|
||||
{{- end }}
|
||||
{{- end }}
|
||||
command:
|
||||
- /bin/sh
|
||||
- -c
|
||||
- sleep infinity
|
||||
{{- with .Values.addons.netshoot.resources }}
|
||||
resources:
|
||||
{{- toYaml . | nindent 2 }}
|
||||
{{- end }}
|
||||
{{- end -}}
|
||||
@@ -0,0 +1,45 @@
|
||||
{{/*
|
||||
Template to render VPN addon
|
||||
It will include / inject the required templates based on the given values.
|
||||
*/}}
|
||||
{{- define "bjw-s.common.addon.vpn" -}}
|
||||
{{- if .Values.addons.vpn.enabled -}}
|
||||
{{- if eq "gluetun" .Values.addons.vpn.type -}}
|
||||
{{- include "bjw-s.common.addon.gluetun" . }}
|
||||
{{- end -}}
|
||||
|
||||
{{/* Include the configmap if not empty */}}
|
||||
{{- if or .Values.addons.vpn.scripts.up .Values.addons.vpn.scripts.down }}
|
||||
{{- $configmap := include "bjw-s.common.addon.vpn.configmap" . -}}
|
||||
{{- if $configmap -}}
|
||||
{{- $_ := set .Values.configMaps "addon-vpn" (dict "enabled" true "data" ($configmap | fromYaml)) -}}
|
||||
{{- end -}}
|
||||
{{- end -}}
|
||||
|
||||
{{/* Include the secret if not empty */}}
|
||||
{{- if and .Values.addons.vpn.configFile (not .Values.addons.vpn.configFileSecret) }}
|
||||
{{- $secret := include "bjw-s.common.addon.vpn.secret" . -}}
|
||||
{{- if $secret -}}
|
||||
{{- $_ := set .Values.secrets "addon-vpn-config" (dict "enabled" true "stringData" ($secret | fromYaml)) -}}
|
||||
{{- end -}}
|
||||
{{- end -}}
|
||||
|
||||
{{/* Append the vpn scripts volume to the volumes */}}
|
||||
{{- $scriptVolume := include "bjw-s.common.addon.vpn.scriptsVolumeSpec" . | fromYaml -}}
|
||||
{{- if $scriptVolume -}}
|
||||
{{- $_ := set .Values.persistence "vpnscript" (dict "enabled" true "mountPath" "-" "type" "custom" "volumeSpec" $scriptVolume) -}}
|
||||
{{- end -}}
|
||||
|
||||
{{/* Append the vpn config volume to the volumes */}}
|
||||
{{- $configVolume := include "bjw-s.common.addon.vpn.configVolumeSpec" . | fromYaml }}
|
||||
{{ if $configVolume -}}
|
||||
{{- $_ := set .Values.persistence "vpnconfig" (dict "enabled" true "mountPath" "-" "type" "custom" "volumeSpec" $configVolume) -}}
|
||||
{{- end -}}
|
||||
|
||||
{{/* Include the networkpolicy if not empty */}}
|
||||
{{- $networkpolicy := include "bjw-s.common.addon.vpn.networkpolicy" . -}}
|
||||
{{- if $networkpolicy -}}
|
||||
{{- $networkpolicy | nindent 0 -}}
|
||||
{{- end -}}
|
||||
{{- end -}}
|
||||
{{- end -}}
|
||||
@@ -0,0 +1,14 @@
|
||||
{{/*
|
||||
The VPN config and scripts to be included.
|
||||
*/}}
|
||||
{{- define "bjw-s.common.addon.vpn.configmap" -}}
|
||||
{{- with .Values.addons.vpn.scripts.up }}
|
||||
up.sh: |-
|
||||
{{- . | nindent 2}}
|
||||
{{- end }}
|
||||
|
||||
{{- with .Values.addons.vpn.scripts.down }}
|
||||
down.sh: |-
|
||||
{{- . | nindent 2}}
|
||||
{{- end -}}
|
||||
{{- end -}}
|
||||
@@ -0,0 +1,29 @@
|
||||
{{/*
|
||||
Blueprint for the NetworkPolicy object that can be included in the addon.
|
||||
*/}}
|
||||
{{- define "bjw-s.common.addon.vpn.networkpolicy" -}}
|
||||
{{- if .Values.addons.vpn.networkPolicy.enabled }}
|
||||
---
|
||||
kind: NetworkPolicy
|
||||
apiVersion: networking.k8s.io/v1
|
||||
metadata:
|
||||
name: {{ include "bjw-s.common.lib.chart.names.fullname" . }}
|
||||
{{- with (merge (.Values.addons.vpn.networkPolicy.labels | default dict) (include "bjw-s.common.lib.metadata.allLabels" $ | fromYaml)) }}
|
||||
labels: {{- toYaml . | nindent 4 }}
|
||||
{{- end }}
|
||||
{{- with (merge (.Values.addons.vpn.networkPolicy.annotations | default dict) (include "bjw-s.common.lib.metadata.globalAnnotations" $ | fromYaml)) }}
|
||||
annotations: {{- toYaml . | nindent 4 }}
|
||||
{{- end }}
|
||||
spec:
|
||||
podSelector:
|
||||
{{- with (merge .Values.addons.vpn.networkPolicy.podSelectorLabels (include "bjw-s.common.lib.metadata.selectorLabels" . | fromYaml)) }}
|
||||
matchLabels: {{- toYaml . | nindent 6 }}
|
||||
{{- end }}
|
||||
policyTypes:
|
||||
- Egress
|
||||
egress:
|
||||
{{- with .Values.addons.vpn.networkPolicy.egress }}
|
||||
{{- . | toYaml | nindent 4 }}
|
||||
{{- end -}}
|
||||
{{- end -}}
|
||||
{{- end -}}
|
||||
@@ -0,0 +1,9 @@
|
||||
{{/*
|
||||
The OpenVPN config secret to be included.
|
||||
*/}}
|
||||
{{- define "bjw-s.common.addon.vpn.secret" -}}
|
||||
{{- if and .Values.addons.vpn.configFile (not .Values.addons.vpn.configFileSecret) -}}
|
||||
vpnConfigfile: |-
|
||||
{{- .Values.addons.vpn.configFile | nindent 2 }}
|
||||
{{- end -}}
|
||||
{{- end -}}
|
||||
@@ -0,0 +1,37 @@
|
||||
{{/*
|
||||
The volume (referencing VPN scripts) to be inserted into additionalVolumes.
|
||||
*/}}
|
||||
{{- define "bjw-s.common.addon.vpn.scriptsVolumeSpec" -}}
|
||||
{{- if or .Values.addons.vpn.scripts.up .Values.addons.vpn.scripts.down -}}
|
||||
configMap:
|
||||
name: {{ include "bjw-s.common.lib.chart.names.fullname" . }}-addon-vpn
|
||||
items:
|
||||
{{- if .Values.addons.vpn.scripts.up }}
|
||||
- key: up.sh
|
||||
path: up.sh
|
||||
mode: 0777
|
||||
{{- end }}
|
||||
{{- if .Values.addons.vpn.scripts.down }}
|
||||
- key: down.sh
|
||||
path: down.sh
|
||||
mode: 0777
|
||||
{{- end }}
|
||||
{{- end -}}
|
||||
{{- end -}}
|
||||
|
||||
{{/*
|
||||
The volume (referencing VPN config) to be inserted into additionalVolumes.
|
||||
*/}}
|
||||
{{- define "bjw-s.common.addon.vpn.configVolumeSpec" -}}
|
||||
{{- if or .Values.addons.vpn.configFile .Values.addons.vpn.configFileSecret -}}
|
||||
secret:
|
||||
{{- if .Values.addons.vpn.configFileSecret }}
|
||||
secretName: {{ .Values.addons.vpn.configFileSecret }}
|
||||
{{- else }}
|
||||
secretName: {{ include "bjw-s.common.lib.chart.names.fullname" . }}-addon-vpn-config
|
||||
{{- end }}
|
||||
items:
|
||||
- key: vpnConfigfile
|
||||
path: vpnConfigfile
|
||||
{{- end -}}
|
||||
{{- end -}}
|
||||
@@ -0,0 +1,11 @@
|
||||
{{/*
|
||||
Template to render gluetun addon. It will add the container to the list of additionalContainers.
|
||||
*/}}
|
||||
*/}}
|
||||
{{- define "bjw-s.common.addon.gluetun" -}}
|
||||
{{/* Append the gluetun container to the sidecars */}}
|
||||
{{- $container := fromYaml (include "bjw-s.common.addon.gluetun.container" .) -}}
|
||||
{{- if $container -}}
|
||||
{{- $_ := set .Values.sidecars "addon-gluetun" $container -}}
|
||||
{{- end -}}
|
||||
{{- end -}}
|
||||
@@ -0,0 +1,57 @@
|
||||
{{/*
|
||||
The gluetun sidecar container to be inserted.
|
||||
*/}}
|
||||
{{- define "bjw-s.common.addon.gluetun.container" -}}
|
||||
name: gluetun
|
||||
image: "{{ .Values.addons.vpn.gluetun.image.repository }}:{{ .Values.addons.vpn.gluetun.image.tag }}"
|
||||
imagePullPolicy: {{ .Values.addons.vpn.gluetun.pullPolicy }}
|
||||
{{- with .Values.addons.vpn.securityContext }}
|
||||
securityContext:
|
||||
{{- toYaml . | nindent 2 }}
|
||||
{{- end }}
|
||||
{{- with .Values.addons.vpn.env }}
|
||||
env:
|
||||
{{- . | toYaml | nindent 2 }}
|
||||
{{- end }}
|
||||
{{- with .Values.addons.vpn.envFrom }}
|
||||
envFrom:
|
||||
{{- . | toYaml | nindent 2 }}
|
||||
{{- end }}
|
||||
{{- with .Values.addons.vpn.args }}
|
||||
args:
|
||||
{{- . | toYaml | nindent 2 }}
|
||||
{{- end }}
|
||||
{{- if or .Values.addons.vpn.configFile .Values.addons.vpn.configFileSecret .Values.addons.vpn.scripts.up .Values.addons.vpn.scripts.down .Values.addons.vpn.additionalVolumeMounts .Values.persistence.shared.enabled }}
|
||||
volumeMounts:
|
||||
{{- if or .Values.addons.vpn.configFile .Values.addons.vpn.configFileSecret }}
|
||||
- name: vpnconfig
|
||||
mountPath: /gluetun/config.conf
|
||||
subPath: vpnConfigfile
|
||||
{{- end }}
|
||||
{{- if .Values.addons.vpn.scripts.up }}
|
||||
- name: vpnscript
|
||||
mountPath: /gluetun/scripts/up.sh
|
||||
subPath: up.sh
|
||||
{{- end }}
|
||||
{{- if .Values.addons.vpn.scripts.down }}
|
||||
- name: vpnscript
|
||||
mountPath: /gluetun/scripts/down.sh
|
||||
subPath: down.sh
|
||||
{{- end }}
|
||||
{{- if .Values.persistence.shared.enabled }}
|
||||
- mountPath: {{ .Values.persistence.shared.mountPath }}
|
||||
name: shared
|
||||
{{- end }}
|
||||
{{- with .Values.addons.vpn.additionalVolumeMounts }}
|
||||
{{- toYaml . | nindent 2 }}
|
||||
{{- end }}
|
||||
{{- end }}
|
||||
{{- with .Values.addons.vpn.livenessProbe }}
|
||||
livenessProbe:
|
||||
{{- toYaml . | nindent 2 }}
|
||||
{{- end -}}
|
||||
{{- with .Values.addons.vpn.resources }}
|
||||
resources:
|
||||
{{- toYaml . | nindent 2 }}
|
||||
{{- end }}
|
||||
{{- end -}}
|
||||
@@ -0,0 +1,34 @@
|
||||
{{/*
|
||||
This template serves as a blueprint for all configMap objects that are created
|
||||
within the common library.
|
||||
*/}}
|
||||
{{- define "bjw-s.common.class.configmap" -}}
|
||||
{{- $fullName := include "bjw-s.common.lib.chart.names.fullname" . -}}
|
||||
{{- $configMapName := $fullName -}}
|
||||
{{- $values := .Values.configmap -}}
|
||||
|
||||
{{- if hasKey . "ObjectValues" -}}
|
||||
{{- with .ObjectValues.configmap -}}
|
||||
{{- $values = . -}}
|
||||
{{- end -}}
|
||||
{{ end -}}
|
||||
|
||||
{{- if and (hasKey $values "nameOverride") $values.nameOverride -}}
|
||||
{{- $configMapName = printf "%v-%v" $configMapName $values.nameOverride -}}
|
||||
{{- end }}
|
||||
---
|
||||
apiVersion: v1
|
||||
kind: ConfigMap
|
||||
metadata:
|
||||
name: {{ $configMapName }}
|
||||
{{- with (merge ($values.labels | default dict) (include "bjw-s.common.lib.metadata.allLabels" $ | fromYaml)) }}
|
||||
labels: {{- toYaml . | nindent 4 }}
|
||||
{{- end }}
|
||||
{{- with (merge ($values.annotations | default dict) (include "bjw-s.common.lib.metadata.globalAnnotations" $ | fromYaml)) }}
|
||||
annotations: {{- toYaml . | nindent 4 }}
|
||||
{{- end }}
|
||||
data:
|
||||
{{- with $values.data }}
|
||||
{{- tpl (toYaml .) $ | nindent 2 }}
|
||||
{{- end }}
|
||||
{{- end -}}
|
||||
@@ -0,0 +1,47 @@
|
||||
{{/*
|
||||
This template serves as a blueprint for Cronjob objects that are created
|
||||
using the common library.
|
||||
*/}}
|
||||
{{- define "bjw-s.common.class.cronjob" -}}
|
||||
{{- $restartPolicy := default "Never" .Values.controller.restartPolicy -}}
|
||||
{{- if and (ne $restartPolicy "Never") (ne $restartPolicy "OnFailure") -}}
|
||||
{{- fail (printf "Not a valid restartPolicy for CronJob (%s)" $restartPolicy) -}}
|
||||
{{- end -}}
|
||||
{{- $_ := set .Values.controller "restartPolicy" $restartPolicy -}}
|
||||
---
|
||||
apiVersion: batch/v1
|
||||
kind: CronJob
|
||||
metadata:
|
||||
name: {{ include "bjw-s.common.lib.chart.names.fullname" . }}
|
||||
{{- with include "bjw-s.common.lib.controller.metadata.labels" . }}
|
||||
labels: {{- . | nindent 4 }}
|
||||
{{- end }}
|
||||
{{- with include "bjw-s.common.lib.controller.metadata.annotations" . }}
|
||||
annotations: {{- . | nindent 4 }}
|
||||
{{- end }}
|
||||
spec:
|
||||
concurrencyPolicy: "{{ .Values.controller.cronjob.concurrencyPolicy }}"
|
||||
startingDeadlineSeconds: {{ .Values.controller.cronjob.startingDeadlineSeconds }}
|
||||
schedule: "{{ .Values.controller.cronjob.schedule }}"
|
||||
successfulJobsHistoryLimit: {{ .Values.controller.cronjob.successfulJobsHistory }}
|
||||
failedJobsHistoryLimit: {{ .Values.controller.cronjob.failedJobsHistory }}
|
||||
jobTemplate:
|
||||
spec:
|
||||
{{- with .Values.controller.cronjob.ttlSecondsAfterFinished }}
|
||||
ttlSecondsAfterFinished: {{ . }}
|
||||
{{- end }}
|
||||
backoffLimit: {{ .Values.controller.cronjob.backoffLimit }}
|
||||
template:
|
||||
metadata:
|
||||
{{- with include ("bjw-s.common.lib.metadata.podAnnotations") . }}
|
||||
annotations:
|
||||
{{- . | nindent 12 }}
|
||||
{{- end }}
|
||||
labels:
|
||||
{{- include "bjw-s.common.lib.metadata.selectorLabels" . | nindent 12 }}
|
||||
{{- with .Values.podLabels }}
|
||||
{{- toYaml . | nindent 12 }}
|
||||
{{- end }}
|
||||
spec:
|
||||
{{- include "bjw-s.common.lib.controller.pod" . | nindent 10 }}
|
||||
{{- end -}}
|
||||
@@ -0,0 +1,35 @@
|
||||
{{/*
|
||||
This template serves as the blueprint for the DaemonSet objects that are created
|
||||
within the common library.
|
||||
*/}}
|
||||
{{- define "bjw-s.common.class.daemonset" -}}
|
||||
---
|
||||
apiVersion: apps/v1
|
||||
kind: DaemonSet
|
||||
metadata:
|
||||
name: {{ include "bjw-s.common.lib.chart.names.fullname" . }}
|
||||
{{- with include "bjw-s.common.lib.controller.metadata.labels" . }}
|
||||
labels: {{- . | nindent 4 }}
|
||||
{{- end }}
|
||||
{{- with include "bjw-s.common.lib.controller.metadata.annotations" . }}
|
||||
annotations: {{- . | nindent 4 }}
|
||||
{{- end }}
|
||||
spec:
|
||||
revisionHistoryLimit: {{ .Values.controller.revisionHistoryLimit }}
|
||||
selector:
|
||||
matchLabels:
|
||||
{{- include "bjw-s.common.lib.metadata.selectorLabels" . | nindent 6 }}
|
||||
template:
|
||||
metadata:
|
||||
{{- with include ("bjw-s.common.lib.metadata.podAnnotations") . }}
|
||||
annotations:
|
||||
{{- . | nindent 8 }}
|
||||
{{- end }}
|
||||
labels:
|
||||
{{- include "bjw-s.common.lib.metadata.selectorLabels" . | nindent 8 }}
|
||||
{{- with .Values.podLabels }}
|
||||
{{- toYaml . | nindent 8 }}
|
||||
{{- end }}
|
||||
spec:
|
||||
{{- include "bjw-s.common.lib.controller.pod" . | nindent 6 }}
|
||||
{{- end }}
|
||||
@@ -0,0 +1,55 @@
|
||||
{{/*
|
||||
This template serves as a blueprint for Deployment objects that are created
|
||||
using the common library.
|
||||
*/}}
|
||||
{{- define "bjw-s.common.class.deployment" -}}
|
||||
{{- $strategy := default "Recreate" .Values.controller.strategy -}}
|
||||
{{- if and (ne $strategy "Recreate") (ne $strategy "RollingUpdate") -}}
|
||||
{{- fail (printf "Not a valid strategy type for Deployment (%s)" $strategy) -}}
|
||||
{{- end -}}
|
||||
---
|
||||
apiVersion: apps/v1
|
||||
kind: Deployment
|
||||
metadata:
|
||||
name: {{ include "bjw-s.common.lib.chart.names.fullname" . }}
|
||||
{{- with include "bjw-s.common.lib.controller.metadata.labels" . }}
|
||||
labels: {{- . | nindent 4 }}
|
||||
{{- end }}
|
||||
{{- with include "bjw-s.common.lib.controller.metadata.annotations" . }}
|
||||
annotations: {{- . | nindent 4 }}
|
||||
{{- end }}
|
||||
spec:
|
||||
revisionHistoryLimit: {{ .Values.controller.revisionHistoryLimit }}
|
||||
{{- if not (eq .Values.controller.replicas nil) }}
|
||||
replicas: {{ .Values.controller.replicas }}
|
||||
{{- end }}
|
||||
strategy:
|
||||
type: {{ $strategy }}
|
||||
{{- with .Values.controller.rollingUpdate }}
|
||||
{{- if and (eq $strategy "RollingUpdate") (or .surge .unavailable) }}
|
||||
rollingUpdate:
|
||||
{{- with .unavailable }}
|
||||
maxUnavailable: {{ . }}
|
||||
{{- end }}
|
||||
{{- with .surge }}
|
||||
maxSurge: {{ . }}
|
||||
{{- end }}
|
||||
{{- end }}
|
||||
{{- end }}
|
||||
selector:
|
||||
matchLabels:
|
||||
{{- include "bjw-s.common.lib.metadata.selectorLabels" . | nindent 6 }}
|
||||
template:
|
||||
metadata:
|
||||
{{- with include ("bjw-s.common.lib.metadata.podAnnotations") . }}
|
||||
annotations:
|
||||
{{- . | nindent 8 }}
|
||||
{{- end }}
|
||||
labels:
|
||||
{{- include "bjw-s.common.lib.metadata.selectorLabels" . | nindent 8 }}
|
||||
{{- with .Values.podLabels }}
|
||||
{{- toYaml . | nindent 8 }}
|
||||
{{- end }}
|
||||
spec:
|
||||
{{- include "bjw-s.common.lib.controller.pod" . | nindent 6 }}
|
||||
{{- end -}}
|
||||
@@ -0,0 +1,75 @@
|
||||
{{/*
|
||||
This template serves as a blueprint for all Ingress objects that are created
|
||||
within the common library.
|
||||
*/}}
|
||||
{{- define "bjw-s.common.class.ingress" -}}
|
||||
{{- $fullName := include "bjw-s.common.lib.chart.names.fullname" . -}}
|
||||
{{- $ingressName := $fullName -}}
|
||||
{{- $values := .Values.ingress -}}
|
||||
|
||||
{{- if hasKey . "ObjectValues" -}}
|
||||
{{- with .ObjectValues.ingress -}}
|
||||
{{- $values = . -}}
|
||||
{{- end -}}
|
||||
{{ end -}}
|
||||
|
||||
{{- if and (hasKey $values "nameOverride") $values.nameOverride -}}
|
||||
{{- $ingressName = printf "%v-%v" $ingressName $values.nameOverride -}}
|
||||
{{- end -}}
|
||||
|
||||
{{- $primaryService := get .Values.service (include "bjw-s.common.lib.service.primary" .) -}}
|
||||
{{- $defaultServiceName := $fullName -}}
|
||||
{{- if and (hasKey $primaryService "nameOverride") $primaryService.nameOverride -}}
|
||||
{{- $defaultServiceName = printf "%v-%v" $defaultServiceName $primaryService.nameOverride -}}
|
||||
{{- end -}}
|
||||
{{- $defaultServicePort := get $primaryService.ports (include "bjw-s.common.lib.service.primaryPort" (dict "values" $primaryService)) -}}
|
||||
---
|
||||
apiVersion: networking.k8s.io/v1
|
||||
kind: Ingress
|
||||
metadata:
|
||||
name: {{ $ingressName }}
|
||||
{{- with (merge ($values.labels | default dict) (include "bjw-s.common.lib.metadata.allLabels" $ | fromYaml)) }}
|
||||
labels: {{- toYaml . | nindent 4 }}
|
||||
{{- end }}
|
||||
{{- with (merge ($values.annotations | default dict) (include "bjw-s.common.lib.metadata.globalAnnotations" $ | fromYaml)) }}
|
||||
annotations: {{- toYaml . | nindent 4 }}
|
||||
{{- end }}
|
||||
spec:
|
||||
{{- if $values.ingressClassName }}
|
||||
ingressClassName: {{ $values.ingressClassName }}
|
||||
{{- end }}
|
||||
{{- if $values.tls }}
|
||||
tls:
|
||||
{{- range $values.tls }}
|
||||
- hosts:
|
||||
{{- range .hosts }}
|
||||
- {{ tpl . $ | quote }}
|
||||
{{- end }}
|
||||
{{- $secretName := tpl (default "" .secretName) $ }}
|
||||
{{- if $secretName }}
|
||||
secretName: {{ $secretName | quote}}
|
||||
{{- end }}
|
||||
{{- end }}
|
||||
{{- end }}
|
||||
rules:
|
||||
{{- range $values.hosts }}
|
||||
- host: {{ tpl .host $ | quote }}
|
||||
http:
|
||||
paths:
|
||||
{{- range .paths }}
|
||||
{{- $service := $defaultServiceName -}}
|
||||
{{- $port := $defaultServicePort.port -}}
|
||||
{{- if .service -}}
|
||||
{{- $service = default $service .service.name -}}
|
||||
{{- $port = default $port .service.port -}}
|
||||
{{- end }}
|
||||
- path: {{ tpl .path $ | quote }}
|
||||
pathType: {{ default "Prefix" .pathType }}
|
||||
backend:
|
||||
service:
|
||||
name: {{ $service }}
|
||||
port:
|
||||
number: {{ $port }}
|
||||
{{- end }}
|
||||
{{- end }}
|
||||
{{- end }}
|
||||
@@ -0,0 +1,45 @@
|
||||
{{/*
|
||||
This template serves as a blueprint for all PersistentVolumeClaim objects that are created
|
||||
within the common library.
|
||||
*/}}
|
||||
{{- define "bjw-s.common.class.pvc" -}}
|
||||
{{- $values := .Values.persistence -}}
|
||||
{{- if hasKey . "ObjectValues" -}}
|
||||
{{- with .ObjectValues.persistence -}}
|
||||
{{- $values = . -}}
|
||||
{{- end -}}
|
||||
{{ end -}}
|
||||
{{- $pvcName := include "bjw-s.common.lib.chart.names.fullname" . -}}
|
||||
{{- if and (hasKey $values "nameOverride") $values.nameOverride -}}
|
||||
{{- if not (eq $values.nameOverride "-") -}}
|
||||
{{- $pvcName = printf "%v-%v" $pvcName $values.nameOverride -}}
|
||||
{{ end -}}
|
||||
{{ end }}
|
||||
---
|
||||
kind: PersistentVolumeClaim
|
||||
apiVersion: v1
|
||||
metadata:
|
||||
name: {{ $pvcName }}
|
||||
{{- with (merge ($values.labels | default dict) (include "bjw-s.common.lib.metadata.allLabels" $ | fromYaml)) }}
|
||||
labels: {{- toYaml . | nindent 4 }}
|
||||
{{- end }}
|
||||
annotations:
|
||||
{{- if $values.retain }}
|
||||
"helm.sh/resource-policy": keep
|
||||
{{- end }}
|
||||
{{- with (merge ($values.annotations | default dict) (include "bjw-s.common.lib.metadata.globalAnnotations" $ | fromYaml)) }}
|
||||
{{- toYaml . | nindent 4 }}
|
||||
{{- end }}
|
||||
spec:
|
||||
accessModes:
|
||||
- {{ required (printf "accessMode is required for PVC %v" $pvcName) $values.accessMode | quote }}
|
||||
resources:
|
||||
requests:
|
||||
storage: {{ required (printf "size is required for PVC %v" $pvcName) $values.size | quote }}
|
||||
{{- if $values.storageClass }}
|
||||
storageClassName: {{ if (eq "-" $values.storageClass) }}""{{- else }}{{ $values.storageClass | quote }}{{- end }}
|
||||
{{- end }}
|
||||
{{- if $values.volumeName }}
|
||||
volumeName: {{ $values.volumeName | quote }}
|
||||
{{- end }}
|
||||
{{- end -}}
|
||||
@@ -0,0 +1,73 @@
|
||||
{{/*
|
||||
This template serves as a blueprint for all Route objects that are created
|
||||
within the common library.
|
||||
*/}}
|
||||
{{- define "bjw-s.common.class.route" -}}
|
||||
{{- $values := .Values.route -}}
|
||||
{{- if hasKey . "ObjectValues" -}}
|
||||
{{- with .ObjectValues.route -}}
|
||||
{{- $values = . -}}
|
||||
{{- end -}}
|
||||
{{ end -}}
|
||||
|
||||
{{- $fullName := include "bjw-s.common.lib.chart.names.fullname" . -}}
|
||||
{{- if and (hasKey $values "nameOverride") $values.nameOverride -}}
|
||||
{{- $fullName = printf "%v-%v" $fullName $values.nameOverride -}}
|
||||
{{ end -}}
|
||||
{{- $routeKind := $values.kind | default "HTTPRoute" -}}
|
||||
{{- $primaryService := get .Values.service (include "bjw-s.common.lib.service.primary" .) -}}
|
||||
{{- $defaultServiceName := $fullName -}}
|
||||
{{- if and (hasKey $primaryService "nameOverride") $primaryService.nameOverride -}}
|
||||
{{- $defaultServiceName = printf "%v-%v" $defaultServiceName $primaryService.nameOverride -}}
|
||||
{{- end -}}
|
||||
{{- $defaultServicePort := get $primaryService.ports (include "bjw-s.common.lib.service.primaryPort" (dict "values" $primaryService)) -}}
|
||||
---
|
||||
apiVersion: gateway.networking.k8s.io/v1alpha2
|
||||
{{- if and (ne $routeKind "GRPCRoute") (ne $routeKind "HTTPRoute") (ne $routeKind "TCPRoute") (ne $routeKind "TLSRoute") (ne $routeKind "UDPRoute") }}
|
||||
{{- fail (printf "Not a valid route kind (%s)" $routeKind) }}
|
||||
{{- end }}
|
||||
kind: {{ $routeKind }}
|
||||
metadata:
|
||||
name: {{ $fullName }}
|
||||
{{- with (merge ($values.labels | default dict) (include "bjw-s.common.lib.metadata.allLabels" $ | fromYaml)) }}
|
||||
labels: {{- toYaml . | nindent 4 }}
|
||||
{{- end }}
|
||||
{{- with (merge ($values.annotations | default dict) (include "bjw-s.common.lib.metadata.globalAnnotations" $ | fromYaml)) }}
|
||||
annotations: {{- toYaml . | nindent 4 }}
|
||||
{{- end }}
|
||||
spec:
|
||||
parentRefs:
|
||||
{{- range $values.parentRefs }}
|
||||
- group: {{ default "gateway.networking.k8s.io" .group }}
|
||||
kind: {{ default "Gateway" .kind }}
|
||||
name: {{ required (printf "parentRef name is required for %v %v" $routeKind $fullName) .name }}
|
||||
namespace: {{ required (printf "parentRef namespace is required for %v %v" $routeKind $fullName) .namespace }}
|
||||
{{- if .sectionName }}
|
||||
sectionName: {{ .sectionName | quote }}
|
||||
{{- end }}
|
||||
{{- end }}
|
||||
{{- if and (ne $routeKind "TCPRoute") (ne $routeKind "UDPRoute") $values.hostnames }}
|
||||
hostnames:
|
||||
{{- with $values.hostnames }}
|
||||
{{- toYaml . | nindent 4 }}
|
||||
{{- end }}
|
||||
{{- end }}
|
||||
rules:
|
||||
{{- range $values.rules }}
|
||||
- backendRefs:
|
||||
{{- range .backendRefs }}
|
||||
- group: {{ default "" .group | quote}}
|
||||
kind: {{ default "Service" .kind }}
|
||||
name: {{ default $defaultServiceName .name }}
|
||||
namespace: {{ default $.Release.Namespace .namespace }}
|
||||
port: {{ default $defaultServicePort.port .port }}
|
||||
weight: {{ default 1 .weight }}
|
||||
{{- end }}
|
||||
{{- if (eq $routeKind "HTTPRoute") }}
|
||||
{{- with .matches }}
|
||||
matches:
|
||||
{{- toYaml . | nindent 6 }}
|
||||
{{- end }}
|
||||
{{- end }}
|
||||
{{- end }}
|
||||
{{- end }}
|
||||
@@ -0,0 +1,37 @@
|
||||
{{/*
|
||||
This template serves as a blueprint for all Secret objects that are created
|
||||
within the common library.
|
||||
*/}}
|
||||
{{- define "bjw-s.common.class.secret" -}}
|
||||
{{- $fullName := include "bjw-s.common.lib.chart.names.fullname" . -}}
|
||||
{{- $secretName := $fullName -}}
|
||||
{{- $values := .Values.configmap -}}
|
||||
|
||||
{{- if hasKey . "ObjectValues" -}}
|
||||
{{- with .ObjectValues.secret -}}
|
||||
{{- $values = . -}}
|
||||
{{- end -}}
|
||||
{{ end -}}
|
||||
|
||||
{{- if and (hasKey $values "nameOverride") $values.nameOverride -}}
|
||||
{{- $secretName = printf "%v-%v" $secretName $values.nameOverride -}}
|
||||
{{- end }}
|
||||
---
|
||||
apiVersion: v1
|
||||
kind: Secret
|
||||
{{- with $values.type }}
|
||||
type: {{ . }}
|
||||
{{- end }}
|
||||
metadata:
|
||||
name: {{ $secretName }}
|
||||
{{- with (merge ($values.labels | default dict) (include "bjw-s.common.lib.metadata.allLabels" $ | fromYaml)) }}
|
||||
labels: {{- toYaml . | nindent 4 }}
|
||||
{{- end }}
|
||||
{{- with (merge ($values.annotations | default dict) (include "bjw-s.common.lib.metadata.globalAnnotations" $ | fromYaml)) }}
|
||||
annotations: {{- toYaml . | nindent 4 }}
|
||||
{{- end }}
|
||||
{{- with $values.stringData }}
|
||||
stringData:
|
||||
{{- tpl (toYaml .) $ | nindent 2 }}
|
||||
{{- end }}
|
||||
{{- end -}}
|
||||
@@ -0,0 +1,100 @@
|
||||
{{/*
|
||||
This template serves as a blueprint for all Service objects that are created
|
||||
within the common library.
|
||||
*/}}
|
||||
{{- define "bjw-s.common.class.service" -}}
|
||||
{{- $values := .Values.service -}}
|
||||
{{- if hasKey . "ObjectValues" -}}
|
||||
{{- with .ObjectValues.service -}}
|
||||
{{- $values = . -}}
|
||||
{{- end -}}
|
||||
{{ end -}}
|
||||
|
||||
{{- $serviceName := include "bjw-s.common.lib.chart.names.fullname" . -}}
|
||||
{{- if and (hasKey $values "nameOverride") $values.nameOverride -}}
|
||||
{{- $serviceName = printf "%v-%v" $serviceName $values.nameOverride -}}
|
||||
{{ end -}}
|
||||
{{- $svcType := $values.type | default "" -}}
|
||||
{{- $enabledPorts := include "bjw-s.common.lib.service.enabledPorts" (dict "serviceName" $serviceName "values" $values) | fromYaml }}
|
||||
{{- $primaryPort := get $values.ports (include "bjw-s.common.lib.service.primaryPort" (dict "values" $values)) }}
|
||||
---
|
||||
apiVersion: v1
|
||||
kind: Service
|
||||
metadata:
|
||||
name: {{ $serviceName }}
|
||||
labels:
|
||||
app.kubernetes.io/service: {{ $serviceName }}
|
||||
{{- with (merge ($values.labels | default dict) (include "bjw-s.common.lib.metadata.allLabels" $ | fromYaml)) }}
|
||||
{{- toYaml . | nindent 4 }}
|
||||
{{- end }}
|
||||
annotations:
|
||||
{{- if eq ( $primaryPort.protocol | default "" ) "HTTPS" }}
|
||||
traefik.ingress.kubernetes.io/service.serversscheme: https
|
||||
{{- end }}
|
||||
{{- with (merge ($values.annotations | default dict) (include "bjw-s.common.lib.metadata.globalAnnotations" $ | fromYaml)) }}
|
||||
{{ toYaml . | nindent 4 }}
|
||||
{{- end }}
|
||||
spec:
|
||||
{{- if (or (eq $svcType "ClusterIP") (empty $svcType)) }}
|
||||
type: ClusterIP
|
||||
{{- if $values.clusterIP }}
|
||||
clusterIP: {{ $values.clusterIP }}
|
||||
{{end}}
|
||||
{{- else if eq $svcType "LoadBalancer" }}
|
||||
type: {{ $svcType }}
|
||||
{{- if $values.loadBalancerIP }}
|
||||
loadBalancerIP: {{ $values.loadBalancerIP }}
|
||||
{{- end }}
|
||||
{{- if $values.loadBalancerSourceRanges }}
|
||||
loadBalancerSourceRanges:
|
||||
{{ toYaml $values.loadBalancerSourceRanges | nindent 4 }}
|
||||
{{- end -}}
|
||||
{{- else }}
|
||||
type: {{ $svcType }}
|
||||
{{- end }}
|
||||
{{- if $values.externalTrafficPolicy }}
|
||||
externalTrafficPolicy: {{ $values.externalTrafficPolicy }}
|
||||
{{- end }}
|
||||
{{- if $values.sessionAffinity }}
|
||||
sessionAffinity: {{ $values.sessionAffinity }}
|
||||
{{- if $values.sessionAffinityConfig }}
|
||||
sessionAffinityConfig:
|
||||
{{ toYaml $values.sessionAffinityConfig | nindent 4 }}
|
||||
{{- end -}}
|
||||
{{- end }}
|
||||
{{- with $values.externalIPs }}
|
||||
externalIPs:
|
||||
{{- toYaml . | nindent 4 }}
|
||||
{{- end }}
|
||||
{{- if $values.publishNotReadyAddresses }}
|
||||
publishNotReadyAddresses: {{ $values.publishNotReadyAddresses }}
|
||||
{{- end }}
|
||||
{{- if $values.ipFamilyPolicy }}
|
||||
ipFamilyPolicy: {{ $values.ipFamilyPolicy }}
|
||||
{{- end }}
|
||||
{{- with $values.ipFamilies }}
|
||||
ipFamilies:
|
||||
{{ toYaml . | nindent 4 }}
|
||||
{{- end }}
|
||||
ports:
|
||||
{{- range $name, $port := $enabledPorts }}
|
||||
- port: {{ $port.port }}
|
||||
targetPort: {{ $port.targetPort | default $name }}
|
||||
{{- if $port.protocol }}
|
||||
{{- if or ( eq $port.protocol "HTTP" ) ( eq $port.protocol "HTTPS" ) ( eq $port.protocol "TCP" ) }}
|
||||
protocol: TCP
|
||||
{{- else }}
|
||||
protocol: {{ $port.protocol }}
|
||||
{{- end }}
|
||||
{{- else }}
|
||||
protocol: TCP
|
||||
{{- end }}
|
||||
name: {{ $name }}
|
||||
{{- if (and (eq $svcType "NodePort") (not (empty $port.nodePort))) }}
|
||||
nodePort: {{ $port.nodePort }}
|
||||
{{ end }}
|
||||
{{- end -}}
|
||||
{{- with (merge ($values.extraSelectorLabels | default dict) (include "bjw-s.common.lib.metadata.selectorLabels" . | fromYaml)) }}
|
||||
selector: {{- toYaml . | nindent 4 }}
|
||||
{{- end }}
|
||||
{{- end }}
|
||||
@@ -0,0 +1,19 @@
|
||||
{{/*
|
||||
This template serves as a blueprint for ServiceAccount objects that are created
|
||||
using the common library.
|
||||
*/}}
|
||||
{{- define "bjw-s.common.class.serviceAccount" -}}
|
||||
---
|
||||
apiVersion: v1
|
||||
kind: ServiceAccount
|
||||
metadata:
|
||||
name: {{ include "bjw-s.common.lib.chart.names.serviceAccountName" . }}
|
||||
{{- with include "bjw-s.common.lib.metadata.allLabels" $ | fromYaml }}
|
||||
labels: {{- toYaml . | nindent 4 }}
|
||||
{{- end }}
|
||||
{{- with (merge (.Values.serviceAccount.annotations | default dict) (include "bjw-s.common.lib.metadata.globalAnnotations" $ | fromYaml)) }}
|
||||
annotations: {{- toYaml . | nindent 4 }}
|
||||
{{- end }}
|
||||
secrets:
|
||||
- name: {{ include "bjw-s.common.lib.chart.names.fullname" . }}-sa-token
|
||||
{{- end -}}
|
||||
@@ -0,0 +1,34 @@
|
||||
{{- define "bjw-s.common.class.serviceMonitor" -}}
|
||||
{{- $values := dict -}}
|
||||
{{- if hasKey . "ObjectValues" -}}
|
||||
{{- with .ObjectValues.serviceMonitor -}}
|
||||
{{- $values = . -}}
|
||||
{{- end -}}
|
||||
{{ end -}}
|
||||
|
||||
{{- $serviceMonitorName := include "bjw-s.common.lib.chart.names.fullname" . -}}
|
||||
{{- if and (hasKey $values "nameOverride") $values.nameOverride -}}
|
||||
{{- $serviceMonitorName = printf "%v-%v" $serviceMonitorName $values.nameOverride -}}
|
||||
{{ end -}}
|
||||
---
|
||||
apiVersion: monitoring.coreos.com/v1
|
||||
kind: ServiceMonitor
|
||||
metadata:
|
||||
name: {{ $serviceMonitorName }}
|
||||
{{- with (merge ($values.labels | default dict) (include "bjw-s.common.lib.metadata.allLabels" $ | fromYaml)) }}
|
||||
labels: {{- toYaml . | nindent 4 }}
|
||||
{{- end }}
|
||||
{{- with (merge ($values.annotations | default dict) (include "bjw-s.common.lib.metadata.globalAnnotations" $ | fromYaml)) }}
|
||||
annotations: {{- toYaml . | nindent 4 }}
|
||||
{{- end }}
|
||||
spec:
|
||||
selector:
|
||||
{{- if $values.selector -}}
|
||||
{{- tpl ($values.selector | toYaml) $ | nindent 4}}
|
||||
{{- else }}
|
||||
matchLabels:
|
||||
app.kubernetes.io/service: {{ tpl $values.serviceName $ }}
|
||||
{{- include "bjw-s.common.lib.metadata.selectorLabels" . | nindent 6 }}
|
||||
{{- end }}
|
||||
endpoints: {{- toYaml (required (printf "endpoints are required for serviceMonitor %v" $serviceMonitorName) $values.endpoints) | nindent 4 }}
|
||||
{{- end }}
|
||||
@@ -0,0 +1,68 @@
|
||||
{{/*
|
||||
This template serves as the blueprint for the StatefulSet objects that are created
|
||||
within the common library.
|
||||
*/}}
|
||||
{{- define "bjw-s.common.class.statefulset" -}}
|
||||
{{- $strategy := default "RollingUpdate" .Values.controller.strategy -}}
|
||||
{{- if and (ne $strategy "OnDelete") (ne $strategy "RollingUpdate") -}}
|
||||
{{- fail (printf "Not a valid strategy type for StatefulSet (%s)" $strategy) -}}
|
||||
{{- end -}}
|
||||
---
|
||||
apiVersion: apps/v1
|
||||
kind: StatefulSet
|
||||
metadata:
|
||||
name: {{ include "bjw-s.common.lib.chart.names.fullname" . }}
|
||||
{{- with include "bjw-s.common.lib.controller.metadata.labels" . }}
|
||||
labels: {{- . | nindent 4 }}
|
||||
{{- end }}
|
||||
{{- with include "bjw-s.common.lib.controller.metadata.annotations" . }}
|
||||
annotations: {{- . | nindent 4 }}
|
||||
{{- end }}
|
||||
spec:
|
||||
revisionHistoryLimit: {{ .Values.controller.revisionHistoryLimit }}
|
||||
replicas: {{ .Values.controller.replicas }}
|
||||
podManagementPolicy: {{ default "OrderedReady" .Values.controller.podManagementPolicy }}
|
||||
updateStrategy:
|
||||
type: {{ $strategy }}
|
||||
{{- if and (eq $strategy "RollingUpdate") .Values.controller.rollingUpdate.partition }}
|
||||
rollingUpdate:
|
||||
partition: {{ .Values.controller.rollingUpdate.partition }}
|
||||
{{- end }}
|
||||
selector:
|
||||
matchLabels:
|
||||
{{- include "bjw-s.common.lib.metadata.selectorLabels" . | nindent 6 }}
|
||||
serviceName: {{ include "bjw-s.common.lib.chart.names.fullname" . }}
|
||||
template:
|
||||
metadata:
|
||||
{{- with include ("bjw-s.common.lib.metadata.podAnnotations") . }}
|
||||
annotations:
|
||||
{{- . | nindent 8 }}
|
||||
{{- end }}
|
||||
labels:
|
||||
{{- include "bjw-s.common.lib.metadata.selectorLabels" . | nindent 8 }}
|
||||
{{- with .Values.podLabels }}
|
||||
{{- toYaml . | nindent 8 }}
|
||||
{{- end }}
|
||||
spec:
|
||||
{{- include "bjw-s.common.lib.controller.pod" . | nindent 6 }}
|
||||
volumeClaimTemplates:
|
||||
{{- range $index, $volumeClaimTemplate := .Values.volumeClaimTemplates }}
|
||||
- metadata:
|
||||
name: {{ $volumeClaimTemplate.name }}
|
||||
{{- with ($volumeClaimTemplate.labels | default dict) }}
|
||||
labels: {{- toYaml . | nindent 10 }}
|
||||
{{- end }}
|
||||
{{- with ($volumeClaimTemplate.annotations | default dict) }}
|
||||
annotations: {{- toYaml . | nindent 10 }}
|
||||
{{- end }}
|
||||
spec:
|
||||
accessModes:
|
||||
- {{ required (printf "accessMode is required for volumeClaimTemplate %v" $volumeClaimTemplate.name) $volumeClaimTemplate.accessMode | quote }}
|
||||
resources:
|
||||
requests:
|
||||
storage: {{ required (printf "size is required for PVC %v" $volumeClaimTemplate.name) $volumeClaimTemplate.size | quote }}
|
||||
{{- if $volumeClaimTemplate.storageClass }}
|
||||
storageClassName: {{ if (eq "-" $volumeClaimTemplate.storageClass) }}""{{- else }}{{ $volumeClaimTemplate.storageClass | quote }}{{- end }}
|
||||
{{- end }}
|
||||
{{- end }}
|
||||
{{- end }}
|
||||
@@ -0,0 +1,45 @@
|
||||
{{/* Expand the name of the chart */}}
|
||||
{{- define "bjw-s.common.lib.chart.names.name" -}}
|
||||
{{- $globalNameOverride := "" -}}
|
||||
{{- if hasKey .Values "global" -}}
|
||||
{{- $globalNameOverride = (default $globalNameOverride .Values.global.nameOverride) -}}
|
||||
{{- end -}}
|
||||
{{- default .Chart.Name (default .Values.nameOverride $globalNameOverride) | trunc 63 | trimSuffix "-" -}}
|
||||
{{- end -}}
|
||||
|
||||
{{/*
|
||||
Create a default fully qualified app name.
|
||||
We truncate at 63 chars because some Kubernetes name fields are limited to this (by the DNS naming spec).
|
||||
If release name contains chart name it will be used as a full name.
|
||||
*/}}
|
||||
{{- define "bjw-s.common.lib.chart.names.fullname" -}}
|
||||
{{- $name := include "bjw-s.common.lib.chart.names.name" . -}}
|
||||
{{- $globalFullNameOverride := "" -}}
|
||||
{{- if hasKey .Values "global" -}}
|
||||
{{- $globalFullNameOverride = (default $globalFullNameOverride .Values.global.fullnameOverride) -}}
|
||||
{{- end -}}
|
||||
{{- if or .Values.fullnameOverride $globalFullNameOverride -}}
|
||||
{{- $name = default .Values.fullnameOverride $globalFullNameOverride -}}
|
||||
{{- else -}}
|
||||
{{- if contains $name .Release.Name -}}
|
||||
{{- $name = .Release.Name -}}
|
||||
{{- else -}}
|
||||
{{- $name = printf "%s-%s" .Release.Name $name -}}
|
||||
{{- end -}}
|
||||
{{- end -}}
|
||||
{{- trunc 63 $name | trimSuffix "-" -}}
|
||||
{{- end -}}
|
||||
|
||||
{{/* Create chart name and version as used by the chart label */}}
|
||||
{{- define "bjw-s.common.lib.chart.names.chart" -}}
|
||||
{{- printf "%s-%s" .Chart.Name .Chart.Version | replace "+" "_" | trunc 63 | trimSuffix "-" -}}
|
||||
{{- end -}}
|
||||
|
||||
{{/* Create the name of the ServiceAccount to use */}}
|
||||
{{- define "bjw-s.common.lib.chart.names.serviceAccountName" -}}
|
||||
{{- if .Values.serviceAccount.create -}}
|
||||
{{- default (include "bjw-s.common.lib.chart.names.fullname" .) .Values.serviceAccount.name -}}
|
||||
{{- else -}}
|
||||
{{- default "default" .Values.serviceAccount.name -}}
|
||||
{{- end -}}
|
||||
{{- end -}}
|
||||
@@ -0,0 +1,56 @@
|
||||
{{/*
|
||||
Default NOTES.txt content.
|
||||
*/}}
|
||||
{{- define "bjw-s.common.lib.chart.notes" -}}
|
||||
|
||||
{{- $primaryIngress := get .Values.ingress (include "bjw-s.common.lib.ingress.primary" .) -}}
|
||||
{{- $primaryService := get .Values.service (include "bjw-s.common.lib.service.primary" .) -}}
|
||||
{{- $primaryPort := "" -}}
|
||||
{{- if $primaryService -}}
|
||||
{{- $primaryPort = get $primaryService.ports (include "bjw-s.common.lib.service.primaryPort" (dict "serviceName" (include "bjw-s.common.lib.service.primary" .) "values" $primaryService)) -}}
|
||||
{{- end -}}
|
||||
|
||||
{{- $prefix := "http" -}}
|
||||
{{- if $primaryPort }}
|
||||
{{- if hasKey $primaryPort "protocol" }}
|
||||
{{- if eq $primaryPort.protocol "HTTPS" }}
|
||||
{{- $prefix = "https" }}
|
||||
{{- end }}
|
||||
{{- end }}
|
||||
{{- end }}
|
||||
|
||||
{{- if $primaryIngress }}
|
||||
1. Access the application by visiting one of these URL's:
|
||||
{{ range $primaryIngress.hosts }}
|
||||
{{- $prefix = "http" -}}
|
||||
{{ if $primaryIngress.tls -}}
|
||||
{{- $prefix = "https" -}}
|
||||
{{ end -}}
|
||||
{{- $host := .host -}}
|
||||
{{ if .hostTpl -}}
|
||||
{{- $host = tpl .hostTpl $ -}}
|
||||
{{ end }}
|
||||
{{- $path := (first .paths).path | default "/" -}}
|
||||
{{ if (first .paths).pathTpl -}}
|
||||
{{- $path = tpl (first .paths).pathTpl $ -}}
|
||||
{{ end }}
|
||||
- {{ $prefix }}://{{- $host }}{{- $path }}
|
||||
{{- end }}
|
||||
{{- else if and $primaryService $primaryPort }}
|
||||
1. Get the application URL by running these commands:
|
||||
{{- if contains "NodePort" $primaryService.type }}
|
||||
export NODE_PORT=$(kubectl get --namespace {{ .Release.Namespace }} -o jsonpath="{.spec.ports[0].nodePort}" services {{ include "bjw-s.common.lib.chart.names.fullname" . }})
|
||||
export NODE_IP=$(kubectl get nodes --namespace {{ .Release.Namespace }} -o jsonpath="{.items[0].status.addresses[0].address}")
|
||||
echo {{ $prefix }}://$NODE_IP:$NODE_PORT
|
||||
{{- else if contains "LoadBalancer" $primaryService.type }}
|
||||
NOTE: It may take a few minutes for the LoadBalancer IP to be available.
|
||||
You can watch the status of by running 'kubectl get svc -w {{ include "bjw-s.common.lib.chart.names.fullname" . }}'
|
||||
export SERVICE_IP=$(kubectl get svc --namespace {{ .Release.Namespace }} {{ include "bjw-s.common.lib.chart.names.fullname" . }} -o jsonpath='{.status.loadBalancer.ingress[0].ip}')
|
||||
echo {{ $prefix }}://$SERVICE_IP:{{ $primaryPort.port | toString | atoi }}
|
||||
{{- else if contains "ClusterIP" $primaryService.type }}
|
||||
export POD_NAME=$(kubectl get pods --namespace {{ .Release.Namespace }} -l "app.kubernetes.io/name={{ include "bjw-s.common.lib.chart.names.name" . }},app.kubernetes.io/instance={{ .Release.Name }}" -o jsonpath="{.items[0].metadata.name}")
|
||||
echo "Visit {{ $prefix }}://127.0.0.1:8080 to use your application"
|
||||
kubectl port-forward $POD_NAME 8080:{{ $primaryPort.port | toString | atoi }}
|
||||
{{- end }}
|
||||
{{- end }}
|
||||
{{- end -}}
|
||||
@@ -0,0 +1,15 @@
|
||||
{{/*
|
||||
Image used by the main container.
|
||||
*/}}
|
||||
{{- define "bjw-s.common.lib.container.image" -}}
|
||||
{{- $imageRepo := .Values.image.repository -}}
|
||||
{{- $imageTag := default .Chart.AppVersion .Values.image.tag -}}
|
||||
|
||||
{{- if kindIs "float64" .Values.image.tag -}}
|
||||
{{- $imageTag = .Values.image.tag | toString -}}
|
||||
{{- end -}}
|
||||
|
||||
{{- if and $imageRepo $imageTag -}}
|
||||
{{- printf "%s:%s" $imageRepo $imageTag -}}
|
||||
{{- end -}}
|
||||
{{- end -}}
|
||||
@@ -0,0 +1,43 @@
|
||||
{{/*
|
||||
Environment variables used by containers.
|
||||
*/}}
|
||||
{{- define "bjw-s.common.lib.container.envVars" -}}
|
||||
{{- $values := .Values.env -}}
|
||||
{{- if hasKey . "ObjectValues" -}}
|
||||
{{- with .ObjectValues.envVars -}}
|
||||
{{- $values = . -}}
|
||||
{{- end -}}
|
||||
{{- end -}}
|
||||
|
||||
{{- with $values -}}
|
||||
{{- $result := list -}}
|
||||
{{- range $k, $v := . -}}
|
||||
{{- $name := $k -}}
|
||||
{{- $value := $v -}}
|
||||
{{- if kindIs "int" $name -}}
|
||||
{{- $name = required "environment variables as a list of maps require a name field" $value.name -}}
|
||||
{{- end -}}
|
||||
|
||||
{{- if kindIs "map" $value -}}
|
||||
{{- if hasKey $value "value" -}}
|
||||
{{- $envValue := $value.value | toString -}}
|
||||
{{- $result = append $result (dict "name" $name "value" (tpl $envValue $)) -}}
|
||||
{{- else if hasKey $value "valueFrom" -}}
|
||||
{{- $result = append $result (dict "name" $name "valueFrom" $value.valueFrom) -}}
|
||||
{{- else -}}
|
||||
{{- $result = append $result (dict "name" $name "valueFrom" $value) -}}
|
||||
{{- end -}}
|
||||
{{- end -}}
|
||||
{{- if not (kindIs "map" $value) -}}
|
||||
{{- if kindIs "string" $value -}}
|
||||
{{- $result = append $result (dict "name" $name "value" (tpl $value $)) -}}
|
||||
{{- else if or (kindIs "float64" $value) (kindIs "bool" $value) -}}
|
||||
{{- $result = append $result (dict "name" $name "value" ($value | toString)) -}}
|
||||
{{- else -}}
|
||||
{{- $result = append $result (dict "name" $name "value" $value) -}}
|
||||
{{- end -}}
|
||||
{{- end -}}
|
||||
{{- end -}}
|
||||
{{- toYaml (dict "env" $result) | nindent 0 -}}
|
||||
{{- end -}}
|
||||
{{- end -}}
|
||||
@@ -0,0 +1,41 @@
|
||||
{{/*
|
||||
Ports included by the controller.
|
||||
*/}}
|
||||
{{- define "bjw-s.common.lib.container.ports" -}}
|
||||
{{- $ports := list -}}
|
||||
{{- range $servicename, $service := .Values.service -}}
|
||||
{{- $serviceEnabled := true -}}
|
||||
{{- if hasKey $service "enabled" -}}
|
||||
{{- $serviceEnabled = $service.enabled -}}
|
||||
{{- end -}}
|
||||
{{- if $serviceEnabled -}}
|
||||
{{- $enabledPorts := include "bjw-s.common.lib.service.enabledPorts" (dict "serviceName" $servicename "values" $service) | fromYaml }}
|
||||
{{- range $portname, $port := ($enabledPorts | default dict) -}}
|
||||
{{- $_ := set $port "name" $portname -}}
|
||||
{{- $ports = mustAppend $ports $port -}}
|
||||
{{- end -}}
|
||||
{{- end -}}
|
||||
{{- end -}}
|
||||
|
||||
{{/* export/render the list of ports */}}
|
||||
{{- if $ports -}}
|
||||
{{- range $_ := $ports }}
|
||||
{{- if default true .enabled | }}
|
||||
- name: {{ .name }}
|
||||
{{- if and .targetPort (kindIs "string" .targetPort) }}
|
||||
{{- fail (printf "Our charts do not support named ports for targetPort. (port name %s, targetPort %s)" .name .targetPort) }}
|
||||
{{- end }}
|
||||
containerPort: {{ .targetPort | default .port }}
|
||||
{{- if .protocol }}
|
||||
{{- if or ( eq .protocol "HTTP" ) ( eq .protocol "HTTPS" ) ( eq .protocol "TCP" ) }}
|
||||
protocol: TCP
|
||||
{{- else }}
|
||||
protocol: {{ .protocol }}
|
||||
{{- end }}
|
||||
{{- else }}
|
||||
protocol: TCP
|
||||
{{- end }}
|
||||
{{- end}}
|
||||
{{- end -}}
|
||||
{{- end -}}
|
||||
{{- end -}}
|
||||
@@ -0,0 +1,67 @@
|
||||
{{/*
|
||||
Probes selection logic.
|
||||
*/}}
|
||||
{{- define "bjw-s.common.lib.container.probes" -}}
|
||||
{{- $primaryService := get .Values.service (include "bjw-s.common.lib.service.primary" .) -}}
|
||||
{{- $primaryPort := "" -}}
|
||||
{{- if $primaryService -}}
|
||||
{{- $primaryPort = get $primaryService.ports (include "bjw-s.common.lib.service.primaryPort" (dict "serviceName" (include "bjw-s.common.lib.service.primary" .) "values" $primaryService)) -}}
|
||||
{{- end -}}
|
||||
|
||||
{{- range $probeName, $probe := .Values.probes -}}
|
||||
{{- if $probe.enabled -}}
|
||||
{{- $probeOutput := "" -}}
|
||||
{{- if $probe.custom -}}
|
||||
{{- if $probe.spec -}}
|
||||
{{- $probeOutput = $probe.spec | toYaml -}}
|
||||
{{- end -}}
|
||||
{{- else -}}
|
||||
{{- if $primaryPort -}}
|
||||
{{- $probeType := "" -}}
|
||||
{{- if eq $probe.type "AUTO" -}}
|
||||
{{- $probeType = $primaryPort.protocol -}}
|
||||
{{- else -}}
|
||||
{{- $probeType = $probe.type | default "TCP" -}}
|
||||
{{- end -}}
|
||||
|
||||
{{- $probeDefinition := dict
|
||||
"initialDelaySeconds" $probe.spec.initialDelaySeconds
|
||||
"failureThreshold" $probe.spec.failureThreshold
|
||||
"timeoutSeconds" $probe.spec.timeoutSeconds
|
||||
"periodSeconds" $probe.spec.periodSeconds
|
||||
-}}
|
||||
|
||||
{{- $probeHeader := "" -}}
|
||||
{{- if or ( eq $probeType "HTTPS" ) ( eq $probeType "HTTP" ) -}}
|
||||
{{- $probeHeader = "httpGet" -}}
|
||||
|
||||
{{- $_ := set $probeDefinition $probeHeader (
|
||||
dict
|
||||
"path" $probe.path
|
||||
"scheme" $probeType
|
||||
)
|
||||
-}}
|
||||
{{- else }}
|
||||
{{- $probeHeader = "tcpSocket" -}}
|
||||
{{- $_ := set $probeDefinition $probeHeader dict -}}
|
||||
{{- end -}}
|
||||
|
||||
{{- if $probe.port }}
|
||||
{{- $_ := set (index $probeDefinition $probeHeader) "port" (tpl ( $probe.port | toString ) $) -}}
|
||||
{{- else if $primaryPort.targetPort }}
|
||||
{{- $_ := set (index $probeDefinition $probeHeader) "port" $primaryPort.targetPort -}}
|
||||
{{- else }}
|
||||
{{- $_ := set (index $probeDefinition $probeHeader) "port" ($primaryPort.port | toString | atoi ) -}}
|
||||
{{- end }}
|
||||
|
||||
{{- $probeOutput = $probeDefinition | toYaml | trim -}}
|
||||
{{- end -}}
|
||||
{{- end -}}
|
||||
|
||||
{{- if $probeOutput -}}
|
||||
{{- printf "%sProbe:" $probeName | nindent 0 -}}
|
||||
{{- $probeOutput | nindent 2 -}}
|
||||
{{- end -}}
|
||||
{{- end -}}
|
||||
{{- end -}}
|
||||
{{- end -}}
|
||||
@@ -0,0 +1,56 @@
|
||||
{{/* Volumes included by the controller */}}
|
||||
{{- define "bjw-s.common.lib.container.volumeMounts" -}}
|
||||
{{- range $persistenceIndex, $persistenceItem := .Values.persistence }}
|
||||
{{- if $persistenceItem.enabled -}}
|
||||
{{- if kindIs "slice" $persistenceItem.subPath -}}
|
||||
{{- if $persistenceItem.mountPath -}}
|
||||
{{- fail (printf "Cannot use persistence.mountPath with a subPath list (%s)" $persistenceIndex) }}
|
||||
{{- end -}}
|
||||
{{- range $subPathIndex, $subPathItem := $persistenceItem.subPath }}
|
||||
- name: {{ $persistenceIndex }}
|
||||
subPath: {{ required "subPaths as a list of maps require a path field" $subPathItem.path }}
|
||||
mountPath: {{ required "subPaths as a list of maps require an explicit mountPath field" $subPathItem.mountPath }}
|
||||
{{- with $subPathItem.readOnly }}
|
||||
readOnly: {{ . }}
|
||||
{{- end }}
|
||||
{{- with $subPathItem.mountPropagation }}
|
||||
mountPropagation: {{ . }}
|
||||
{{- end }}
|
||||
{{- end -}}
|
||||
{{- else -}}
|
||||
{{/* Set the default mountPath to /<name_of_the_peristence_item> */}}
|
||||
{{- $mountPath := (printf "/%v" $persistenceIndex) -}}
|
||||
{{- if eq "hostPath" (default "pvc" $persistenceItem.type) -}}
|
||||
{{- $mountPath = $persistenceItem.hostPath -}}
|
||||
{{- end -}}
|
||||
{{/* Use the specified mountPath if provided */}}
|
||||
{{- with $persistenceItem.mountPath -}}
|
||||
{{- $mountPath = . -}}
|
||||
{{- end }}
|
||||
{{- if ne $mountPath "-" }}
|
||||
- name: {{ $persistenceIndex }}
|
||||
mountPath: {{ $mountPath }}
|
||||
{{- with $persistenceItem.subPath }}
|
||||
subPath: {{ . }}
|
||||
{{- end }}
|
||||
{{- with $persistenceItem.readOnly }}
|
||||
readOnly: {{ . }}
|
||||
{{- end }}
|
||||
{{- with $persistenceItem.mountPropagation }}
|
||||
mountPropagation: {{ . }}
|
||||
{{- end }}
|
||||
{{- end }}
|
||||
{{- end -}}
|
||||
{{- end -}}
|
||||
{{- end }}
|
||||
|
||||
{{- if eq .Values.controller.type "statefulset" }}
|
||||
{{- range $index, $vct := .Values.volumeClaimTemplates }}
|
||||
- mountPath: {{ $vct.mountPath }}
|
||||
name: {{ $vct.name }}
|
||||
{{- if $vct.subPath }}
|
||||
subPath: {{ $vct.subPath }}
|
||||
{{- end }}
|
||||
{{- end }}
|
||||
{{- end }}
|
||||
{{- end -}}
|
||||
@@ -0,0 +1,58 @@
|
||||
{{- /* The main container included in the controller */ -}}
|
||||
{{- define "bjw-s.common.lib.controller.mainContainer" -}}
|
||||
- name: {{ include "bjw-s.common.lib.chart.names.fullname" . }}
|
||||
image: {{ include "bjw-s.common.lib.container.image" . }}
|
||||
imagePullPolicy: {{ .Values.image.pullPolicy }}
|
||||
{{- with .Values.command }}
|
||||
command:
|
||||
{{- if kindIs "string" . }}
|
||||
- {{ . | quote }}
|
||||
{{- else }}
|
||||
{{ toYaml . | nindent 4 }}
|
||||
{{- end }}
|
||||
{{- end }}
|
||||
{{- with .Values.args }}
|
||||
args:
|
||||
{{- if kindIs "string" . }}
|
||||
- {{ . | quote }}
|
||||
{{- else }}
|
||||
{{ toYaml . | nindent 4 }}
|
||||
{{- end }}
|
||||
{{- end }}
|
||||
{{- with .Values.securityContext }}
|
||||
securityContext:
|
||||
{{- toYaml . | nindent 4 }}
|
||||
{{- end }}
|
||||
{{- with .Values.lifecycle }}
|
||||
lifecycle:
|
||||
{{- toYaml . | nindent 4 }}
|
||||
{{- end }}
|
||||
{{- with .Values.termination.messagePath }}
|
||||
terminationMessagePath: {{ . }}
|
||||
{{- end }}
|
||||
{{- with .Values.termination.messagePolicy }}
|
||||
terminationMessagePolicy: {{ . }}
|
||||
{{- end }}
|
||||
|
||||
{{- with .Values.env }}
|
||||
env:
|
||||
{{- get (fromYaml (include "bjw-s.common.lib.container.envVars" $)) "env" | toYaml | nindent 4 -}}
|
||||
{{- end }}
|
||||
{{- with .Values.envFrom }}
|
||||
envFrom:
|
||||
{{- toYaml . | nindent 4 }}
|
||||
{{- end }}
|
||||
{{- with (include "bjw-s.common.lib.container.ports" . | trim) }}
|
||||
ports:
|
||||
{{- nindent 4 . }}
|
||||
{{- end }}
|
||||
{{- with (include "bjw-s.common.lib.container.volumeMounts" . | trim) }}
|
||||
volumeMounts:
|
||||
{{- nindent 4 . }}
|
||||
{{- end }}
|
||||
{{- include "bjw-s.common.lib.container.probes" . | trim | nindent 2 }}
|
||||
{{- with .Values.resources }}
|
||||
resources:
|
||||
{{- toYaml . | nindent 4 }}
|
||||
{{- end }}
|
||||
{{- end -}}
|
||||
@@ -0,0 +1,25 @@
|
||||
{{- define "bjw-s.common.lib.controller.metadata.labels" -}}
|
||||
{{-
|
||||
$labels := (
|
||||
merge
|
||||
(.Values.controller.labels | default dict)
|
||||
(include "bjw-s.common.lib.metadata.allLabels" $ | fromYaml)
|
||||
)
|
||||
-}}
|
||||
{{- with $labels -}}
|
||||
{{- toYaml . -}}
|
||||
{{- end -}}
|
||||
{{- end -}}
|
||||
|
||||
{{- define "bjw-s.common.lib.controller.metadata.annotations" -}}
|
||||
{{-
|
||||
$annotations := (
|
||||
merge
|
||||
(.Values.controller.annotations | default dict)
|
||||
(include "bjw-s.common.lib.metadata.globalAnnotations" $ | fromYaml)
|
||||
)
|
||||
-}}
|
||||
{{- with $annotations -}}
|
||||
{{- toYaml . -}}
|
||||
{{- end -}}
|
||||
{{- end -}}
|
||||
@@ -0,0 +1,114 @@
|
||||
{{- /*
|
||||
The pod definition included in the controller.
|
||||
*/ -}}
|
||||
{{- define "bjw-s.common.lib.controller.pod" -}}
|
||||
{{- with .Values.imagePullSecrets }}
|
||||
imagePullSecrets:
|
||||
{{- toYaml . | nindent 2 }}
|
||||
{{- end }}
|
||||
serviceAccountName: {{ include "bjw-s.common.lib.chart.names.serviceAccountName" . }}
|
||||
automountServiceAccountToken: {{ .Values.automountServiceAccountToken }}
|
||||
{{- with .Values.podSecurityContext }}
|
||||
securityContext:
|
||||
{{- toYaml . | nindent 2 }}
|
||||
{{- end }}
|
||||
{{- with .Values.priorityClassName }}
|
||||
priorityClassName: {{ . }}
|
||||
{{- end }}
|
||||
{{- with .Values.runtimeClassName }}
|
||||
runtimeClassName: {{ . }}
|
||||
{{- end }}
|
||||
{{- with .Values.schedulerName }}
|
||||
schedulerName: {{ . }}
|
||||
{{- end }}
|
||||
{{- with .Values.hostIPC }}
|
||||
hostIPC: {{ . }}
|
||||
{{- end }}
|
||||
{{- with .Values.hostNetwork }}
|
||||
hostNetwork: {{ . }}
|
||||
{{- end }}
|
||||
{{- with .Values.hostPID }}
|
||||
hostPID: {{ . }}
|
||||
{{- end }}
|
||||
{{- with .Values.hostname }}
|
||||
hostname: {{ . }}
|
||||
{{- end }}
|
||||
{{- if .Values.dnsPolicy }}
|
||||
dnsPolicy: {{ .Values.dnsPolicy }}
|
||||
{{- else if .Values.hostNetwork }}
|
||||
dnsPolicy: ClusterFirstWithHostNet
|
||||
{{- else }}
|
||||
dnsPolicy: ClusterFirst
|
||||
{{- end }}
|
||||
{{- with .Values.dnsConfig }}
|
||||
dnsConfig:
|
||||
{{- toYaml . | nindent 2 }}
|
||||
{{- end }}
|
||||
enableServiceLinks: {{ .Values.enableServiceLinks }}
|
||||
{{- with .Values.termination.gracePeriodSeconds }}
|
||||
terminationGracePeriodSeconds: {{ . }}
|
||||
{{- end }}
|
||||
{{- if .Values.initContainers }}
|
||||
initContainers:
|
||||
{{- $initContainers := list }}
|
||||
{{- range $index, $key := (keys .Values.initContainers | uniq | sortAlpha) }}
|
||||
{{- $container := get $.Values.initContainers $key }}
|
||||
{{- if not $container.name -}}
|
||||
{{- $_ := set $container "name" $key }}
|
||||
{{- end }}
|
||||
{{- if $container.env -}}
|
||||
{{- $_ := set $ "ObjectValues" (dict "envVars" $container.env) -}}
|
||||
{{- $newEnv := fromYaml (include "bjw-s.common.lib.container.envVars" $) -}}
|
||||
{{- $_ := unset $.ObjectValues "envVars" -}}
|
||||
{{- $_ := set $container "env" $newEnv.env }}
|
||||
{{- end }}
|
||||
{{- $initContainers = append $initContainers $container }}
|
||||
{{- end }}
|
||||
{{- tpl (toYaml $initContainers) $ | nindent 2 }}
|
||||
{{- end }}
|
||||
containers:
|
||||
{{- include "bjw-s.common.lib.controller.mainContainer" . | nindent 2 }}
|
||||
{{- with (merge .Values.sidecars .Values.additionalContainers) }}
|
||||
{{- $sidecarContainers := list }}
|
||||
{{- range $name, $container := . }}
|
||||
{{- if not $container.name -}}
|
||||
{{- $_ := set $container "name" $name }}
|
||||
{{- end }}
|
||||
{{- if $container.env -}}
|
||||
{{- $_ := set $ "ObjectValues" (dict "envVars" $container.env) -}}
|
||||
{{- $newEnv := fromYaml (include "bjw-s.common.lib.container.envVars" $) -}}
|
||||
{{- $_ := set $container "env" $newEnv.env }}
|
||||
{{- $_ := unset $.ObjectValues "envVars" -}}
|
||||
{{- end }}
|
||||
{{- $sidecarContainers = append $sidecarContainers $container }}
|
||||
{{- end }}
|
||||
{{- tpl (toYaml $sidecarContainers) $ | nindent 2 }}
|
||||
{{- end }}
|
||||
{{- with (include "bjw-s.common.lib.controller.volumes" . | trim) }}
|
||||
volumes:
|
||||
{{- nindent 2 . }}
|
||||
{{- end }}
|
||||
{{- with .Values.hostAliases }}
|
||||
hostAliases:
|
||||
{{- toYaml . | nindent 2 }}
|
||||
{{- end }}
|
||||
{{- with .Values.nodeSelector }}
|
||||
nodeSelector:
|
||||
{{- toYaml . | nindent 2 }}
|
||||
{{- end }}
|
||||
{{- with .Values.affinity }}
|
||||
affinity:
|
||||
{{- toYaml . | nindent 2 }}
|
||||
{{- end }}
|
||||
{{- with .Values.topologySpreadConstraints }}
|
||||
topologySpreadConstraints:
|
||||
{{- toYaml . | nindent 2 }}
|
||||
{{- end }}
|
||||
{{- with .Values.tolerations }}
|
||||
tolerations:
|
||||
{{- toYaml . | nindent 2 }}
|
||||
{{- end }}
|
||||
{{- with .Values.controller.restartPolicy }}
|
||||
restartPolicy: {{ . }}
|
||||
{{- end }}
|
||||
{{- end -}}
|
||||
@@ -0,0 +1,68 @@
|
||||
{{/*
|
||||
Volumes included by the controller.
|
||||
*/}}
|
||||
{{- define "bjw-s.common.lib.controller.volumes" -}}
|
||||
{{- range $index, $persistence := .Values.persistence }}
|
||||
{{- if $persistence.enabled }}
|
||||
- name: {{ $index }}
|
||||
{{- if eq (default "pvc" $persistence.type) "pvc" }}
|
||||
{{- $pvcName := (include "bjw-s.common.lib.chart.names.fullname" $) -}}
|
||||
{{- if $persistence.existingClaim }}
|
||||
{{- /* Always prefer an existingClaim if that is set */}}
|
||||
{{- $pvcName = $persistence.existingClaim -}}
|
||||
{{- else -}}
|
||||
{{- /* Otherwise refer to the PVC name */}}
|
||||
{{- if $persistence.nameOverride -}}
|
||||
{{- if not (eq $persistence.nameOverride "-") -}}
|
||||
{{- $pvcName = (printf "%s-%s" (include "bjw-s.common.lib.chart.names.fullname" $) $persistence.nameOverride) -}}
|
||||
{{- end -}}
|
||||
{{- else -}}
|
||||
{{- $pvcName = (printf "%s-%s" (include "bjw-s.common.lib.chart.names.fullname" $) $index) -}}
|
||||
{{- end -}}
|
||||
{{- end }}
|
||||
persistentVolumeClaim:
|
||||
claimName: {{ $pvcName }}
|
||||
{{- else if or (eq $persistence.type "configMap") (eq $persistence.type "secret") }}
|
||||
{{- $objectName := (required (printf "name not set for persistence item %s" $index) $persistence.name) }}
|
||||
{{- $objectName = tpl $objectName $ }}
|
||||
{{- if eq $persistence.type "configMap" }}
|
||||
configMap:
|
||||
name: {{ $objectName }}
|
||||
{{- else }}
|
||||
secret:
|
||||
secretName: {{ $objectName }}
|
||||
{{- end }}
|
||||
{{- with $persistence.defaultMode }}
|
||||
defaultMode: {{ . }}
|
||||
{{- end }}
|
||||
{{- with $persistence.items }}
|
||||
items:
|
||||
{{- toYaml . | nindent 6 }}
|
||||
{{- end }}
|
||||
{{- else if eq $persistence.type "emptyDir" }}
|
||||
{{- $emptyDir := dict -}}
|
||||
{{- with $persistence.medium -}}
|
||||
{{- $_ := set $emptyDir "medium" . -}}
|
||||
{{- end -}}
|
||||
{{- with $persistence.sizeLimit -}}
|
||||
{{- $_ := set $emptyDir "sizeLimit" . -}}
|
||||
{{- end }}
|
||||
emptyDir: {{- $emptyDir | toYaml | nindent 4 }}
|
||||
{{- else if eq $persistence.type "hostPath" }}
|
||||
hostPath:
|
||||
path: {{ required "hostPath not set" $persistence.hostPath }}
|
||||
{{- with $persistence.hostPathType }}
|
||||
type: {{ . }}
|
||||
{{- end }}
|
||||
{{- else if eq $persistence.type "nfs" }}
|
||||
nfs:
|
||||
server: {{ required "server not set" $persistence.server }}
|
||||
path: {{ required "path not set" $persistence.path }}
|
||||
{{- else if eq $persistence.type "custom" }}
|
||||
{{- toYaml $persistence.volumeSpec | nindent 2 }}
|
||||
{{- else }}
|
||||
{{- fail (printf "Not a valid persistence.type (%s)" $persistence.type) }}
|
||||
{{- end }}
|
||||
{{- end }}
|
||||
{{- end }}
|
||||
{{- end }}
|
||||
@@ -0,0 +1,21 @@
|
||||
{{/* Return the name of the primary ingress object */}}
|
||||
{{- define "bjw-s.common.lib.ingress.primary" -}}
|
||||
{{- $enabledIngresses := dict -}}
|
||||
{{- range $name, $ingress := .Values.ingress -}}
|
||||
{{- if $ingress.enabled -}}
|
||||
{{- $_ := set $enabledIngresses $name . -}}
|
||||
{{- end -}}
|
||||
{{- end -}}
|
||||
|
||||
{{- $result := "" -}}
|
||||
{{- range $name, $ingress := $enabledIngresses -}}
|
||||
{{- if and (hasKey $ingress "primary") $ingress.primary -}}
|
||||
{{- $result = $name -}}
|
||||
{{- end -}}
|
||||
{{- end -}}
|
||||
|
||||
{{- if not $result -}}
|
||||
{{- $result = keys $enabledIngresses | first -}}
|
||||
{{- end -}}
|
||||
{{- $result -}}
|
||||
{{- end -}}
|
||||
@@ -0,0 +1,10 @@
|
||||
{{/* Common labels shared across objects */}}
|
||||
{{- define "bjw-s.common.lib.metadata.allLabels" -}}
|
||||
helm.sh/chart: {{ include "bjw-s.common.lib.chart.names.chart" . }}
|
||||
{{ include "bjw-s.common.lib.metadata.selectorLabels" . }}
|
||||
{{- if .Chart.AppVersion }}
|
||||
app.kubernetes.io/version: {{ .Chart.AppVersion | quote }}
|
||||
{{- end }}
|
||||
app.kubernetes.io/managed-by: {{ .Release.Service }}
|
||||
{{ include "bjw-s.common.lib.metadata.globalLabels" . }}
|
||||
{{- end -}}
|
||||
@@ -0,0 +1,10 @@
|
||||
{{/* Common annotations shared across objects */}}
|
||||
{{- define "bjw-s.common.lib.metadata.globalAnnotations" -}}
|
||||
{{- with .Values.global.annotations }}
|
||||
{{- range $k, $v := . }}
|
||||
{{- $name := $k }}
|
||||
{{- $value := tpl $v $ }}
|
||||
{{ $name }}: {{ quote $value }}
|
||||
{{- end }}
|
||||
{{- end }}
|
||||
{{- end -}}
|
||||
@@ -0,0 +1,9 @@
|
||||
{{- define "bjw-s.common.lib.metadata.globalLabels" -}}
|
||||
{{- with .Values.global.labels }}
|
||||
{{- range $k, $v := . }}
|
||||
{{- $name := $k }}
|
||||
{{- $value := tpl $v $ }}
|
||||
{{ $name }}: {{ quote $value }}
|
||||
{{- end }}
|
||||
{{- end }}
|
||||
{{- end -}}
|
||||
@@ -0,0 +1,26 @@
|
||||
{{/* Determine the Pod annotations used in the controller */}}
|
||||
{{- define "bjw-s.common.lib.metadata.podAnnotations" -}}
|
||||
{{- if .Values.podAnnotations -}}
|
||||
{{- tpl (toYaml .Values.podAnnotations) . | nindent 0 -}}
|
||||
{{- end -}}
|
||||
|
||||
{{- $configMapsFound := dict -}}
|
||||
{{- range $name, $configmap := .Values.configMaps -}}
|
||||
{{- if $configmap.enabled -}}
|
||||
{{- $_ := set $configMapsFound $name (toYaml $configmap.data | sha256sum) -}}
|
||||
{{- end -}}
|
||||
{{- end -}}
|
||||
{{- if $configMapsFound -}}
|
||||
{{- printf "checksum/config: %v" (toYaml $configMapsFound | sha256sum) | nindent 0 -}}
|
||||
{{- end -}}
|
||||
|
||||
{{- $secretsFound := dict -}}
|
||||
{{- range $name, $secret := .Values.secrets -}}
|
||||
{{- if $secret.enabled -}}
|
||||
{{- $_ := set $secretsFound $name (toYaml $secret.data | sha256sum) -}}
|
||||
{{- end -}}
|
||||
{{- end -}}
|
||||
{{- if $secretsFound -}}
|
||||
{{- printf "checksum/secrets: %v" (toYaml $secretsFound | sha256sum) | nindent 0 -}}
|
||||
{{- end -}}
|
||||
{{- end -}}
|
||||
@@ -0,0 +1,5 @@
|
||||
{{/* Selector labels shared across objects */}}
|
||||
{{- define "bjw-s.common.lib.metadata.selectorLabels" -}}
|
||||
app.kubernetes.io/name: {{ include "bjw-s.common.lib.chart.names.name" . }}
|
||||
app.kubernetes.io/instance: {{ .Release.Name }}
|
||||
{{- end -}}
|
||||
@@ -0,0 +1,21 @@
|
||||
{{/* Return the name of the primary route object */}}
|
||||
{{- define "bjw-s.common.lib.route.primary" -}}
|
||||
{{- $enabledRoutes := dict -}}
|
||||
{{- range $name, $route := .Values.route -}}
|
||||
{{- if $route.enabled -}}
|
||||
{{- $_ := set $enabledRoutes $name . -}}
|
||||
{{- end -}}
|
||||
{{- end -}}
|
||||
|
||||
{{- $result := "" -}}
|
||||
{{- range $name, $route := $enabledRoutes -}}
|
||||
{{- if and (hasKey $route "primary") $route.primary -}}
|
||||
{{- $result = $name -}}
|
||||
{{- end -}}
|
||||
{{- end -}}
|
||||
|
||||
{{- if not $result -}}
|
||||
{{- $result = keys $enabledRoutes | first -}}
|
||||
{{- end -}}
|
||||
{{- $result -}}
|
||||
{{- end -}}
|
||||
@@ -0,0 +1,19 @@
|
||||
{{/*
|
||||
Return the enabled ports for a given Service object.
|
||||
*/}}
|
||||
{{- define "bjw-s.common.lib.service.enabledPorts" -}}
|
||||
{{- $enabledPorts := dict -}}
|
||||
|
||||
{{- range $name, $port := .values.ports -}}
|
||||
{{- if kindIs "map" $port -}}
|
||||
{{- $portEnabled := true -}}
|
||||
{{- if hasKey $port "enabled" -}}
|
||||
{{- $portEnabled = $port.enabled -}}
|
||||
{{- end -}}
|
||||
{{- if $portEnabled -}}
|
||||
{{- $_ := set $enabledPorts $name . -}}
|
||||
{{- end -}}
|
||||
{{- end -}}
|
||||
{{- end -}}
|
||||
{{- $enabledPorts | toYaml -}}
|
||||
{{- end -}}
|
||||
@@ -0,0 +1,18 @@
|
||||
{{/*
|
||||
Return the enabled services.
|
||||
*/}}
|
||||
{{- define "bjw-s.common.lib.service.enabledServices" -}}
|
||||
{{- $enabledServices := dict -}}
|
||||
{{- range $name, $service := .Values.service -}}
|
||||
{{- if kindIs "map" $service -}}
|
||||
{{- $serviceEnabled := true -}}
|
||||
{{- if hasKey $service "enabled" -}}
|
||||
{{- $serviceEnabled = $service.enabled -}}
|
||||
{{- end -}}
|
||||
{{- if $serviceEnabled -}}
|
||||
{{- $_ := set $enabledServices $name . -}}
|
||||
{{- end -}}
|
||||
{{- end -}}
|
||||
{{- end -}}
|
||||
{{- $enabledServices | toYaml -}}
|
||||
{{- end -}}
|
||||
@@ -0,0 +1,18 @@
|
||||
{{/*
|
||||
Return the primary service object
|
||||
*/}}
|
||||
{{- define "bjw-s.common.lib.service.primary" -}}
|
||||
{{- $enabledServices := (include "bjw-s.common.lib.service.enabledServices" $ | fromYaml ) }}
|
||||
|
||||
{{- $result := "" -}}
|
||||
{{- range $name, $service := $enabledServices -}}
|
||||
{{- if and (hasKey $service "primary") $service.primary -}}
|
||||
{{- $result = $name -}}
|
||||
{{- end -}}
|
||||
{{- end -}}
|
||||
|
||||
{{- if not $result -}}
|
||||
{{- $result = keys $enabledServices | first -}}
|
||||
{{- end -}}
|
||||
{{- $result -}}
|
||||
{{- end -}}
|
||||
@@ -0,0 +1,18 @@
|
||||
{{/*
|
||||
Return the primary port for a given Service object.
|
||||
*/}}
|
||||
{{- define "bjw-s.common.lib.service.primaryPort" -}}
|
||||
{{- $enabledPorts := (include "bjw-s.common.lib.service.enabledPorts" . | fromYaml) }}
|
||||
|
||||
{{- $result := "" -}}
|
||||
{{- range $name, $port := $enabledPorts -}}
|
||||
{{- if and (hasKey $port "primary") $port.primary -}}
|
||||
{{- $result = $name -}}
|
||||
{{- end -}}
|
||||
{{- end -}}
|
||||
|
||||
{{- if not $result -}}
|
||||
{{- $result = keys $enabledPorts | first -}}
|
||||
{{- end -}}
|
||||
{{- $result -}}
|
||||
{{- end -}}
|
||||
10
charts/paperless-ngx/charts/common/templates/loader/_all.tpl
Normal file
10
charts/paperless-ngx/charts/common/templates/loader/_all.tpl
Normal file
@@ -0,0 +1,10 @@
|
||||
{{/*
|
||||
Main entrypoint for the common library chart. It will render all underlying templates based on the provided values.
|
||||
*/}}
|
||||
{{- define "bjw-s.common.loader.all" -}}
|
||||
{{- /* Generate chart and dependency values */ -}}
|
||||
{{- include "bjw-s.common.loader.init" . -}}
|
||||
|
||||
{{- /* Generate remaining objects */ -}}
|
||||
{{- include "bjw-s.common.loader.generate" . -}}
|
||||
{{- end -}}
|
||||
@@ -0,0 +1,30 @@
|
||||
{{/*
|
||||
Secondary entrypoint and primary loader for the common chart
|
||||
*/}}
|
||||
{{- define "bjw-s.common.loader.generate" -}}
|
||||
{{- /* Enable code-server add-on if required */ -}}
|
||||
{{- if .Values.addons.codeserver.enabled -}}
|
||||
{{- include "bjw-s.common.addon.codeserver" . | nindent 0 -}}
|
||||
{{- end -}}
|
||||
|
||||
{{- /* Enable VPN add-on if required */ -}}
|
||||
{{- if .Values.addons.vpn.enabled -}}
|
||||
{{- include "bjw-s.common.addon.vpn" . | nindent 0 -}}
|
||||
{{- end -}}
|
||||
|
||||
{{- /* Enable netshoot add-on if required */ -}}
|
||||
{{- if .Values.addons.netshoot.enabled -}}
|
||||
{{- include "bjw-s.common.addon.netshoot" . | nindent 0 -}}
|
||||
{{- end -}}
|
||||
|
||||
{{- /* Build the templates */ -}}
|
||||
{{- include "bjw-s.common.render.pvcs" . | nindent 0 -}}
|
||||
{{- include "bjw-s.common.render.serviceAccount" . | nindent 0 -}}
|
||||
{{- include "bjw-s.common.render.controller" . | nindent 0 -}}
|
||||
{{- include "bjw-s.common.render.services" . | nindent 0 -}}
|
||||
{{- include "bjw-s.common.render.ingresses" . | nindent 0 -}}
|
||||
{{- include "bjw-s.common.render.serviceMonitors" . | nindent 0 -}}
|
||||
{{- include "bjw-s.common.render.routes" . | nindent 0 -}}
|
||||
{{- include "bjw-s.common.render.configmaps" . | nindent 0 -}}
|
||||
{{- include "bjw-s.common.render.secrets" . | nindent 0 -}}
|
||||
{{- end -}}
|
||||
@@ -0,0 +1,4 @@
|
||||
{{- define "bjw-s.common.loader.init" -}}
|
||||
{{- /* Merge the local chart values and the common chart defaults */ -}}
|
||||
{{- include "bjw-s.common.values.init" . }}
|
||||
{{- end -}}
|
||||
@@ -0,0 +1,19 @@
|
||||
{{/*
|
||||
Renders the configMap objects required by the chart.
|
||||
*/}}
|
||||
{{- define "bjw-s.common.render.configmaps" -}}
|
||||
{{- /* Generate named configMaps as required */ -}}
|
||||
{{- range $name, $configmap := .Values.configMaps -}}
|
||||
{{- if $configmap.enabled -}}
|
||||
{{- $configmapValues := $configmap -}}
|
||||
|
||||
{{- /* set the default nameOverride to the configMap name */ -}}
|
||||
{{- if not $configmapValues.nameOverride -}}
|
||||
{{- $_ := set $configmapValues "nameOverride" $name -}}
|
||||
{{ end -}}
|
||||
|
||||
{{- $_ := set $ "ObjectValues" (dict "configmap" $configmapValues) -}}
|
||||
{{- include "bjw-s.common.class.configmap" $ | nindent 0 -}}
|
||||
{{- end -}}
|
||||
{{- end -}}
|
||||
{{- end -}}
|
||||
@@ -0,0 +1,18 @@
|
||||
{{/*
|
||||
Renders the controller object required by the chart.
|
||||
*/}}
|
||||
{{- define "bjw-s.common.render.controller" -}}
|
||||
{{- if .Values.controller.enabled -}}
|
||||
{{- if eq .Values.controller.type "deployment" -}}
|
||||
{{- include "bjw-s.common.class.deployment" . | nindent 0 -}}
|
||||
{{- else if eq .Values.controller.type "cronjob" -}}
|
||||
{{- include "bjw-s.common.class.cronjob" . | nindent 0 -}}
|
||||
{{ else if eq .Values.controller.type "daemonset" -}}
|
||||
{{- include "bjw-s.common.class.daemonset" . | nindent 0 -}}
|
||||
{{ else if eq .Values.controller.type "statefulset" -}}
|
||||
{{- include "bjw-s.common.class.statefulset" . | nindent 0 -}}
|
||||
{{ else -}}
|
||||
{{- fail (printf "Not a valid controller.type (%s)" .Values.controller.type) -}}
|
||||
{{- end -}}
|
||||
{{- end -}}
|
||||
{{- end -}}
|
||||
@@ -0,0 +1,19 @@
|
||||
{{/*
|
||||
Renders the Ingress objects required by the chart.
|
||||
*/}}
|
||||
{{- define "bjw-s.common.render.ingresses" -}}
|
||||
{{- /* Generate named ingresses as required */ -}}
|
||||
{{- range $name, $ingress := .Values.ingress }}
|
||||
{{- if $ingress.enabled -}}
|
||||
{{- $ingressValues := $ingress -}}
|
||||
|
||||
{{/* set defaults */}}
|
||||
{{- if and (not $ingressValues.nameOverride) (ne $name (include "bjw-s.common.lib.ingress.primary" $)) -}}
|
||||
{{- $_ := set $ingressValues "nameOverride" $name -}}
|
||||
{{- end -}}
|
||||
|
||||
{{- $_ := set $ "ObjectValues" (dict "ingress" $ingressValues) -}}
|
||||
{{- include "bjw-s.common.class.ingress" $ | nindent 0 -}}
|
||||
{{- end -}}
|
||||
{{- end -}}
|
||||
{{- end -}}
|
||||
@@ -0,0 +1,16 @@
|
||||
{{/*
|
||||
Renders the Persistent Volume Claim objects required by the chart.
|
||||
*/}}
|
||||
{{- define "bjw-s.common.render.pvcs" -}}
|
||||
{{- /* Generate pvc as required */ -}}
|
||||
{{- range $index, $PVC := .Values.persistence -}}
|
||||
{{- if and $PVC.enabled (eq (default "pvc" $PVC.type) "pvc") (not $PVC.existingClaim) -}}
|
||||
{{- $persistenceValues := $PVC -}}
|
||||
{{- if not $persistenceValues.nameOverride -}}
|
||||
{{- $_ := set $persistenceValues "nameOverride" $index -}}
|
||||
{{- end -}}
|
||||
{{- $_ := set $ "ObjectValues" (dict "persistence" $persistenceValues) -}}
|
||||
{{- include "bjw-s.common.class.pvc" $ | nindent 0 -}}
|
||||
{{- end -}}
|
||||
{{- end -}}
|
||||
{{- end -}}
|
||||
@@ -0,0 +1,18 @@
|
||||
{{/* Renders the Route objects required by the chart */}}
|
||||
{{- define "bjw-s.common.render.routes" -}}
|
||||
{{- /* Generate named routes as required */ -}}
|
||||
{{- range $name, $route := .Values.route }}
|
||||
{{- if $route.enabled -}}
|
||||
{{- $routeValues := $route -}}
|
||||
|
||||
{{/* set defaults */}}
|
||||
{{- if and (not $routeValues.nameOverride) (ne $name (include "bjw-s.common.lib.route.primary" $)) -}}
|
||||
{{- $_ := set $routeValues "nameOverride" $name -}}
|
||||
{{- end -}}
|
||||
|
||||
{{- $_ := set $ "ObjectValues" (dict "route" $routeValues) -}}
|
||||
{{- include "bjw-s.common.class.route" $ | nindent 0 -}}
|
||||
{{- $_ := unset $.ObjectValues "route" -}}
|
||||
{{- end }}
|
||||
{{- end }}
|
||||
{{- end }}
|
||||
@@ -0,0 +1,19 @@
|
||||
{{/*
|
||||
Renders the Secret objects required by the chart.
|
||||
*/}}
|
||||
{{- define "bjw-s.common.render.secrets" -}}
|
||||
{{- /* Generate named Secrets as required */ -}}
|
||||
{{- range $name, $secret := .Values.secrets -}}
|
||||
{{- if $secret.enabled -}}
|
||||
{{- $secretValues := $secret -}}
|
||||
|
||||
{{- /* set the default nameOverride to the Secret name */ -}}
|
||||
{{- if not $secretValues.nameOverride -}}
|
||||
{{- $_ := set $secretValues "nameOverride" $name -}}
|
||||
{{ end -}}
|
||||
|
||||
{{- $_ := set $ "ObjectValues" (dict "secret" $secretValues) -}}
|
||||
{{- include "bjw-s.common.class.secret" $ | nindent 0 -}}
|
||||
{{- end -}}
|
||||
{{- end -}}
|
||||
{{- end -}}
|
||||
@@ -0,0 +1,20 @@
|
||||
{{/*
|
||||
Renders the serviceMonitor objects required by the chart.
|
||||
*/}}
|
||||
{{- define "bjw-s.common.render.serviceMonitors" -}}
|
||||
{{- /* Generate named services as required */ -}}
|
||||
{{- range $name, $serviceMonitor := .Values.serviceMonitor -}}
|
||||
{{- if $serviceMonitor.enabled -}}
|
||||
{{- $serviceMonitorValues := $serviceMonitor -}}
|
||||
|
||||
{{- if and (not $serviceMonitorValues.nameOverride) (ne $name "main") -}}
|
||||
{{- $_ := set $serviceMonitorValues "nameOverride" $name -}}
|
||||
{{- end -}}
|
||||
|
||||
{{/* Include the serviceMonitor class */}}
|
||||
{{- $_ := set $ "ObjectValues" (dict "serviceMonitor" $serviceMonitorValues) -}}
|
||||
{{- include "bjw-s.common.class.serviceMonitor" $ | nindent 0 -}}
|
||||
{{- $_ := unset $.ObjectValues "serviceMonitor" -}}
|
||||
{{- end -}}
|
||||
{{- end -}}
|
||||
{{- end -}}
|
||||
@@ -0,0 +1,13 @@
|
||||
{{/*
|
||||
Renders the serviceAccount object required by the chart.
|
||||
*/}}
|
||||
{{- define "bjw-s.common.render.serviceAccount" -}}
|
||||
{{- if .Values.serviceAccount.create -}}
|
||||
|
||||
{{- /* Create a service account secret */ -}}
|
||||
{{- $serviceAccountName := include "bjw-s.common.lib.chart.names.serviceAccountName" . -}}
|
||||
{{- $_ := set .Values.secrets "sa-token" (dict "enabled" true "annotations" (dict "kubernetes.io/service-account.name" $serviceAccountName) "type" "kubernetes.io/service-account-token") -}}
|
||||
|
||||
{{- include "bjw-s.common.class.serviceAccount" $ | nindent 0 -}}
|
||||
{{- end -}}
|
||||
{{- end -}}
|
||||
@@ -0,0 +1,25 @@
|
||||
{{/*
|
||||
Renders the Service objects required by the chart.
|
||||
*/}}
|
||||
{{- define "bjw-s.common.render.services" -}}
|
||||
{{- /* Generate named services as required */ -}}
|
||||
{{- range $name, $service := .Values.service -}}
|
||||
{{- $serviceEnabled := true -}}
|
||||
{{- if hasKey $service "enabled" -}}
|
||||
{{- $serviceEnabled = $service.enabled -}}
|
||||
{{- end -}}
|
||||
{{- if $serviceEnabled -}}
|
||||
{{- $serviceValues := $service -}}
|
||||
|
||||
{{/* set the default nameOverride to the service name */}}
|
||||
{{- if and (not $serviceValues.nameOverride) (ne $name (include "bjw-s.common.lib.service.primary" $)) -}}
|
||||
{{- $_ := set $serviceValues "nameOverride" $name -}}
|
||||
{{ end -}}
|
||||
|
||||
{{/* Include the Service class */}}
|
||||
{{- $_ := set $ "ObjectValues" (dict "service" $serviceValues) -}}
|
||||
{{- include "bjw-s.common.class.service" $ | nindent 0 -}}
|
||||
{{- $_ := unset $.ObjectValues "service" -}}
|
||||
{{- end -}}
|
||||
{{- end -}}
|
||||
{{- end -}}
|
||||
@@ -0,0 +1,12 @@
|
||||
{{/*
|
||||
Merge the local chart values and the common chart defaults
|
||||
*/}}
|
||||
{{- define "bjw-s.common.values.init" -}}
|
||||
{{- if .Values.common -}}
|
||||
{{- $defaultValues := deepCopy .Values.common -}}
|
||||
{{- $userValues := deepCopy (omit .Values "common") -}}
|
||||
{{- $_ := set $defaultValues "additionalContainers" dict -}}
|
||||
{{- $mergedValues := mustMergeOverwrite $defaultValues $userValues -}}
|
||||
{{- $_ := set . "Values" (deepCopy $mergedValues) -}}
|
||||
{{- end -}}
|
||||
{{- end -}}
|
||||
840
charts/paperless-ngx/charts/common/values.yaml
Normal file
840
charts/paperless-ngx/charts/common/values.yaml
Normal file
@@ -0,0 +1,840 @@
|
||||
---
|
||||
global:
|
||||
# -- Set an override for the prefix of the fullname
|
||||
nameOverride:
|
||||
# -- Set the entire name definition
|
||||
fullnameOverride:
|
||||
# -- Set additional global labels. Helm templates can be used.
|
||||
labels: {}
|
||||
# -- Set additional global annotations. Helm templates can be used.
|
||||
annotations: {}
|
||||
|
||||
controller:
|
||||
# -- enable the controller.
|
||||
enabled: true
|
||||
# -- Set the controller type.
|
||||
# Valid options are deployment, daemonset, statefulset or cronjob
|
||||
type: deployment
|
||||
# -- Set annotations on the deployment/statefulset/daemonset/cronjob
|
||||
annotations: {}
|
||||
# -- Set labels on the deployment/statefulset/daemonset/cronjob
|
||||
labels: {}
|
||||
# -- Number of desired pods. When using a HorizontalPodAutoscaler, set this to `null`.
|
||||
replicas: 1
|
||||
# -- Set the controller upgrade strategy
|
||||
# For Deployments, valid values are Recreate (default) and RollingUpdate.
|
||||
# For StatefulSets, valid values are OnDelete and RollingUpdate (default).
|
||||
# DaemonSets/CronJobs ignore this.
|
||||
strategy:
|
||||
rollingUpdate:
|
||||
# -- Set deployment RollingUpdate max unavailable
|
||||
unavailable:
|
||||
# -- Set deployment RollingUpdate max surge
|
||||
surge:
|
||||
# -- Set statefulset RollingUpdate partition
|
||||
partition:
|
||||
# -- ReplicaSet revision history limit
|
||||
revisionHistoryLimit: 3
|
||||
# -- Set statefulset podManagementPolicy, valid values are Parallel and OrderedReady (default).
|
||||
podManagementPolicy:
|
||||
# -- Set Container restart policy.
|
||||
# @default -- `Always`. When `controller.type` is `cronjob` it defaults to `Never`.
|
||||
restartPolicy:
|
||||
# -- CronJob configuration. Required only when using `controller.type: cronjob`.
|
||||
# @default -- See below
|
||||
cronjob:
|
||||
# -- Specifies how to treat concurrent executions of a job that is created by this cron job
|
||||
# valid values are Allow, Forbid or Replace
|
||||
concurrencyPolicy: Forbid
|
||||
# -- Sets the CronJob time when to execute your jobs
|
||||
schedule: "*/20 * * * *"
|
||||
# -- The deadline in seconds for starting the job if it misses its scheduled time for any reason
|
||||
startingDeadlineSeconds: 30
|
||||
# -- The number of succesful Jobs to keep
|
||||
successfulJobsHistory: 1
|
||||
# -- The number of failed Jobs to keep
|
||||
failedJobsHistory: 1
|
||||
# -- If this field is set, ttlSecondsAfterFinished after the Job finishes, it is eligible to
|
||||
# be automatically deleted.
|
||||
ttlSecondsAfterFinished:
|
||||
# -- Limits the number of times a failed job will be retried
|
||||
backoffLimit: 6
|
||||
|
||||
image:
|
||||
# -- image repository
|
||||
repository:
|
||||
# -- image tag
|
||||
tag:
|
||||
# -- image pull policy
|
||||
pullPolicy:
|
||||
|
||||
# -- Set image pull secrets
|
||||
imagePullSecrets: []
|
||||
|
||||
# -- Override the command(s) for the default container
|
||||
command: []
|
||||
# -- Override the args for the default container
|
||||
args: []
|
||||
|
||||
# -- Set annotations on the pod
|
||||
podAnnotations: {}
|
||||
|
||||
# -- Set labels on the pod
|
||||
podLabels: {}
|
||||
|
||||
serviceAccount:
|
||||
# -- Specifies whether a service account should be created
|
||||
create: false
|
||||
|
||||
# -- Annotations to add to the service account
|
||||
annotations: {}
|
||||
|
||||
# -- The name of the service account to use.
|
||||
# If not set and create is true, a name is generated using the fullname template
|
||||
name: ""
|
||||
|
||||
# -- Specifies whether a service account token should be automatically mounted.
|
||||
automountServiceAccountToken: true
|
||||
|
||||
# -- Use this to populate secrets with the values you specify.
|
||||
# Be aware that these values are not encrypted by default, and could therefore visible
|
||||
# to anybody with access to the values.yaml file.
|
||||
# Additional Secrets can be added by adding a dictionary key similar to the 'secret' object.
|
||||
# @default -- See below
|
||||
secrets:
|
||||
secret:
|
||||
# -- Enables or disables the Secret
|
||||
enabled: false
|
||||
# -- Labels to add to the Secret
|
||||
labels: {}
|
||||
# -- Annotations to add to the Secret
|
||||
annotations: {}
|
||||
# -- Secret stringData content. Helm template enabled.
|
||||
stringData:
|
||||
{}
|
||||
# foo: bar
|
||||
|
||||
# -- Configure configMaps for the chart here.
|
||||
# Additional configMaps can be added by adding a dictionary key similar to the 'config' object.
|
||||
# @default -- See below
|
||||
configMaps:
|
||||
config:
|
||||
# -- Enables or disables the configMap
|
||||
enabled: false
|
||||
# -- Labels to add to the configMap
|
||||
labels: {}
|
||||
# -- Annotations to add to the configMap
|
||||
annotations: {}
|
||||
# -- configMap data content. Helm template enabled.
|
||||
data:
|
||||
{}
|
||||
# foo: bar
|
||||
|
||||
# -- Main environment variables. Template enabled.
|
||||
# Syntax options:
|
||||
# A) TZ: UTC
|
||||
# B) PASSWD: '{{ .Release.Name }}'
|
||||
# C) PASSWD:
|
||||
# configMapKeyRef:
|
||||
# name: config-map-name
|
||||
# key: key-name
|
||||
# D) PASSWD:
|
||||
# valueFrom:
|
||||
# secretKeyRef:
|
||||
# name: secret-name
|
||||
# key: key-name
|
||||
# ...
|
||||
# E) - name: TZ
|
||||
# value: UTC
|
||||
# F) - name: TZ
|
||||
# value: '{{ .Release.Name }}'
|
||||
env:
|
||||
|
||||
# -- Secrets and/or ConfigMaps that will be loaded as environment variables.
|
||||
# [[ref]](https://unofficial-kubernetes.readthedocs.io/en/latest/tasks/configure-pod-container/configmap/#use-case-consume-configmap-in-environment-variables)
|
||||
envFrom: []
|
||||
# - configMapRef:
|
||||
# name: config-map-name
|
||||
# - secretRef:
|
||||
# name: secret-name
|
||||
|
||||
# -- Custom priority class for different treatment by the scheduler
|
||||
priorityClassName: # system-node-critical
|
||||
|
||||
# -- Allow specifying a runtimeClassName other than the default one (ie: nvidia)
|
||||
runtimeClassName: # nvidia
|
||||
|
||||
# -- Allows specifying a custom scheduler name
|
||||
schedulerName: # awkward-dangerous-scheduler
|
||||
|
||||
# -- Allows specifying explicit hostname setting
|
||||
hostname:
|
||||
|
||||
# -- Use the host's ipc namespace
|
||||
hostIPC: false
|
||||
|
||||
# -- When using hostNetwork make sure you set dnsPolicy to `ClusterFirstWithHostNet`
|
||||
hostNetwork: false
|
||||
|
||||
# -- Use the host's pid namespace
|
||||
hostPID: false
|
||||
|
||||
# -- Defaults to "ClusterFirst" if hostNetwork is false
|
||||
# and "ClusterFirstWithHostNet" if hostNetwork is true.
|
||||
dnsPolicy: # ClusterFirst
|
||||
|
||||
# -- Configuring the ndots option may resolve nslookup issues on some Kubernetes setups.
|
||||
dnsConfig: {}
|
||||
# options:
|
||||
# - name: ndots
|
||||
# value: "1"
|
||||
|
||||
# -- Enable/disable the generation of environment variables for services.
|
||||
# [[ref]](https://kubernetes.io/docs/concepts/services-networking/connect-applications-service/#accessing-the-service)
|
||||
enableServiceLinks: true
|
||||
|
||||
# -- Configure the Security Context for the Pod
|
||||
podSecurityContext: {}
|
||||
|
||||
# -- Configure the Security Context for the main container
|
||||
securityContext: {}
|
||||
|
||||
# -- Configure the lifecycle for the main container
|
||||
lifecycle: {}
|
||||
|
||||
# -- Specify any initContainers here as dictionary items.
|
||||
# Each initContainer should have its own key. The dictionary item key will determine the order.
|
||||
# Helm templates can be used.
|
||||
initContainers: {}
|
||||
|
||||
# -- Specify any sidecar containers here as dictionary items.
|
||||
# Each sidecar container should have its own key. The dictionary item key will determine the order.
|
||||
# Helm templates can be used.
|
||||
sidecars: {}
|
||||
|
||||
# -- Probe configuration
|
||||
# -- [[ref]](https://kubernetes.io/docs/tasks/configure-pod-container/configure-liveness-readiness-startup-probes/)
|
||||
# @default -- See below
|
||||
probes:
|
||||
# -- Liveness probe configuration
|
||||
# @default -- See below
|
||||
liveness:
|
||||
# -- Enable the liveness probe
|
||||
enabled: true
|
||||
# -- Set this to `true` if you wish to specify your own livenessProbe
|
||||
custom: false
|
||||
# -- sets the probe type when not using a custom probe
|
||||
# @default -- "TCP"
|
||||
type: TCP
|
||||
# -- 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
|
||||
spec:
|
||||
initialDelaySeconds: 0
|
||||
periodSeconds: 10
|
||||
timeoutSeconds: 1
|
||||
failureThreshold: 3
|
||||
|
||||
# -- Redainess probe configuration
|
||||
# @default -- See below
|
||||
readiness:
|
||||
# -- Enable the readiness probe
|
||||
enabled: true
|
||||
# -- Set this to `true` if you wish to specify your own readinessProbe
|
||||
custom: false
|
||||
# -- sets the probe type when not using a custom probe
|
||||
# @default -- "TCP"
|
||||
type: TCP
|
||||
# -- 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
|
||||
spec:
|
||||
initialDelaySeconds: 0
|
||||
periodSeconds: 10
|
||||
timeoutSeconds: 1
|
||||
failureThreshold: 3
|
||||
|
||||
# -- Startup probe configuration
|
||||
# @default -- See below
|
||||
startup:
|
||||
# -- Enable the startup probe
|
||||
enabled: true
|
||||
# -- Set this to `true` if you wish to specify your own startupProbe
|
||||
custom: false
|
||||
# -- sets the probe type when not using a custom probe
|
||||
# @default -- "TCP"
|
||||
type: TCP
|
||||
# -- 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
|
||||
spec:
|
||||
initialDelaySeconds: 0
|
||||
timeoutSeconds: 1
|
||||
## This means it has a maximum of 5*30=150 seconds to start up before it fails
|
||||
periodSeconds: 5
|
||||
failureThreshold: 30
|
||||
|
||||
termination:
|
||||
# -- Configure the path at which the file to which the main container's termination message will be written.
|
||||
# -- [[ref](https://kubernetes.io/docs/reference/kubernetes-api/workload-resources/pod-v1/#lifecycle-1)]
|
||||
messagePath:
|
||||
|
||||
# -- Indicate how the main container's termination message should be populated.
|
||||
# Valid options are `File` and `FallbackToLogsOnError`.
|
||||
# -- [[ref](https://kubernetes.io/docs/reference/kubernetes-api/workload-resources/pod-v1/#lifecycle-1)]
|
||||
messagePolicy:
|
||||
|
||||
# -- Duration in seconds the pod needs to terminate gracefully
|
||||
# -- [[ref](https://kubernetes.io/docs/reference/kubernetes-api/workload-resources/pod-v1/#lifecycle)]
|
||||
gracePeriodSeconds:
|
||||
|
||||
# -- Configure the services for the chart here.
|
||||
# Additional services can be added by adding a dictionary key similar to the 'main' service.
|
||||
# @default -- See below
|
||||
service:
|
||||
main:
|
||||
# -- Enables or disables the service
|
||||
enabled: true
|
||||
|
||||
# -- Make this the primary service (used in probes, notes, etc...).
|
||||
# If there is more than 1 service, make sure that only 1 service is marked as primary.
|
||||
primary: true
|
||||
|
||||
# -- Override the name suffix that is used for this service
|
||||
nameOverride:
|
||||
|
||||
# -- Set the service type
|
||||
type: ClusterIP
|
||||
|
||||
# -- Specify the externalTrafficPolicy for the service. Options: Cluster, Local
|
||||
# -- [[ref](https://kubernetes.io/docs/tutorials/services/source-ip/)]
|
||||
externalTrafficPolicy:
|
||||
|
||||
# -- Specify the ip policy. Options: SingleStack, PreferDualStack, RequireDualStack
|
||||
ipFamilyPolicy:
|
||||
# -- The ip families that should be used. Options: IPv4, IPv6
|
||||
ipFamilies: []
|
||||
|
||||
# -- Provide additional annotations which may be required.
|
||||
annotations: {}
|
||||
|
||||
# -- Provide additional labels which may be required.
|
||||
labels: {}
|
||||
|
||||
# -- Configure the Service port information here.
|
||||
# Additional ports can be added by adding a dictionary key similar to the 'http' service.
|
||||
# @default -- See below
|
||||
ports:
|
||||
http:
|
||||
# -- Enables or disables the port
|
||||
enabled: true
|
||||
|
||||
# -- Make this the primary port (used in probes, notes, etc...)
|
||||
# If there is more than 1 service, make sure that only 1 port is marked as primary.
|
||||
primary: true
|
||||
|
||||
# -- The port number
|
||||
port:
|
||||
|
||||
# -- Port protocol.
|
||||
# Support values are `HTTP`, `HTTPS`, `TCP` and `UDP`.
|
||||
# HTTPS and HTTPS spawn a TCP service and get used for internal URL and name generation
|
||||
protocol: HTTP
|
||||
|
||||
# -- Specify a service targetPort if you wish to differ the service port from the application port.
|
||||
# If `targetPort` is specified, this port number is used in the container definition instead of
|
||||
# the `port` value. Therefore named ports are not supported for this field.
|
||||
targetPort:
|
||||
|
||||
# -- Specify the nodePort value for the LoadBalancer and NodePort service types.
|
||||
# [[ref]](https://kubernetes.io/docs/concepts/services-networking/service/#type-nodeport)
|
||||
nodePort:
|
||||
|
||||
# -- Allow adding additional match labels
|
||||
extraSelectorLabels: {}
|
||||
|
||||
# -- Configure the ServiceMonitors for the chart here.
|
||||
# Additional ServiceMonitors can be added by adding a dictionary key similar to the 'main' ServiceMonitors.
|
||||
# @default -- See below
|
||||
serviceMonitor:
|
||||
main:
|
||||
# -- Enables or disables the serviceMonitor.
|
||||
enabled: false
|
||||
|
||||
# -- Override the name suffix that is used for this serviceMonitor.
|
||||
nameOverride:
|
||||
|
||||
# -- Provide additional annotations which may be required.
|
||||
annotations: {}
|
||||
|
||||
# -- Provide additional labels which may be required.
|
||||
labels: {}
|
||||
|
||||
# -- Configures a custom selector for the serviceMonitor, this takes precedence over
|
||||
# specifying a service name.
|
||||
# Helm templates can be used.
|
||||
selector: {}
|
||||
|
||||
# -- Configures the target Service for the serviceMonitor. Helm templates can be used.
|
||||
serviceName: '{{ include "bjw-s.common.lib.chart.names.fullname" $ }}'
|
||||
|
||||
# -- Configures the endpoints for the serviceMonitor.
|
||||
# @default -- See values.yaml
|
||||
endpoints:
|
||||
- port: http
|
||||
scheme: http
|
||||
path: /metrics
|
||||
interval: 1m
|
||||
scrapeTimeout: 10s
|
||||
|
||||
# -- Configure the ingresses for the chart here.
|
||||
# Additional ingresses can be added by adding a dictionary key similar to the 'main' ingress.
|
||||
# @default -- See below
|
||||
ingress:
|
||||
main:
|
||||
# -- Enables or disables the ingress
|
||||
enabled: false
|
||||
|
||||
# -- Make this the primary ingress (used in probes, notes, etc...).
|
||||
# If there is more than 1 ingress, make sure that only 1 ingress is marked as primary.
|
||||
primary: true
|
||||
|
||||
# -- Override the name suffix that is used for this ingress.
|
||||
nameOverride:
|
||||
|
||||
# -- Provide additional annotations which may be required.
|
||||
annotations:
|
||||
{}
|
||||
# kubernetes.io/ingress.class: nginx
|
||||
# kubernetes.io/tls-acme: "true"
|
||||
|
||||
# -- Provide additional labels which may be required.
|
||||
labels: {}
|
||||
|
||||
# -- Set the ingressClass that is used for this ingress.
|
||||
ingressClassName: # "nginx"
|
||||
|
||||
## Configure the hosts for the ingress
|
||||
hosts:
|
||||
- # -- Host address. Helm template can be passed.
|
||||
host: chart-example.local
|
||||
## Configure the paths for the host
|
||||
paths:
|
||||
- # -- Path. Helm template can be passed.
|
||||
path: /
|
||||
pathType: Prefix
|
||||
service:
|
||||
# -- Overrides the service name reference for this path
|
||||
name:
|
||||
# -- Overrides the service port reference for this path
|
||||
port:
|
||||
|
||||
# -- Configure TLS for the ingress. Both secretName and hosts can process a Helm template.
|
||||
tls: []
|
||||
# - secretName: chart-example-tls
|
||||
# hosts:
|
||||
# - chart-example.local
|
||||
|
||||
# -- Configure the gateway routes for the chart here.
|
||||
# Additional routes can be added by adding a dictionary key similar to the 'main' route.
|
||||
# [[ref]](https://gateway-api.sigs.k8s.io/references/spec/#gateway.networking.k8s.io%2fv1alpha2)
|
||||
# @default -- See below
|
||||
route:
|
||||
main:
|
||||
# -- Enables or disables the route
|
||||
enabled: false
|
||||
|
||||
# -- Set the route kind
|
||||
# Valid options are GRPCRoute, HTTPRoute, TCPRoute, TLSRoute, UDPRoute
|
||||
kind: HTTPRoute
|
||||
|
||||
# -- Override the name suffix that is used for this route.
|
||||
nameOverride:
|
||||
|
||||
# -- Provide additional annotations which may be required.
|
||||
annotations: {}
|
||||
|
||||
# -- Provide additional labels which may be required.
|
||||
labels: {}
|
||||
|
||||
# -- Configure the resource the route attaches to.
|
||||
parentRefs:
|
||||
- # Group of the referent resource.
|
||||
group: gateway.networking.k8s.io
|
||||
# Kind of the referent resource.
|
||||
kind: Gateway
|
||||
# Name of the referent resource
|
||||
name:
|
||||
# Namespace of the referent resource
|
||||
namespace:
|
||||
# Name of the section within the target resource.
|
||||
sectionName:
|
||||
|
||||
# -- Host addresses
|
||||
hostnames: []
|
||||
|
||||
# -- Configure rules for routing. Defaults to the primary service.
|
||||
rules:
|
||||
- # -- Configure backends where matching requests should be sent.
|
||||
backendRefs:
|
||||
- group: ""
|
||||
kind: Service
|
||||
name:
|
||||
namespace:
|
||||
port:
|
||||
weight: 1
|
||||
## Configure conditions used for matching incoming requests. Only for HTTPRoutes
|
||||
matches:
|
||||
- path:
|
||||
type: PathPrefix
|
||||
value: /
|
||||
|
||||
# -- Configure persistence for the chart here.
|
||||
# Additional items can be added by adding a dictionary key similar to the 'config' key.
|
||||
# [[ref]](https://bjw-s.github.io/helm-charts/docs/common-library/common-library-storage)
|
||||
# @default -- See below
|
||||
persistence:
|
||||
# -- Default persistence for configuration files.
|
||||
# @default -- See below
|
||||
config:
|
||||
# -- Enables or disables the persistence item
|
||||
enabled: false
|
||||
|
||||
# -- Sets the persistence type
|
||||
# Valid options are pvc, emptyDir, hostPath, secret, configMap or custom
|
||||
type: pvc
|
||||
|
||||
# -- Where to mount the volume in the main container.
|
||||
# Defaults to `/<name_of_the_volume>`,
|
||||
# setting to '-' creates the volume but disables the volumeMount.
|
||||
mountPath: # /config
|
||||
# -- Specify if the volume should be mounted read-only.
|
||||
readOnly: false
|
||||
# -- Override the name suffix that is used for this volume.
|
||||
nameOverride:
|
||||
|
||||
# -- Storage Class for the config volume.
|
||||
# If set to `-`, dynamic provisioning is disabled.
|
||||
# If set to something else, the given storageClass is used.
|
||||
# If undefined (the default) or set to null, no storageClassName spec is set, choosing the default provisioner.
|
||||
storageClass: # "-"
|
||||
|
||||
# -- If you want to reuse an existing claim, the name of the existing PVC can be passed here.
|
||||
existingClaim: # your-claim
|
||||
|
||||
# -- Used in conjunction with `existingClaim`. Specifies a sub-path inside the referenced volume instead of its root
|
||||
subPath: # some-subpath
|
||||
|
||||
# -- AccessMode for the persistent volume.
|
||||
# Make sure to select an access mode that is supported by your storage provider!
|
||||
# [[ref]](https://kubernetes.io/docs/concepts/storage/persistent-volumes/#access-modes)
|
||||
accessMode: ReadWriteOnce
|
||||
|
||||
# -- The amount of storage that is requested for the persistent volume.
|
||||
size: 1Gi
|
||||
|
||||
# -- Set to true to retain the PVC upon `helm uninstall`
|
||||
retain: false
|
||||
|
||||
# -- Create an emptyDir volume to share between all containers
|
||||
# [[ref]]https://kubernetes.io/docs/concepts/storage/volumes/#emptydir)
|
||||
# @default -- See below
|
||||
shared:
|
||||
enabled: false
|
||||
type: emptyDir
|
||||
mountPath: /shared
|
||||
|
||||
# -- Set the medium to "Memory" to mount a tmpfs (RAM-backed filesystem) instead
|
||||
# of the storage medium that backs the node.
|
||||
medium: # Memory
|
||||
|
||||
# -- If the `SizeMemoryBackedVolumes` feature gate is enabled, you can
|
||||
# specify a size for memory backed volumes.
|
||||
sizeLimit: # 1Gi
|
||||
|
||||
# -- Used in conjunction with `controller.type: statefulset` to create individual disks for each instance.
|
||||
volumeClaimTemplates: []
|
||||
# - name: data
|
||||
# labels: {}
|
||||
# annotations: {}
|
||||
# mountPath: /data
|
||||
# accessMode: "ReadWriteOnce"
|
||||
# size: 1Gi
|
||||
# - name: backup
|
||||
# labels: {}
|
||||
# annotations: {}
|
||||
# mountPath: /backup
|
||||
# subPath: theSubPath
|
||||
# accessMode: "ReadWriteOnce"
|
||||
# size: 2Gi
|
||||
# storageClass: cheap-storage-class
|
||||
|
||||
# -- Node selection constraint
|
||||
# [[ref]](https://kubernetes.io/docs/concepts/scheduling-eviction/assign-pod-node/#nodeselector)
|
||||
nodeSelector: {}
|
||||
|
||||
# -- Defines affinity constraint rules.
|
||||
# [[ref]](https://kubernetes.io/docs/concepts/scheduling-eviction/assign-pod-node/#affinity-and-anti-affinity)
|
||||
affinity: {}
|
||||
|
||||
# -- Defines topologySpreadConstraint rules.
|
||||
# [[ref]](https://kubernetes.io/docs/concepts/workloads/pods/pod-topology-spread-constraints/)
|
||||
topologySpreadConstraints: []
|
||||
# - maxSkew: <integer>
|
||||
# topologyKey: <string>
|
||||
# whenUnsatisfiable: <string>
|
||||
# labelSelector: <object>
|
||||
|
||||
# -- Specify taint tolerations
|
||||
# [[ref]](https://kubernetes.io/docs/concepts/scheduling-eviction/taint-and-toleration/)
|
||||
tolerations: []
|
||||
|
||||
# -- Use hostAliases to add custom entries to /etc/hosts - mapping IP addresses to hostnames.
|
||||
# [[ref]](https://kubernetes.io/docs/concepts/services-networking/add-entries-to-pod-etc-hosts-with-host-aliases/)
|
||||
hostAliases: []
|
||||
# - ip: "192.168.1.100"
|
||||
# hostnames:
|
||||
# - "example.com"
|
||||
# - "www.example.com"
|
||||
|
||||
# -- Set the resource requests / limits for the main container.
|
||||
resources:
|
||||
{}
|
||||
## We usually recommend not to specify default resources and to leave this as a conscious
|
||||
## choice for the user. This also increases chances charts run on environments with little
|
||||
## resources, such as Minikube. If you do want to specify resources, uncomment the following
|
||||
## lines, adjust them as necessary, and remove the curly braces after 'resources:'.
|
||||
# limits:
|
||||
# cpu: 100m
|
||||
# memory: 128Mi
|
||||
# requests:
|
||||
# cpu: 100m
|
||||
# memory: 128Mi
|
||||
|
||||
# -- The common chart supports several add-ons. These can be configured under this key.
|
||||
# @default -- See below
|
||||
addons:
|
||||
# -- The common chart supports adding a VPN add-on. It can be configured under this key.
|
||||
# @default -- See values.yaml
|
||||
vpn:
|
||||
# -- Enable running a VPN in the pod to route traffic through a VPN
|
||||
enabled: false
|
||||
|
||||
# -- Specify the VPN type. Valid options are `gluetun`.
|
||||
type: gluetun
|
||||
|
||||
# -- Gluetun specific configuration
|
||||
# -- Make sure to read the [documentation](https://github.com/qdm12/gluetun/wiki)
|
||||
# to see how to configure this addon!
|
||||
# @default -- See below
|
||||
gluetun:
|
||||
image:
|
||||
# -- Specify the Gluetun image
|
||||
repository: docker.io/qmcgaw/gluetun
|
||||
# -- Specify the Gluetun image tag
|
||||
tag: v3.34.3
|
||||
# -- Specify the Gluetun image pull policy
|
||||
pullPolicy: IfNotPresent
|
||||
|
||||
# -- Set the VPN container securityContext
|
||||
# @default -- See values.yaml
|
||||
securityContext:
|
||||
capabilities:
|
||||
add:
|
||||
- NET_ADMIN
|
||||
- SYS_MODULE
|
||||
|
||||
# -- All variables specified here will be added to the vpn sidecar container
|
||||
# See the documentation of the VPN image for all config values
|
||||
env:
|
||||
{}
|
||||
# TZ: UTC
|
||||
|
||||
# -- Override the args for the vpn sidecar container
|
||||
args: []
|
||||
|
||||
# -- Provide a customized vpn configuration file to be used by the VPN.
|
||||
configFile:
|
||||
# |-
|
||||
# Some Example Config
|
||||
# remote greatvpnhost.com 8888
|
||||
# auth-user-pass
|
||||
# Cipher AES
|
||||
|
||||
# -- Reference an existing secret that contains the VPN configuration file
|
||||
# The chart expects it to be present under the `vpnConfigfile` key.
|
||||
configFileSecret:
|
||||
|
||||
# -- Provide custom up/down scripts that can be used by the vpn configuration.
|
||||
# @default -- See values.yaml
|
||||
scripts:
|
||||
# @default -- See below
|
||||
up:
|
||||
# |-
|
||||
# !/bin/bash
|
||||
# echo "connected" > /shared/vpnstatus
|
||||
|
||||
# @default -- See below
|
||||
down:
|
||||
# |-
|
||||
# #!/bin/bash
|
||||
# echo "disconnected" > /shared/vpnstatus
|
||||
|
||||
additionalVolumeMounts: []
|
||||
|
||||
# -- Optionally specify a livenessProbe, e.g. to check if the connection is still
|
||||
# being protected by the VPN
|
||||
livenessProbe:
|
||||
{}
|
||||
# exec:
|
||||
# command:
|
||||
# - sh
|
||||
# - -c
|
||||
# - if [ $(curl -s https://ipinfo.io/country) == 'US' ]; then exit 0; else exit $?; fi
|
||||
# initialDelaySeconds: 30
|
||||
# periodSeconds: 60
|
||||
# failureThreshold: 1
|
||||
|
||||
networkPolicy:
|
||||
# -- If set to true, will deploy a network policy that blocks all outbound
|
||||
# traffic except traffic specified as allowed
|
||||
enabled: false
|
||||
|
||||
# -- Provide additional annotations which may be required.
|
||||
annotations: {}
|
||||
|
||||
# -- Provide additional labels which may be required.
|
||||
labels: {}
|
||||
|
||||
# -- Provide additional podSelector labels which may be required.
|
||||
podSelectorLabels: {}
|
||||
|
||||
# -- The egress configuration for your network policy, All outbound traffic
|
||||
# from the pod will be blocked unless specified here.
|
||||
# [[ref]](https://kubernetes.io/docs/concepts/services-networking/network-policies/)
|
||||
# [[recipes]](https://github.com/ahmetb/kubernetes-network-policy-recipes)
|
||||
egress:
|
||||
# - to:
|
||||
# - ipBlock:
|
||||
# cidr: 0.0.0.0/0
|
||||
# ports:
|
||||
# - port: 53
|
||||
# protocol: UDP
|
||||
# - port: 53
|
||||
# protocol: TCP
|
||||
|
||||
# -- The common library supports adding a code-server add-on to access files. It can be configured under this key.
|
||||
# @default -- See values.yaml
|
||||
codeserver:
|
||||
# -- Enable running a code-server container in the pod
|
||||
enabled: false
|
||||
|
||||
image:
|
||||
# -- Specify the code-server image
|
||||
repository: ghcr.io/coder/code-server
|
||||
# -- Specify the code-server image tag
|
||||
tag: 4.13.0
|
||||
# -- Specify the code-server image pull policy
|
||||
pullPolicy: IfNotPresent
|
||||
|
||||
# -- Set any environment variables for code-server here
|
||||
env:
|
||||
{}
|
||||
# TZ: UTC
|
||||
|
||||
# -- Set codeserver command line arguments.
|
||||
# Consider setting --user-data-dir to a persistent location to preserve code-server setting changes
|
||||
args:
|
||||
- --auth
|
||||
- none
|
||||
# - --user-data-dir
|
||||
# - "/config/.vscode"
|
||||
|
||||
# -- Specify a list of volumes that get mounted in the code-server container.
|
||||
# At least 1 volumeMount is required!
|
||||
volumeMounts: []
|
||||
# - name: config
|
||||
# mountPath: /data/config
|
||||
|
||||
# -- Specify the working dir that will be opened when code-server starts
|
||||
# If not given, the app will default to the mountpah of the first specified volumeMount
|
||||
workingDir: ""
|
||||
|
||||
# -- Optionally allow access a Git repository by passing in a private SSH key
|
||||
# @default -- See below
|
||||
git:
|
||||
# -- Raw SSH private key
|
||||
deployKey: ""
|
||||
# -- Base64-encoded SSH private key. When both variables are set, the raw SSH key takes precedence.
|
||||
deployKeyBase64: ""
|
||||
# -- Existing secret containing SSH private key
|
||||
# The chart expects it to be present under the `id_rsa` key.
|
||||
deployKeySecret: ""
|
||||
|
||||
service:
|
||||
# -- Enable a service for the code-server add-on.
|
||||
enabled: true
|
||||
type: ClusterIP
|
||||
# Specify the default port information
|
||||
ports:
|
||||
codeserver:
|
||||
port: 12321
|
||||
enabled: true
|
||||
protocol: TCP
|
||||
targetPort: 12321
|
||||
## Specify the nodePort value for the LoadBalancer and NodePort service types.
|
||||
## ref: https://kubernetes.io/docs/concepts/services-networking/service/#type-nodeport
|
||||
##
|
||||
# nodePort:
|
||||
annotations: {}
|
||||
labels: {}
|
||||
|
||||
ingress:
|
||||
# -- Enable an ingress for the code-server add-on.
|
||||
enabled: false
|
||||
|
||||
annotations:
|
||||
{}
|
||||
# kubernetes.io/ingress.class: nginx
|
||||
# kubernetes.io/tls-acme: "true"
|
||||
|
||||
labels: {}
|
||||
|
||||
# -- Set the ingressClass that is used for this ingress.
|
||||
ingressClassName: # "nginx"
|
||||
|
||||
hosts:
|
||||
- host: code.chart-example.local
|
||||
paths:
|
||||
- path: /
|
||||
pathType: Prefix
|
||||
tls: []
|
||||
# - secretName: chart-example-tls
|
||||
# hosts:
|
||||
# - code.chart-example.local
|
||||
|
||||
securityContext:
|
||||
runAsUser: 0
|
||||
|
||||
# -- The common library supports adding a netshoot add-on to troubleshoot network issues within a Pod.
|
||||
# It can be configured under this key.
|
||||
# @default -- See values.yaml
|
||||
netshoot:
|
||||
# -- Enable running a netshoot container in the pod
|
||||
enabled: false
|
||||
|
||||
image:
|
||||
# -- Specify the netshoot image
|
||||
repository: ghcr.io/nicolaka/netshoot
|
||||
# -- Specify the netshoot image tag
|
||||
tag: v0.11
|
||||
# -- Specify the netshoot image pull policy
|
||||
pullPolicy: IfNotPresent
|
||||
|
||||
# -- Set any environment variables for netshoot here
|
||||
env: {}
|
||||
|
||||
securityContext:
|
||||
capabilities:
|
||||
add:
|
||||
- NET_ADMIN
|
||||
6
charts/paperless-ngx/charts/mariadb/Chart.lock
Normal file
6
charts/paperless-ngx/charts/mariadb/Chart.lock
Normal file
@@ -0,0 +1,6 @@
|
||||
dependencies:
|
||||
- name: common
|
||||
repository: oci://registry-1.docker.io/bitnamicharts
|
||||
version: 2.27.0
|
||||
digest: sha256:b711ab5874abf868a0c64353a790f17771758cee6f802acb9819be004c8460af
|
||||
generated: "2024-11-07T11:44:05.529563646+01:00"
|
||||
36
charts/paperless-ngx/charts/mariadb/Chart.yaml
Normal file
36
charts/paperless-ngx/charts/mariadb/Chart.yaml
Normal file
@@ -0,0 +1,36 @@
|
||||
annotations:
|
||||
category: Database
|
||||
images: |
|
||||
- name: mariadb
|
||||
image: docker.io/bitnami/mariadb:11.4.4-debian-12-r0
|
||||
- name: mysqld-exporter
|
||||
image: docker.io/bitnami/mysqld-exporter:0.15.1-debian-12-r36
|
||||
- name: os-shell
|
||||
image: docker.io/bitnami/os-shell:12-debian-12-r32
|
||||
licenses: Apache-2.0
|
||||
apiVersion: v2
|
||||
appVersion: 11.4.4
|
||||
dependencies:
|
||||
- name: common
|
||||
repository: oci://registry-1.docker.io/bitnamicharts
|
||||
tags:
|
||||
- bitnami-common
|
||||
version: 2.x.x
|
||||
description: MariaDB is an open source, community-developed SQL database server that
|
||||
is widely in use around the world due to its enterprise features, flexibility, and
|
||||
collaboration with leading tech firms.
|
||||
home: https://bitnami.com
|
||||
icon: https://bitnami.com/assets/stacks/mariadb/img/mariadb-stack-220x234.png
|
||||
keywords:
|
||||
- mariadb
|
||||
- mysql
|
||||
- database
|
||||
- sql
|
||||
- prometheus
|
||||
maintainers:
|
||||
- name: Broadcom, Inc. All Rights Reserved.
|
||||
url: https://github.com/bitnami/charts
|
||||
name: mariadb
|
||||
sources:
|
||||
- https://github.com/bitnami/charts/tree/main/bitnami/mariadb
|
||||
version: 20.1.1
|
||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user