discourse

by [riftbit]

Helm chartv5.0.0App 2.7.8Verified publisher

A Helm chart for deploying Discourse to Kubernetes

About this chart

Discourse

Discourse is an open source discussion platform. It can be used as a mailing list, discussion forum, long-form chat room, and more.

TL;DR

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

Introduction

This chart bootstraps a Discourse deployment on a Kubernetes cluster using the Helm package manager.

It also packages Bitnami Postgresql and Bitnami Redis™ which are required as databases for the Discourse application.

Bitnami charts can be used with Kubeapps for deployment and management of Helm Charts in clusters.

Prerequisites

  • Kubernetes 1.12+
  • Helm 3.1.0
  • PV provisioner support in the underlying infrastructure
  • ReadWriteMany volumes for deployment scaling

Installing the Chart

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

$ helm install my-release bitnami/discourse

The command deploys Discourse on the Kubernetes cluster in the default configuration. The Parameters section lists the parameters that can be configured during installation.

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 discourse.fullname template (will maintain the release name)""
fullnameOverrideString to fully override discourse.fullname template""
commonLabelsLabels to be added to all deployed resources{}
commonAnnotationsAnnotations to be added to all deployed resources{}

Service parameters

NameDescriptionValue
service.typeKubernetes Service typeLoadBalancer
service.portService HTTP port80
service.nodePortNode Ports to expose""
service.loadBalancerIPUse loadBalancerIP to request a specific static IP""
service.externalTrafficPolicyEnable client source IP preservationCluster
service.annotationsService annotations{}
service.loadBalancerSourceRangesLimits which cidr blocks can connect to service's load balancer[]
service.extraPortsExtra ports to expose (normally used with the sidecar value)[]
service.nodePorts.httpKubernetes http node port""

Discourse parameters

NameDescriptionValue
image.registryDiscourse image registrydocker.io
image.repositoryDiscourse image repositorybitnami/discourse
image.tagDiscourse image tag2.7.8-debian-10-r0
image.pullPolicyDiscourse image pull policyIfNotPresent
image.pullSecretsDiscourse image pull secrets[]
image.debugSpecify if debug logs should be enabledfalse
imagePullSecretsSpecify docker-registry secret names as an array[]
discourse.hostDiscourse host to create application URLs (include the port if =/= 80)""
discourse.siteNameDiscourse site nameMy Site!
discourse.usernameAdmin user of the applicationuser
discourse.passwordpassword. WARNING: Minimum length of 10 characters""
discourse.existingSecretName of an existing secret containing the password (ignores previous password)""
discourse.emailAdmin user email of the application[email protected]
discourse.commandCustom command to override image cmd[]
discourse.argsCustom args for the custom command[]
discourse.containerSecurityContextContainer security context specification{}
discourse.resources.limitsThe resources limits for the container{}
discourse.resources.requestsThe requested resources for the container{}
discourse.livenessProbe.enabledEnable/disable livenessProbetrue
discourse.livenessProbe.initialDelaySecondsDelay before liveness probe is initiated500
discourse.livenessProbe.periodSecondsHow often to perform the probe10
discourse.livenessProbe.timeoutSecondsWhen the probe times out5
discourse.livenessProbe.failureThresholdMinimum consecutive failures for the probe6
discourse.livenessProbe.successThresholdMinimum consecutive successes for the probe1
discourse.readinessProbe.enabledEnable/disable readinessProbetrue
discourse.readinessProbe.initialDelaySecondsDelay before readiness probe is initiated30
discourse.readinessProbe.periodSecondsHow often to perform the probe10
discourse.readinessProbe.timeoutSecondsWhen the probe times out5
discourse.readinessProbe.failureThresholdMinimum consecutive failures for the probe6
discourse.readinessProbe.successThresholdMinimum consecutive successes for the probe1
discourse.customLivenessProbeCustom liveness probe to execute (when the main one is disabled){}
discourse.customReadinessProbeCustom readiness probe to execute (when the main one is disabled){}
discourse.smtp.enabledEnable/disable SMTPfalse
discourse.smtp.hostSMTP host name""
discourse.smtp.portSMTP port number""
discourse.smtp.userSMTP account user name""
discourse.smtp.passwordSMTP account password""
discourse.smtp.protocolSMTP protocol (Allowed values: tls, ssl)""
discourse.smtp.authSMTP authentication method""
discourse.smtp.existingSecretName of an existing Kubernetes secret. The secret must have the following key configured: smtp-password""
discourse.extraEnvVarsAn array to add extra env vars[]
discourse.extraEnvVarsCMArray to add extra configmaps[]
discourse.extraEnvVarsSecretArray to add extra environment variables from a secret""
discourse.extraVolumeMountsAdditional volume mounts (used along with extraVolumes)[]
discourse.skipInstallDo not run the Discourse installation wizardfalse
replicaCountNumber of Discourse & Sidekiq replicas1
extraVolumesArray of extra volumes to be added deployment. Requires setting extraVolumeMounts[]
sidecarsAttach additional sidecar containers to the pod[]
initContainersAdditional init containers to add to the pods[]
serviceAccount.createWhether the service account should be createdfalse
serviceAccount.annotationsAnnotations to add to the service account

Deploy discourse with OpenTenant

Each tenant gets its own release of this chart, with its own namespace, secrets and domain. The builder below already has discourse 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 chartdiscourse is pinned at v5.0.0 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