My continuous struggle with HADashboard

whats in the logs at that time?
are you trying it from the same subnet?
have you set any certification?
and you could probably try the complete path to the dirs in your config.
like

/home/pi/…

@bager if your using the addon from the following repository https://github.com/vkorn/hassio-addons , try port 3030 as described here https://github.com/vkorn/hassio-addons/tree/master/appdaemon and see if that makes a difference. cheers

@bager did you get this fixed? I’ve ran into the same problem as you.

@bager
I am not familiar with docker containers, but if it is a linux based something then it should be running ssh. And it can be managed through ssh. If you are running windows on your home computer Download putty from here: www.putty.org, and then start it. Type the IP of your HA machine and log in with your HA user account. After that just type
sudo netstat -tpan
and you should get a list of services listening on different ports. And if you can’t see 3030 or 5050 in the list then appdaemon is not listening anywhere. If you can see localhost by the 3030 or 5050 port then you will need to make changes to make it listen on 0.0.0.0.
If you are using a mac, then you can use the command line (terminal) where you can type ssh Ip_Of_Ha_device and then login with the HA user account.
tom

1 Like

Hey @towme ! Thanks a lot for that reply. I won’t say that it got ME closer, but it definetly showed that nothing is listening on the ports. So I guess that that is a step? How do I then make sure that it will begin listening to the port? And to @leighcurran, as you can see, I’m still having the same issue.

GUYS!!! I GOT IT TO WORK! Can’t believe it.

I’m not quite sure how, and what I did, but I copied the config (again) from the GutHub repository. (Here: https://github.com/vkorn/hassio-addons/blob/master/appdaemon/appdaemon-example.yaml)
The of course replaced it with own info.

And then I put the port in the config in my hass.io setup, and then it actually worked!

Well. Almost. When I go to http://URL:5050 i get the dashboard welcome. Perfect
But from there, the link to the actual dashboard doesn’t work. I have it set in the config as:

  dash_url: http://192.168.0.133

But that won’t make it go to the dashboard as it lacks the port. if I then manually type dash_url: http://192.168.0.133:5050/hello, it works fine. BUT. If I add the port in the config like this:

  dash_url: http://192.168.0.133:5050

Nothing works. That seems weird.
Well, I can make it work as I just type the URL manually, and it is not an issue as the dashboards are static in my situation. so no problem. Just weird IMO.

So grateful for you guys help. Its extremely nice that this community is so helpful towards the less technical of us!

You shouldn’t add the port in the config, because the port shows what service it is so it gets assigned automatically (well sort of). For example ssh usually listens on port 22, http on port 80, https on 443 and so on. The first 1024 ports a reserved and already sorted out for different services, but from 1025 - 65535 you can almost freely choose your favourite port for your own app. Baloob chose 5050 when he wrote the Appdaemon 2.0, also 3030 for appdaemon v1.x.
All this is means is that if your service is not running on the default port number (which above 1024 is usually the case) then you will have to add it manually after the IP address separated with a colon.
So the correct way should be that you put your IP into the config, and then add :5050 to the links in your dashboard configs. Also keep in mind that the name of dashboard should be added to the link when you try to open it.
You probably will want to have different dashboards for the lightning and the heating, so your urls will look like this: http://IP:5050/lights and http://IP:5050/heat

don’t lose faith in this project, keep up with the trying thats the way to go!

cheers
tom

Makes sense. And the same conclusion I came to.
No though, I have issues with the actual devices from HA not working in the dashboard. I came across a forum saying that it has something to do with nginx not being configured correctly. But when I install NGINX on hass.io it won’t start. So that makes it kind of hard to configure it. Do you happen to know anything about that?

1 big correction!!

Appdaemon isnt written by baloob but it is a creation from aimc (Andrew) :wink:

2 Likes

@ReneTode
Yeah, you’re right. Wrote the wrong name, sorry.
tom

1 Like

@bagger
Appdaemon is not yet able to use the nginx reverse proxy. So you are not able to configure it like HA.
Anyways you should get it running first on your home network without any extra software getting in the way.
If you are trying to access http://192.168.0.133:5050/hello, then it suggests that you are at home on your own wired / wireless network. Then you do not need nginx in the middle.
You only need nginx if you want to “hide” your HA machine and port from the eyes of others.
Ha listens on 8123 port, nginx listens on 80 or 443.
So bad people know that port 8123 is HA, and then they know how to attack your system, and if you are controlling locks, then it is not a good thing to have your house hacked. But if you are using nginx, then it seems that it is listenting on port 80/443 which is standard http(s), and it does not tell you what is the software behind it.

cheers
tom

Makes sense. I am only running it local and that is fine for me in the beginning. But someone just mentioned that the error I get when accessing the dashbord could be because of NGINX. But it seems from your answer that that is not the case. btw, the error that i get is a pop-up saying “error getting state, check Java Console for details” . And the light switch etc. that I added are not working. They just show a percentage that cannot be changed, and they are not able to turn the light on/off.

I am not a programmer, so please forgive the not exact terminology.
Appdaemon is linking into HA and communicating with it vica versa. So first you have to make sure that anything you try works in HA. Access your install with http://IP:8123, and see if the button, switch, sensor, etc. is there (you can see it). Then try to flip it manually, and see if it does what it is meant to do.
After that you can start creating your own dashboards, according to the readme on github

you can use nginx to see your dashboards outside your own network, with certs and you can password protect your dashboards.

This is probably hijacking, but
I have asked that question from Andrew (I know not baloob :slight_smile: ) just about a week ago, and he told me that it is not possible yet.
am I missing something?

i dont know what is not possible and what you actually want.
but these things are possible:

  • setting certs in AD or in NGINX
  • going from outside your network to AD for AD API or Dashboards
  • setting paswords for dashboards

those things are also in the docs and around for longer then a week.

http://appdaemon.readthedocs.io/en/latest/DASHBOARD_INSTALL.html

I have just ran through the link you’ve posted, but I can’t see where is nginx envolved there. It is only taking about appdaemon over ssl and password protecting it. (I haven’t found anything about proxying from port 443 to 5050.)
I thought that bagger was looking for something like this:

there is nothing about NGINX there because the docs are about AD.
i dont know if its possible to go from 433 to 5050 (i thought that was also possible)

setting up AD through nginx is off course completely different then setting up HA though nginx.

Sorry. Looks like today I am not that good with names :slight_smile: It is bager of course not bagger. Sorry again!

1 Like

No worries about the name @towme :wink:

I’m getting a bit confused about the nginx part. I have no need to acces the dashboard outside my own network at the moment, so if nginx is not required for jut normal local setup, then my bad. I might have gotten it confused. What I still can’t get to work though is, that in my normal HA panel (ie http://IP:8123) I can easily control all my components (lights, locks etc.) but when I add them on the HADashboard, they wont work. Then the system says the following error as I load the dashboard.

“error getting state, check Java Console for details”

I can see the components (ie. the lamps and locks etc), but nothing happens when I press them: