Home Panel - A web frontend for controlling the home

Hi @NigelL,

Have you tried setting REACT_APP_HASS_SSL: 'false' instead of REACT_APP_HASS_SSL: 'true' in the environment variables?

See here for an example non-ssl setup: https://git.timmo.xyz/home-panel/setup/#non-ssl

Yes, that is set to false. Here’s the command line I used (well, mostly :slight_smile:)

sudo docker run -d --name=homepanel -e REACT_APP_HASS_HOST=‘192.168.0.253’ -e REACT_APP_HASS_PASSWORD=/mypassword/ -e REACT_APP_HASS_SSL=‘false’ -e REACT_APP_API_URL=‘http://localhost:3123’ -p 8234:80 -v /config/homepanel/config.json:/usr/src/app/config.json timmo001/home-panel

And here’s the relevant results of a set command in the container

REACT_APP_API_URL=‘http://localhost:3123
REACT_APP_HASS_HOST=‘192.168.0.253’
REACT_APP_HASS_PASSWORD=/mypassword/
REACT_APP_HASS_SSL=‘false’

And here’s the console log from Chrome

Connect to wss://192.168.0.253/api/websocket?latest

WebSocket connection to ‘wss://192.168.0.253/api/websocket?latest’ failed: Error in connection establishment: net::ERR_CONNECTION_REFUSED @ haws.es.js:1

Connection failed with code 1
(anonymous) @ Root.js:67

Hmm… This should work. Perhaps you are running an older version of the container?

Try running:

sudo docker pull timmo001/home-panel:latest

or change your docker command to use timmo001/home-panel:latest (or timmo001/home-panel:0.4.5 to be version specific)

Ran the command, and it came back with

latest: Pulling from timmo001/home-panel
Digest: sha256:9a71f61cc3fdc4e4b1dc9a80405f74a0c1f68280a2586a9456fd7eb3257f25b3
Status: Image is up to date for timmo001/home-panel:latest

Unfortunately, I don’t know react enough to even start debugging what’s happening in the app

Now, having said that I don’t know enough React to help debug, I do know javascript, and have played around a bit.

In one spot you use this to build the url (in connectToHASS)
const wsURL = `${process.env.REACT_APP_HASS_SSL ? ‘wss’ : ‘ws’}://

But in handleChange, the same part is built as follows
createConnection(`${process.env.REACT_APP_HASS_SSL === true ? ‘wss’ : ‘ws’}

I wonder if the first one should have the explicit compare to true as well.

I’ve extracted the Root.js file, made that change, copied it back in to the container and restarted it, and it works now.

1 Like

Yes I just noticed that. I’m implementing the fix now. I believe it’s to do with the environment variables being interpreted as strings instead of booleans, so it always returns true so ssl is enabled.

Release v0.4.6


Full Changelog

Changed

  • :fire: fix non-ssl hass setups

Thanks to @NigelL for the pointer on this. :crossed_fingers:it works for you now

Thanks @timmo001, looks good to me. Now I’ll have to play around with your actual work :smiley:

1 Like

Just an FYI everyone. This project is very much in it’s early stages. Lots of changes and fixes are coming. If you have any suggestions, feedback, bugs to report, enhancement ideas etc. feel free to open an issue on the git repository:

PS. The hassio addon is very close to a working state. I have a fix I want to get in to the app first before I officially release it to the world, but hang tight!

1 Like

Release v0.5.0


Full Changelog

Changed

  • :sparkles: Add new login system
  • :books: update docs to match new login system

This release overhauls the app to use a new login system using the API. You will need to move your config.json to the API instead of the webapp. Take a look at the docs for the new setup procedure.

1 Like

Thank you for sharing this with us and it is very amazing. I’ve been trying to get mine up and running but for some reason i’m having a little issue with the config file. My setup is on docker and when i try to access it, i’ve got this gray page:


I think that i’m doing something.

1 Like

Hi @mistrovly,

What do the logs say? If you open up the developer console with F12 on chrome you should see some errors which might help you fix your connection issues

Thank you for taking the time to reply to me.
Actually after a few restart and reinstalling the docker image, i was able to get to the login screen where i can create an account. But when i clicked on create account I got this error


I tried it with with the IP only and with the port number for HA and still nothing.

You may have to update the API. Run:

docker pull timmo001/home-panel
docker pull timmo001/home-panel-api

then run the containers again and see if this fixes your issue. This looks like a CORS issue which should have been fixed in v0.2.1 of the api

thank you for the fast reply. unfortunately that did not fix it. also when i ran the first command it’s telling me that is already up-to-date and i did pull a new version of the API.

Try running the containers again, then clear the cache/cookies in your browser. Hopefully this fixes it.

If you are still having issues, can you post the logs from the developer console and the docker logs if required. More info on this on the section I just added to the docs:

https://git.timmo.xyz/home-panel/troubleshooting/#before-posting-your-issue

Ok i’ll try that and thanks again

This is an awesome project !

Would it be possible to implement the following:

  • The ability to have multiple pages of entities
  • The possibility of adding an icon to each icon like the TileBoard project has
  • An alarm tile with an optional pin pad
1 Like

Hi @john1,

I like your ideas. If you have a GitHub account, feel free to add these in as individual issues here:

If you dont, I will add them later myself.

The only one that may be a bit of a concern is the pagination. Although, there may be a way to split groups up in the grid so they no longer scroll, but this could be done along the line once the higher priority tickets are done like the add-on etc.