wubbl0rz / FiatChamp

FIAT (uconnect) Home Assistant Addon 🚗
https://github.com/wubbl0rz/FiatChamp
MIT License
91 stars 17 forks source link

SupervisorToken in standalone mode #29

Closed thomasbeaumont closed 1 year ago

thomasbeaumont commented 1 year ago

Hi and thanks for the awesome work!

I am having trouble with my standalone install, looks like my car gets found but if I don't specify the URL of my hass server, it defaults to:

http://supervisor/core/api/states

If I specify it adding it to the env variables, I get a 401 as api/states is protected.

Is it possible to generate a token to grant access to HASS standalone?

Cheers,

Thomas

thomasbeaumont commented 1 year ago

Ok sorry I found out what to modify. What you indicate in post 22 needs to be completed by adding the FiatChamp_HomeAssistantUrl variable, generate a long live token and replace yours by the one generated.

wubbl0rz commented 1 year ago

@thomasbeaumont can you post a example of your docker compose ? then i can update the readme.

thomasbeaumont commented 1 year ago

Hi @wubbl0rz thanks for this awesome integration, it works perfectly. I don't have a docker-compose file, just lazily deployed your image using portainer.

Here is the ENV I used:

STANDALONE=True FiatChamp_FiatUser=xxx@xxx.xxx FiatChamp_FiatPw=yyyyyyy FiatChamp_FiatPin=WXYZ FiatChamp_MqttUser=user1 FiatChamp_MqttPw=user1pass FiatChamp_MqttServer=192.168.X.X FiatChamp_MqttPort=1883 FiatChamp_SupervisorToken=mylonggeneratedlonglivetokenforyourapp FiatChamp_HomeAssistantUrl=http://internalhassip:8123

This works perfectly on a standalone home assistant, with separate MQTT + MQTT broker plugin and your image.

I hope this helps