keycloak

by BeeInventor

Helm chartv4.0.4App 14.0.0

Fork from bitnami keycloak 4.0.3, just for patching bitnami-common

About this chart

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.

TL;DR

  helm repo add bitnami https://charts.bitnami.com/bitnami
  helm install my-release bitnami/keycloak

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 deployment on a Kubernetes cluster using the Helm package manager.

Bitnami charts can be used with Kubeapps for deployment and management of Helm Charts in clusters. This Helm chart has been tested on top of Bitnami Kubernetes Production Runtime (BKPR). Deploy BKPR to get automated TLS certificates, logging and monitoring for your applications.

Prerequisites

  • Kubernetes 1.12+
  • Helm 3.1.0

Installing the Chart

To install the chart with the release name my-release:

$ helm repo add bitnami https://charts.bitnami.com/bitnami
$ helm install my-release bitnami/keycloak

These commands deploy a Keycloak application on the Kubernetes cluster in the default configuration.

Tip: List all releases using helm list

Uninstalling the Chart

To uninstall/delete the my-release deployment:

$ helm delete my-release

The command removes all the Kubernetes components associated with the chart and deletes the release.

Parameters

Global parameters

NameDescriptionValue
global.imageRegistryGlobal Docker image registry""
global.imagePullSecretsGlobal Docker registry secret names as an array[]
global.storageClassGlobal StorageClass for Persistent Volume(s)""

Common parameters

NameDescriptionValue
kubeVersionForce target Kubernetes version (using Helm capabilities if not set)""
nameOverrideString to partially override keycloak.fullname""
fullnameOverrideString to fully override keycloak.fullname""
hostAliasesAdd deployment host aliases[]
commonLabelsLabels to add to all deployed objects{}
commonAnnotationsAnnotations to add to all deployed objects{}
clusterDomainDefault Kubernetes cluster domaincluster.local
extraDeployArray of extra objects to deploy with the release[]

Keycloak parameters

NameDescriptionValue
image.registryKeycloak image registrydocker.io
image.repositoryKeycloak image repositorybitnami/keycloak
image.tagKeycloak image tag (immutable tags are recommended)14.0.0-debian-10-r0
image.pullPolicyKeycloak image pull policyIfNotPresent
image.pullSecretsSpecify docker-registry secret names as an array[]
image.debugSpecify if debug logs should be enabledfalse
auth.createAdminUserCreate administrator user on boottrue
auth.adminUserKeycloak administrator useruser
auth.adminPasswordKeycloak administrator password for the new user""
auth.managementUserWildfly management usermanager
auth.managementPasswordWildfly management password""
auth.existingSecretAn already existing secret containing auth info""
auth.existingSecretPerPasswordOverride existingSecret and other secret values""
auth.tls.enabledEnable TLS encryptionfalse
auth.tls.autoGeneratedGenerate automatically self-signed TLS certificates. Currently only supports PEM certificatesfalse
auth.tls.existingSecretExisting secret containing the TLS certificates per Keycloak replica""
auth.tls.jksSecretDEPRECATED. Use auth.tls.existingSecret instead""
auth.tls.keystorePasswordPassword to access the keystore when it's password-protected""
auth.tls.truststorePasswordPassword to access the truststore when it's password-protected""
auth.tls.resources.limitsThe resources limits for the TLS init container{}
auth.tls.resources.requestsThe requested resources for the TLS init container{}
proxyAddressForwardingEnable Proxy Address Forwardingfalse
serviceDiscovery.enabledEnable Service Discovery for Keycloak (required if replicaCount > 1)false
serviceDiscovery.protocolSets the protocol that Keycloak nodes would use to discover new peerskubernetes.KUBE_PING
serviceDiscovery.propertiesProperties for the discovery protocol set in serviceDiscovery.protocol parameter[]
serviceDiscovery.transportStackTransport stack for the discovery protocol set in serviceDiscovery.protocol parametertcp
cache.ownersCountNumber of nodes that will replicate cached data1
cache.authOwnersCountNumber of nodes that will replicate cached authentication data1
configurationKeycloak Configuration. Auto-generated based on other parameters when not specified""
existingConfigmapName of existing ConfigMap with Keycloak configuration""
extraStartupArgsExtra default startup args""
initdbScriptsDictionary of initdb scripts{}
initdbScriptsConfigMapConfigMap with the initdb scripts (Note: Overrides initdbScripts)""
commandOverride default container command (useful when using custom images)[]
argsOverride default container args (useful when using custom images)[]
extraEnvVarsExtra environment variables to be set on Keycloak container[]
extraEnvVarsCMName of existing ConfigMap containing extra env vars""
extraEnvVarsSecretName of existing Secret containing extra env vars""

keycloak-config-cli parameters

NameDescriptionValue
keycloakConfigCli.enabledWhether to enable keycloak-config-clifalse
keycloakConfigCli.image.registrykeycloak-config-cli container image registrydocker.io
keycloakConfigCli.image.repositorykeycloak-config-cli container image repositorybitnami/keycloak-config-cli
keycloakConfigCli.image.tagkeycloak-config-cli container image tag4.0.1-debian-10-r0
keycloakConfigCli.image.pullPolicykeycloak-config-cli container image pull policyIfNotPresent
keycloakConfigCli.image.pullSecretskeycloak-config-cli container image pull secrets[]
keycloakConfigCli.annotationsAnnotations for keycloak-config-cli jobundefined
keycloakConfigCli.commandCommand for running the container (set to default if not set). Use array form[]
keycloakConfigCli.argsArgs for running the container (set to default if not set). Use array form[]
keycloakConfigCli.hostAliasesJob pod host aliases[]
keycloakConfigCli.resources.limitsThe resources limits for the keycloak-config-cli container{}
keycloakConfigCli.resources.requestsThe requested resources for the keycloak-config-cli container{}
keycloakConfigCli.containerSecurityContext.enabledEnabled keycloak-config-cli containers' Security Contexttrue
keycloakConfigCli.containerSecurityContext.runAsUserSet keycloak-config-cli container's Security Context runAsUser1001
keycloakConfigCli.containerSecurityContext.runAsNonRootSet keycloak-config-cli container's Security Context runAsNonRoottrue
keycloakConfigCli.podSecurityContext.enabledEnabled keycloak-config-cli pods' Security Contexttrue
keycloakConfigCli.podSecurityContext.fsGroupSet keycloak-config-cli pod's Security Context fsGroup1001
keycloakConfigCli.backoffLimitNumber of retries before considering a Job as failed1
keycloakConfigCli.podLabelsPod extra labels{}
keycloakConfigCli.podAnnotationsAnnotations for job pod{}
`keycloakConf

Deploy keycloak with OpenTenant

Each tenant gets its own release of this chart, with its own namespace, secrets and domain. The builder below already has keycloak on a Hetzner server. Change the host, add apps from the marketplace, then copy the generated files. Providers and prices are samples, and nothing here is sent anywhere.

  1. Pick a serverConnect Hetzner, OVHcloud or AWS. The builder starts on Hetzner, the cheapest sample rate.
  2. Place the chartkeycloak is pinned at v4.0.4 in opentenant.yaml. Drag more apps from the marketplace onto a rack.
  3. ApplySave opentenant.yaml and main.tf from the console, then run the commands below.
# opentenant.yaml, main.tf and dns.tf come from the builder below
opentenant validate opentenant.yaml
terraform init && terraform apply