Comments (8)
That's a docker limitation, not a problem with Zigbee2Mqtt.
When using the address 127.0.0.1
, you're resolving this in your container namespace, not on the host itself, which is elsewhere.
You can name your containers using --hostname mqttserver
and use this name instead to read your MQTT server.
from zigbee2mqttassistant.
Hmm don't think this should be closed. This is still very much a limitation of this container.
Your solution requires me to go ahead and update all of my other containers and internal DNS, because I can't use the host network with this container. The only reason I can't use the host network, is because I can't change the HTTP port from 80 to something else.
Unfortunately Docker runs on many types of systems. And sometimes there are reasons why assigning a hostname to a container can't work (one of those is when the MQTT container is using the host network for another reason entirely)
So for now the "fix" is to go ahead and update all my other Docker containers to point to the MQTT hostname. Seems quite the wrong way to do it.
from zigbee2mqttassistant.
That did it!
Thanks
from zigbee2mqttassistant.
It worked for me when I gave it the "public" ip of the host that's running mqtt. For example: Z2MA_SETTINGS__MQTTSERVER=192.168.1.2
from zigbee2mqttassistant.
That's odd.
No tests has been done right now with --net=host
because it's not required by this software to have a direct access to your network.
Let's me try it on my side.
I'm glad it's working on Synology NAS ;-). What is the CPU architecture ? Intel or ARM ?
from zigbee2mqttassistant.
@philhawthorne Did you try with latest version, now using the alpine images?
from zigbee2mqttassistant.
@carldebilly is it possible to change the HTTP port this service is exposed on from something other than 80?
Right now I can't use --net=host
for this container because port 80 is used by the Synology Admin Panel. If I can tel this service to be exposed on another port, then I can use --net=host
to expose this to my network, and not conflict with Synology.
from zigbee2mqttassistant.
Yep it is possible. As described in another issue #67, you can use the following method:
To set port tcp/5000 for http, use the following environment variable:
ASPNETCORE_URLS=http://*:5000
Please close the issue if it fixes your problem :-).
from zigbee2mqttassistant.
Related Issues (20)
- Setting the base_topic for the docker image? HOT 2
- Devices are recognized but stated as "No components" [BUG] HOT 12
- unresponsive s. X hours vs. MQTT last_seen HOT 1
- [BUG]Unable to connect to MQTT server mqtt HOT 23
- Bug after HA last update HOT 12
- unable to connect to mqtt server HOT 9
- Don't show "NO COMPONENTS" error if not running as a HomeAssistant instance. HOT 1
- Network Map not working HOT 5
- Zigbee2MqttAssitant unable to connect to mqtt server HOT 3
- Use more of the available screen space (especially in the map view)
- Longer timeout before showing as unresponsive
- [BUG] Sengled E21-N1EA reporting not supported HOT 4
- [BUG] Issue with Sonoff SNZB-02 unresponsive HOT 1
- [BUG] Slae.sh CC2652RB stick is not listed in device tab of zigbee2mqttAssistant HOT 1
- System.InvalidCastException: Null object cannot be converted to a value type. HOT 1
- [BUG] only partial connection to z2m HOT 5
- Thanks for this project
- releases needed to track changes
- [BUG] Cannot download lasted Docker image and Z2MA not linking to Z2M
- [BUG] crashes when the network drops HOT 2
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from zigbee2mqttassistant.