Ingress static files issue with third party addon (homebridge)

Goodmorning,

I am trying to have a custom addon (homebridge) work with ingress. The addon itself installs by a git repo and it is accessible when i expose the port. But when i try to use ingress it doesn’t work. After checking the developer tools in the browser i see the .js files served are the wrong path and pointing to the HA root itself. When i check my browser url i can see the ingress: https://xxx.xxx.xxx.xxx/229f9685_homebridge/dashboard

Anyone has experience with this? How can i tell the script files in the header of the html should point into the ingress url? On both the internal as the external url the issue exists.

Hi, you can use sed to replace all instances in js files of / with ./ !
I did that for my scrutiny addon and it worked.

Code : grep -rl '/web/' /app/scrutiny-web/ | xargs sed -i 's|/web/|./|g'

Search for all files containing /web/ in the directory /app/scrutiny-web/, then replace all instances of /web/ with ./

You’ll just need to customize it to your needs and add it to your dockerfile

1 Like

Thanks for the answer, will test how this will work and come back!!

2 Likes