Closed rbarberop closed 1 year ago
@rbarberop
Thank you for submitting this PR. Before merging, I would like to gain a better understanding of your use case to ensure we improve the documentation accurately. I'm curious about how you connected Edge instances to ThingsBoard CE deployed as a monolith or using microservices without an external load balancer. Did you also deploy ThingsBoard Edge instances within the Kubernetes cluster?
By understanding your use case, we can ensure the appropriate changes are made and provide more comprehensive guidance for other users in similar situations.
Hi @volodymyr-babak , thanks for taking a look at this.
The issue happens in both cases, monolith or microservices. And it's independent of which K8s cluster they are deployed in (same cluster for demo purposes or different clusters for MVP with a customer).
With the current configuration, Thingsboard CE does not expose port 7070, which means that any Thingsboard Edge instance can't connect.
I just added port 7070 to be exposed in the service to fix the issue.
@rbarberop, thank you for providing additional details.
Currently, the tb-node container exposes port 7070:
I am in the process of working on a pull request to add a new Edge TCP service of type LoadBalancer: https://github.com/thingsboard/thingsboard-ce-k8s/pull/93/files
After deploying this LoadBalancer service to my GCP cluster, I successfully connected a ThingsBoard Edge instance running on my local PC to a ThingsBoard CE server running in a Kubernetes cluster within GCP.
Here are the steps in the documentation I followed to obtain the IP address of the Edge load balancer:
The tb-node service you modified is of type ClusterIP and does not provide an external IP address. I am wondering how ThingsBoard Edge would connect to ThingsBoard CE in this case. I might be missing something, and I am trying to understand the missing part at the moment.
You are correct, the config I uploaded would only work in the demo use case, where both are deployed in the same K8s cluster.
Yes, the container exposes the port 7070 but then it was not connected to any service, that's what I was adding with this PR.
Given that you are already going to cover this with your PR (and that the version of Edge in this PR is already old), I'll close it in favor of yours.
Thanks for taking the time to check it out.
With the yaml as it was, port 7070 was not exposed in the tb-node service.
Thingsboard Edge instances could not communicate with Thingsboard CE deployed that way.
Adding port 7070 to the service fixes the issue.