Eclipse Hono 1.1.1 Installed using Kubernetes - Probelm in Creating a Tenant

213 Views Asked by At

I have installed Eclipse Hono 1.1.1 Kubernetic cluster using Helm as per the below instructions.

https://hub.helm.sh/charts/eclipse-iot/hono

Initially I tried to create a tenant using the below command

curl -X POST "http://servername:28080/v1/tenants/DEFAULT_TENANT123" -H "accept: application/json" -H "Content-Type: application/json"

But then I got the Resource not found error.

And then as per the instructions in the How do i run curl command from within a Kubernetes pod

curl -X POST "http://ServiceName:Serviceport/v1/tenants/DEFAULT_TENANT123" -H "accept: application/json" -H "Content-Type: application/json"

Again it dint work..!!!

I tried the following command to enter into the device registry pod

 kubectl exec -it honohelmdeploy-service-device-registry-0 -- sh

And inside the device registry pod, I tried to run the above command and still it dint work.

I am not sure what should be the Host and Port while using the below command

curl -X POST "http://HOST:PORT/v1/tenants/DEFAULT_TENANT123" -H "accept: application/json" -H "Content-Type: application/json" 

I tried using device registry service name/ device registry pod name as hosts. I tried using device registry ports I tried using my server name / localhost as hosts.. I tried using 28080 as ports..

But I was not able to create a Tenant. Please assist.

Edited with the screeshot for kubectl get svc command enter image description here

1

There are 1 best solutions below

0
On BEST ANSWER

Ok, it seems like you have installed Hono to minikube without any loadbalancer running. You can see this from the EXTERNAL-IP column which contains <pending> for all of Hono's (externally visible) service endpoints.

You need to start minikube tunnel in order for these endpoints to be exposed via a loadbalancer as described in the chart's README. You should be able to run the minikube tunnel command either before or after having installed Hono to the cluster. Once the loadbalancer is running, the EXTERNAL-IP addresses should be bound and you should be able to access the service endpoints.