thingsboard

by Helm

Helm chartv0.1.2App 2.2Apache-2.0

A Helm chart for Kubernetes

About this chart

helm-thingsboard

ThingsBoard is an open-source IoT platform for data collection, processing, visualization, and device management.

Introduction

This Helm chart installs thingsboard in a Kubernetes cluster.

Prerequisites

  • Kubernetes cluster 1.10+
  • Helm 3.0+
  • PV provisioner support in the underlying infrastructure.

Thingsboard

Thingsboard enables device connectivity via industry standard IoT protocols - MQTT, CoAP and HTTP and supports both cloud and on-premises deployments. ThingsBoard combines scalability, fault-tolerance and performance so you will never lose your data.

RabbitMQ

RabbitMQ is an open source message broker software that implements the Advanced Message Queuing Protocol (AMQP).

ThingsBoard is able to use various messaging systems/brokers for storing the messages and communication between ThingsBoard services, this helm Chart uses RabbitMQ.

RabbitMQ is recommended if you don’t have much load and you already have experience with this messaging system.

we're using bitnami/rabbitmq helm chart. for more info about how to use it, please check the documentation .

Configure the chart

The items of section Configuration can be set via --set flag during installation or change the values according to the need of the environment in helm-thingsboard/values.yaml file.

Configure the way how to expose thingsboard service:

  • Ingress: The ingress controller must be installed in the Kubernetes cluster.
  • ClusterIP: Exposes the service on a cluster-internal IP. Choosing this value makes the service only reachable from within the cluster.
  • NodePort: Exposes the service on each Node’s IP at a static port (the NodePort). You’ll be able to contact the NodePort service, from outside the cluster, by requesting NodeIP:NodePort.
  • LoadBalancer: Exposes the service externally using a cloud provider’s load balancer.

Installation

Access a Kubernetes cluster.

Add Helm repo:

helm repo add cetic https://cetic.github.io/helm-charts

Update the list helm chart available for installation (like apt-get update). This is recommend before install/upgrade a helm chart:

helm repo update
helm dep up

Change the values according to the environment in the file values.yaml.

Install the thingsboard helm chart with a release name my-release:

helm install my-release cetic/thingsboard

View the pods.

kubectl get pods

Uninstallation

To uninstall/delete the thingsboard deployment:

helm delete my-release

How to access thingsboard

After deploying the chart in your cluster, you can use the following command to access the thingsboard frontend service:

minikube service <my-release>-thingsboard

Configuration

The following tables lists the configurable parameters of the chart and their default values.

KeyTypeDefaultDescription
affinityobject{}Affinity configurations
ingress.annotationsobject{}Ingress annotations
ingress.enabledboolfalseEnables Ingress
ingress.hostslist[{"host":null,"paths":[]}]Ingress hosts
ingress.tlslist[]Ingress TLS configuration
nodeSelectorobject{}nodeSelector configurations
rabbitmq.enabledbooltrueenable rabbitmq
rabbitmq.auth.usernamestring"admin"userName of rabbitmq
rabbitmq.auth.passwordstring"password1"Password of rabbitmq
rabbitmq.ldap.enabledboolfalseenable/disable ldad for user authentication
rabbitmq.ldap.serverstringmy-openldapldap server adress
rrabbitmq.ldap.portint389ldap server port
rabbitmq.ldap.user_dn_patternstringcn=${username},dc=example,dc=orgldap user dn pattern
readinessProbe.enabledbooltrueenable/disbale ReadinessProbe
readinessProbe.initialDelaySecondsint60Specifies the number of the readinessProbe's delay seconds
readinessProbe.periodSecondsint7readinessProbe's period seconds
TB_RABBIT_MQ.TB_QUEUE_TYPEstring"rabbitmq"ThingsBoard QUEUE TYPE
TB_RABBIT_MQ.TB_QUEUE_RABBIT_MQ_USERNAMEstring"admin"rabbitmq's username
TB_RABBIT_MQ.TB_QUEUE_RABBIT_MQ_PASSWORDstring"password1"rabbitmq's password
TB_RABBIT_MQ.TB_QUEUE_RABBIT_MQ_HOSTstring"rabbitmq"rabbitmq's host
TB_RABBIT_MQ.TB_QUEUE_RABBIT_MQ_PORTint5672rabbitmq's port

Uninstallation

To delete the thingsboard release:

helm delete my-release

License

Apache License 2.0

Deploy thingsboard with OpenTenant

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