inverse / hassio-addon-emoncms

Home Assistant addon for running emoncms
MIT License
13 stars 4 forks source link

Port 9541 conflicts with TasmoAdmin HA Add-on #52

Open 42Network opened 2 years ago

42Network commented 2 years ago

Hello. It seems you chose the same port number 9541 as TasmoAdmin. I changed the port to 8541 in config settings, and the emoncms addon starts, but the link on the Info page for "Open Web UI" is hardcoded to 9541.

Can you make this "Open Web UI" link dynamic to automatically pickup the changed port number?

Thanks

inverse commented 2 years ago

Not aware of a way that can be done but I'll happily accept a pull request to change it.

I'm not entirely sure how to avoid port mapping conflicts - I know there is some ingress functionality that could be leveraged perhaps but I didn't dig much into that yet.

42Network commented 2 years ago

As a workaround, and to get EmonCMS to appear in the Homeassistant sidebar, I added a stanza in my configuration.yaml file for it, along with TasmoAdmin, thus:

panel_iframe:
  tasmoadmin:
    title: TasmoAdmin
    icon: mdi:lightbulb-on
    url: http://w.x.y.z:9541
  emoncms:
    title: EmonCMS
    icon: mdi:power-socket-us
    url: http://w.x.y.z:8541
42Network commented 2 years ago

Also, I think the hardcoded 9541 is on line 7 in file emoncms/config.json:

  "webui": "[PROTO:ssl]://[HOST]:[PORT:9541]",