Rbillon59 / hass-n8n

Home assistant addon to host a n8n.io instance
Apache License 2.0
44 stars 15 forks source link

Invalid n8n OAuth Redirect URL #17

Closed blackbasilisk closed 1 year ago

blackbasilisk commented 1 year ago

Hey man, Great work on the add-on!! Thank you for making this available to the world :)

When adding a workflow that uses Google OAuth, the system auto completes the OAuth callback URL. It defaults to using localhost, which doesn't seem to work when using HA because it's not technically on localhost. Is there a way to set it to use the ip address/hostname of the HA instance ? Either via configuration value or perhaps the n8n installation getting the hostname of the HA instance and then always using that ? Hope that makes sense.. see image below: image

When authenticating the following happens when submitting auth via google consent screen: image

blackbasilisk commented 1 year ago

It seems possible to set the base URL , but seems to need some work... https://docs.n8n.io/hosting/environment-variables/configuration-methods/#base-url

I can try look at this and submit PR, but I might take a while to get up to speed with manipulating things to get it to work like this.. I'm still a proper Docker noob nevermind even creating HA integrations :P

Rbillon59 commented 1 year ago

Hey ! Thank you for your kind words !

I did not expected the pr to close the issue, could you update your addon and set the "webhook_tunnel_url" var please ?

Rbillon59 commented 1 year ago

Did you check it's fixing your issue ?