Page 1 of 1

request mosquitto MQTTT hardware plugin

Posted: Wednesday 16 June 2021 17:48
by pvklink
Hi,

Is it possible to accept 127.0.0.1 as a MQTT connection in de MQTT hardware plugin to the localhost instead of hardcoded ipadress ?

Re: request mosquitto MQTTT hardware plugin

Posted: Wednesday 16 June 2021 20:16
by waltervl
To be sure: did you try it to use 127.0.0.1 as IP address instead of localhost in the MQTT hardware configuration?
And the conclusion was that it did not work?
And what if you fill in the IP address of your Domoticz server?

Re: request mosquitto MQTTT hardware plugin

Posted: Wednesday 16 June 2021 21:00
by pvklink
localhost and 127.0.0.1 dont work.
Using an harded coded ip adres is just my point...you want to avoid that if possible..
In my cases the mqtt server is always on the same rpi (one of 5) as domoticz.
When updating my images, container and sometime volumes you dont want a lot of configure actions.
When i copy my test environment to my production environment, i want to set one variable...test or production
I am almost there!
In the past i was two days buyi to configure about 10 environments on 5 rpi's
Now i have one software stack with volumes, docker compose and dockerfiles.. some clicks in a menu, anf after 15minutes everything is working

Re: request mosquitto MQTTT hardware plugin

Posted: Wednesday 16 June 2021 21:35
by waltervl
localhost used to work. Is mosquitto listening to localhost? You can check this with mosquito_pub

Edit: localhost within a Domoticz docker will only look to mosquitto in the Domoticz docker. Mosquito is on another docker...

Re: request mosquitto MQTTT hardware plugin

Posted: Monday 21 June 2021 15:25
by waltervl
pvklink wrote: Wednesday 16 June 2021 21:00 localhost and 127.0.0.1 dont work (Edit: on docker.....)
Does it work now?
Edit: found this as possible solution (do not know if it is still valid (2014) )
https://stackoverflow.com/questions/243 ... f-the-mach

Re: request mosquitto MQTTT hardware plugin

Posted: Monday 21 June 2021 15:57
by Dave21w
Not sure why yours doesn't work, I've never used anything else
hardware.jpg
hardware.jpg (88.37 KiB) Viewed 566 times
Edit: Sorry didn't realise we were talking about docker.