dendrite

by joaquinito2051

Helm chartv6.1.1App v0.8.9

Dendrite Matrix Homeserver

About this chart

dendrite

Dendrite Matrix Homeserver

This chart is not maintained by the upstream project and any issues with the chart should be raised here

Source Code

Requirements

Kubernetes: >=1.16.0-0

Dependencies

RepositoryNameVersion
https://charts.bitnami.com/bitnamipostgresql11.6.12
https://library-charts.k8s-at-home.comcommon4.4.2
https://library-charts.k8s-at-home.comkeyserver(common)4.4.2
https://library-charts.k8s-at-home.comclientapi(common)4.4.2
https://library-charts.k8s-at-home.commediaapi(common)4.4.2
https://library-charts.k8s-at-home.comsyncapi(common)4.4.2
https://library-charts.k8s-at-home.comroomserver(common)4.4.2
https://library-charts.k8s-at-home.comfederationapi(common)4.4.2
https://library-charts.k8s-at-home.comuserapi(common)4.4.2
https://library-charts.k8s-at-home.comappserviceapi(common)4.4.2
https://nats-io.github.io/k8s/helm/charts/nats0.17.1

TL;DR

helm repo add k8s-at-home https://k8s-at-home.com/charts/
helm repo update
helm install dendrite k8s-at-home/dendrite

Installing the Chart

To install the chart with the release name dendrite

helm install dendrite k8s-at-home/dendrite

Uninstalling the Chart

To uninstall the dendrite deployment

helm uninstall dendrite

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

Configuration

Read through the values.yaml file. It has several commented out suggested values. Other values may be used from the values.yaml from the common library.

Specify each parameter using the --set key=value[,key=value] argument to helm install.

helm install dendrite \
  --set env.TZ="America/New York" \
    k8s-at-home/dendrite

Alternatively, a YAML file that specifies the values for the above parameters can be provided while installing the chart.

helm install dendrite k8s-at-home/dendrite -f values.yaml

Custom configuration

Polylith Ingress

Due to the complexity of setting up ingress for each individual component it is left up to the individual to add the necessary ingress fields to polylith deployments.

For more information see:

  • https://github.com/matrix-org/dendrite/blob/master/docs/INSTALL.md#nginx-or-other-reverse-proxy
  • and https://github.com/matrix-org/dendrite/blob/master/docs/nginx/polylith-sample.conf

Values

Important: When deploying an application Helm chart you can add more values from our common library chart here

KeyTypeDefaultDescription
appserviceapiobjectSee values.yamlConfigure the app service api. For more information see the sample dendrite configuration
appserviceapi.databaseobjectSee values.yamlOverride general dendrite.database parameters.
appserviceapi.database.conn_max_lifetimestringdendrite.database.conn_max_lifetimeMaximum connection lifetime
appserviceapi.database.connection_stringstringfile or derived from included postgresql deploymentCustom connection string
appserviceapi.database.max_idle_connsstringdendrite.database.max_idle_connsMaximum dile connections
appserviceapi.database.max_open_connsstringdendrite.database.max_open_connsMaximum open connections
appserviceapi.image.pullPolicystring"IfNotPresent"image pull policy
appserviceapi.image.repositorystring"matrixdotorg/dendrite-polylith"image repository
appserviceapi.image.tagstringchart.appVersionimage tag
clientapiobjectSee values.yamlConfiguration for the client api component. For more information see the sample dendrite configuration
clientapi.config.captchaobjectSee values.yamlConfigure captcha for registration
clientapi.config.rate_limitingobjectvalues.yamlConfigure rate limiting.
clientapi.config.registration_disabledboolfalseEnable or disable registration for this homeserver.
clientapi.config.registration_shared_secretstring""Shared secret that allows registration, despite registration_disabled.
clientapi.config.turnobjectSee values.yamlConfigure TURN
clientapi.image.pullPolicystring"IfNotPresent"image pull policy
clientapi.image.repositorystring"matrixdotorg/dendrite-polylith"image repository
clientapi.image.tagstringchart.appVersionimage tag
databaseobjectSee values.yamlOverride general dendrite.database parameters.
database.conn_max_lifetimestringdendrite.database.conn_max_lifetimeMaximum connection lifetime
database.connection_stringstringfile or derived from included postgresql deploymentCustom connection string
database.max_idle_connsstringdendrite.database.max_idle_connsMaximum dile connections
database.max_open_connsstringdendrite.database.max_open_connsMaximum open connections
dendriteobjectSee values.yamlConfiguration for Dendrite. For more information see the sample denrite-config.yaml
dendrite.databaseobjectSee values.yamlConfigure database connection parameters.
dendrite.globalobjectSee values.yamlConfigure the global settings for dendrite.
dendrite.global.disable_federationboolfalseDisables federation
dendrite.global.dns_cacheobjectSee values.yamlConfigure DNS cache.
dendrite.global.dns_cache.enabledboolSee values.yamlIf enabled, dns cache will be enabled.
dendrite.global.key_validity_periodstring"168h0m0s"Configure the key_validity period
dendrite.global.metricsobjectSee values.yamlConfigure prometheus metrics collection for dendrite.
dendrite.global.metrics.enabledboolSee values.yamlIf enabled, metrics collection will be enabled
dendrite.global.mscslist[]Configure experimental MSC's
dendrite.global.presenceobject{"enable_inbound":false,"enable_outbound":false}Configure handling of presence events
dendrite.global.presence.enable_inboundboolfalseWhether inbound presence events are allowed, e.g. receiving presence events from other servers
dendrite.global.presence.enable_outboundboolfalseWhether outbound presence events are allowed, e.g. sending presence events to other servers
dendrite.global.server_namestring"localhost"(required) Configure the server name for the dendrite instance.
dendrite.global.server_noticesobject{"avatar_url":"","display_name":"Server alerts","enabled":false,"local_part":"_server","room_name":"Server Alerts"}Server notices allows server admins to send messages to all users.
dendrite.global.server_notices.avatar_urlstring""The mxid of the avatar to use
dendrite.global.server_notices.display_namestring"Server alerts"The displayname to be used when sending notices
dendrite.global.server_notices.local_partstring"_server"The server localpart to be used when sending notices, ensure this is not yet taken
dendrite.global.server_notices.room_namestring"Server Alerts"The roomname to be used when creating messages
dendrite.global.trusted_third_party_id_serverslist["matrix.org","vector.im"]Configure the list of domains the server will trust as identity servers
dendrite.global.well_known_server_namestring""Configure the well-known server name and optional port
dendrite.logginglistSee values.yamlConfigure logging.
dendrite.matrix_key_secret.createboolfalseCreate matrix_key secret using the keyBody below.
dendrite.matrix_key_secret.existingSecretstring""Use an existing secret
dendrite.matrix_key_secret.keyBodystring""New Key Body
dendrite.matrix_key_secret.secretPathstring"matrix_key.pem"Field in the secret to get the key from
dendrite.polylithEnabledboolfalseEnable polylith deployment
dendrite.polylith_ingressobjectSee values.yamlEnable and configure polylith ingress as per https://github.com/matrix-org/dendrite/blob/main/docs/nginx/polylith-sample.conf
dendrite.polylith_ingress.syncapi_pathslistSee values.yamlSync API Paths are a little tricky since they require regular expressions. Therefore the paths will depend on the ingress controller used. See values.yaml for nginx and traefik.
dendrite.report_statsobject{"enabled":false,"endpoint":""}Usage statistics reporting configuration
dendrite.report_stats.enabledboolfalseEnable or disable usage reporting
dendrite.report_stats.endpointstring""Push endpoint for usage statistics
dendrite.tls_secretobjectSee values.yamlIf enabled, use an existing secrets for the TLS certificate and key. Otherwise, to enable TLS a server.crt and server.key must be mounted at /etc/dendrite.
dendrite.tracingobjectSee values.yamlConfigure opentracing.
federationapiobjectvalues.yamlConfigure the Federation API For more information see the sample dendrite configuration
federationapi.databaseobjectSee values.yamlOverride general dendrite.database parameters.
federationapi.database.conn_max_lifetimestringdendrite.database.conn_max_lifetimeMaximum connection lifetime
federationapi.database.connection_stringstringfile or derived from included postgresql deploymentCustom connection string
federationapi.database.max_idle_connsstringdendrite.database.max_idle_connsMaximum dile connections
federationapi.database.max_open_connsstringdendrite.database.max_open_connsMaximum open connections
federationapi.image.pullPolicystring"IfNotPresent"image pull policy
federationapi.image.repositorystring"matrixdotorg/dendrite-polylith"image repository
federationapi.image.tagstringchart.appVersionimage tag
imageobject{"pullPolicy":"IfNotPresent","repository":"matrixdotorg/dendrite-monolith","tag":null}IMPORTANT NOTE This chart inherits from our common library chart. You can check the default values/options here: https://github.com/k8s-at-home/library-charts/tree/main/charts/stable/common/values.yaml
image.pullPolicystring"IfNotPresent"image pull policy
image.repositorystring"matrixdotorg/dendrite-monolith"image repository
image.tagstringchart.appVersionimage tag
ingress.mainobjectSee values.yaml(Monolith Only) Enable and configure ingress settings for the chart under this key.
keyserverobjectSee values.yamlConfigure the key server. For more information see the sample dendrite configuration
keyserver.databaseobjectSee values.yamlOverride general dendrite.database parameters.
keyserver.database.conn_max_lifetimestringdendrite.database.conn_max_lifetimeMaximum connection lifetime
keyserver.database.connection_stringstringfile or derived from included postgresql deploymentCustom connection string
keyserver.database.max_idle_connsstringdendrite.database.max_idle_connsMaximum dile connections
keyserver.database.max_open_connsstringdendrite.database.max_open_connsMaximum open connections
keyserver.image.pullPolicystring"IfNotPresent"image pull policy
keyserver.image.repositorystring"matrixdotorg/dendrite-polylith"image repository
keyserver.image.tagstringchart.appVersionimage tag
mediaapiobjectvalues.yamlConfigure the Media API For more information see the sample dendrite configuration
mediaapi.databaseobjectSee values.yamlOverride general dendrite.database parameters.
mediaapi.database.conn_max_lifetimestringdendrite.database.conn_max_lifetimeMaximum connection lifetime
mediaapi.database.connection_stringstringfile or derived from included postgresql deploymentCustom connection string
mediaapi.database.max_idle_connsstringdendrite.database.max_idle_connsMaximum dile connections
mediaapi.database.max_open_connsstringdendrite.database.max_open_connsMaximum open connections
mediaapi.image.pullPolicystring"IfNotPresent"image pull policy
mediaapi.image.repositorystring"matrixdotorg/dendrite-polylith"image repository
mediaapi.image.tagstringchart.appVersionimage tag
mscsobjectvalues.yamlConfiguration for experimental MSCs For more information see [the sample dendrite configuration](https://github.com/matrix-org/dendrite/blob/main/dendr

Deploy dendrite with OpenTenant

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