Get alarm time from alexa

I don’t know either. I don’t believe you have to set it with the hassio image. That’s what I use. It’s not set with the commands used to install it.

EDIT: These are the commands. Nothing about datetime. My date isn’t screwed up so I would assume that you just need to set it in the OS and HA.

sudo -i
apt-get install software-properties-common
apt-get update
apt-get install -y apparmor-utils apt-transport-https avahi-daemon ca-certificates curl dbus jq network-manager socat
systemctl disable ModemManager
curl -fsSL get.docker.com | sh

Yes ok … i’ll try to check again when i’m at home

So right now :
Ubuntu OK
Docker … need to check
HA OK
Alexa App OK on the web app (i see America/Toronto for the device)

So if it’s not the time of docker or hassio it’s a bug of the plugin …

I don’t use hassio either. Just out of curiosity, what do you get when you enter the following into the Template Editor? (You can just tell me if they agree or not if you don’t want to share your time zone.)

{{ now().tzinfo }}
{{ now().astimezone().tzinfo }}

America/Newyork
EST

EDIT: Leads me to believe something is wrong with his setup then. But I’m not running on ubuntu, running on debian. But it should be the same crap.

Debian, Docker, Hassio here.

Yep, they would seem to agree.

BTW, I think you showed how you install stuff, but now how you run it. See the following comment from above:

I know I’ve seen many examples of people using docker and/or hassio and the time zone setting inside HA’s docker container was set incorrectly. I’m glad I haven’t messed with that stuff. :wink:

well, none of that is controlled by a hassio user.

EDIT: I Just noticed that he never specified hassio. Only docker and home assistant. So I think we found the cause. It’s his docker container not being started with @eifinger’s command.

1 Like

Actually I think he did…

well, then the only option could be incorrect install or the date not set in home assistant. As far as I know, hassio users have no control over how the docker containers run. Even on Ubuntu. I’m sure if users were experts in docker they could mess with it. But that doesn’t seem to be the case here.

When I asked him to do this:

{{ now().tzinfo }}
{{ now().astimezone().tzinfo }}

he got this:

America/Toronto
UTC

That clearly shows that the time zone setting in the context in which HA runs is wrong. I believe he claims that the time zone setting in the OS is correct. Unless he’s wrong, and the time zone setting in the OS is indeed wrong, then that only leaves the docker context to explain why he got UTC for the second expression.

Now, although that should be fixed (because it can lead to other issues), I’m not sure it’s really the reason for the problem noted in the OP. I think you’re probably right that it has more to do with the time zone setting in the Alexa app. Although he claims that’s right.

@arnaud, inquiring minds want to know… :slight_smile:

So… first sorry i’m a new user of the forum … and there is a limitation on how much a new user can post :frowning:

Yes i use hassio …

Yesterday i check again my config and the timezone of my host and HA, they are OK.
So it’s hassio or a bug with the component i use.

No worries.

So although you do need to eventually figure out why the time zone isn’t set correctly in docker (because it can cause other issues), according to @petro’s post about the code, which I reviewed, it does seem like the more likely reason is due to the time zone setting in the “app”, whatever that is. Did you check to see if the warning mentioned was in your logs?

            _LOGGER.warning(
                "%s does not have a timezone set. "
                "Returned times may be wrong. "
                "Please set the timezone in the Alexa app.",
                self._client.name,
            )

EDIT: Or maybe it’s just wrong? I think you said you checked that, but…