emqx-enterprise
by EMQX
A Helm chart for EMQX
About this chart
Introduction
This chart bootstraps an emqx deployment on a Kubernetes cluster using the Helm package manager.
Prerequisites
- Kubernetes 1.6+
- Helm
Installing the Chart
To install the chart with the release name my-emqx:
-
From Github
$ git clone https://github.com/emqx/emqx.git $ cd emqx/deploy/charts/emqx-enterprise $ helm install my-emqx . -
From chart Repos
helm repo add emqx https://repos.emqx.io/charts helm install my-emqx emqx/emqx-enterpriseIf you want to install an unstable version, you need to add
--develwhen you execute thehelm installcommand.
Uninstalling the Chart
To uninstall/delete the my-emqx deployment:
$ helm del my-emqx
Configuration
The following table lists the configurable parameters of the emqx chart and their default values.
| Parameter | Description | Default Value |
|---|---|---|
replicaCount | It is recommended to have odd number of nodes in a cluster, otherwise the emqx cluster cannot be automatically healed in case of net-split. | 3 |
image.repository | EMQX Image name | emqx/emqx-enterprise |
image.pullPolicy | The image pull policy | IfNotPresent |
image.pullSecrets | The image pull secrets | [] (does not add image pull secrets to deployed pods) |
serviceAccount.create | If true, create a new service account | true |
serviceAccount.name | Service account to be used. If not set and serviceAccount.create is true, a name is generated using the full-name template | |
serviceAccount.annotations | Annotations to add to the service account | |
envFromSecret | The name pull a secret in the same Kubernetes namespace which contains values that will be added to the environment | nil |
recreatePods | Forces the recreation of pods during upgrades, which can be useful to always apply the most recent configuration. | false |
podAnnotations | Annotations for pod | {} |
podManagementPolicy | To redeploy a chart with existing PVC(s), the value must be set to Parallel to avoid deadlock | Parallel |
persistence.enabled | Enable EMQX persistence using PVC | false |
persistence.storageClass | Storage class of backing PVC | nil (uses alpha storage class annotation) |
persistence.existingClaim | EMQX data Persistent Volume existing claim name, evaluated as a template | "" |
persistence.accessMode | PVC Access Mode for EMQX volume | ReadWriteOnce |
persistence.size | PVC Storage Request for EMQX volume | 20Mi |
initContainers | Containers that run before the creation of EMQX containers. They can contain utilities or setup scripts. | {} |
resources | CPU/Memory resource requests/limits | {} |
extraVolumeMounts | Additional volumeMounts to the default backend container. | [] |
extraVolumes | Additional volumes to the default backend pod. | [] |
nodeSelector | Node labels for pod assignment | {} |
tolerations | Toleration labels for pod assignment | [] |
affinity | Map of node/pod affinities | {} |
service.type | Kubernetes Service type. | ClusterIP |
service.mqtt | Port for MQTT. | 1883 |
service.mqttssl | Port for MQTT(SSL). | 8883 |
service.ws | Port for WebSocket/HTTP. | 8083 |
service.wss | Port for WSS/HTTPS. | 8084 |
service.dashboard | Port for dashboard and API. | 18083 |
service.customPorts | Custom Ports to be exposed in the Service. | {} |
service.nodePorts.mqtt | Kubernetes node port for MQTT. | nil |
service.nodePorts.mqttssl | Kubernetes node port for MQTT(SSL). | nil |
service.nodePorts.ws | Kubernetes node port for WebSocket/HTTP. | nil |
service.nodePorts.wss | Kubernetes node port for WSS/HTTPS. | nil |
service.nodePorts.dashboard | Kubernetes node port for dashboard. | nil |
service.customNodePorts | Kubernetes node port for custom ports. | {} |
service.loadBalancerClass | The load balancer implementation this Service belongs to | |
service.loadBalancerIP | loadBalancerIP for Service | nil |
service.loadBalancerSourceRanges | Address(es) that are allowed when service is LoadBalancer | [] |
service.externalIPs | ExternalIPs for the service | [] |
service.externalTrafficPolicy | External Traffic Policy for the service | Cluster |
service.annotations | Service/ServiceMonitor annotations | {}(evaluated as a template) |
service.labels | Service/ServiceMonitor labels | {}(evaluated as a template) |
ingress.dashboard.enabled | Enable ingress for EMQX Dashboard | false |
ingress.dashboard.ingressClassName | Set the ingress class for EMQX Dashboard | |
ingress.dashboard.path | Ingress path for EMQX Dashboard | / |
ingress.dashboard.pathType | Ingress pathType for EMQX Dashboard | ImplementationSpecific |
ingress.dashboard.hosts | Ingress hosts for EMQX Dashboard | dashboard.emqx.local |
ingress.dashboard.tls | Ingress tls for EMQX Dashboard | [] |
Deploy emqx-enterprise with OpenTenant
Each tenant gets its own release of this chart, with its own namespace, secrets and domain. The builder below already has emqx-enterprise 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.
- Pick a serverConnect Hetzner, OVHcloud or AWS. The builder starts on Hetzner, the cheapest sample rate.
- Place the chartemqx-enterprise is pinned at v6.3.3 in opentenant.yaml. Drag more apps from the marketplace onto a rack.
- 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