ualex73 / monitor_docker

Monitor Docker containers from Home Assistant
Apache License 2.0
267 stars 34 forks source link

Feature Request: Expose port for each container #115

Closed philipjholm closed 1 month ago

philipjholm commented 1 year ago

Is there any way to get the port number for each container. If that is not possible today, would it be possible to add? Seems like a very important thing to be able to link to each container.

RoboMagus commented 10 months ago

This information is available in the docker container inspect ... command, so I guess this plugin would be able to access that data. However this can be any number of port mappings (source, target, TCP/UDP) to the host interface, or only internally exposed. That's not something that is trivially exposed as a single sensor value.

I'm curious though why you'd like this information available in HomeAssistant sensors? As these values basically never change once configured there's nothing dynamic that can be done with it.

ualex73 commented 1 month ago

As @RoboMagus asks, it is a curious request. The port information is not something that should be in this integration, so I will close this ticket.