Search code examples
home-automationhome-assistant

Homeassistant Timezone Sync


My raspi knows when EDT (Eastern US Daylight Time) is active,

HypriotOS/armv7: pirate@black-pearl in ~
$ date
Thu Oct 17 10:27:27 EDT 2019

the docker container for homeassistant knows when EDT is active,

root@black-pearl:/# date
Thu Oct 17 10:28:54 EDT 2019

but I cannot manage to get homeassistant v.0.100.2 to reflect this.

I've used

time_zone: EST

which does display the correct time if I were NOT in daylight savings.

Here's what else Ive tried:

  1. passing in the hosts time, which clearly works as evidenced by the docker containers console

    -v /etc/localtime:/etc/localtime
    
    -v /etc/timezone:/etc/timezone:ro
    
  2. Leaving blank in the hopes that freegeoip will solve this for me.

  3. Using time_zone: EDT instead of EST but it isn't recognized as a valid config.

Ultimately I'm not above lying to hass and telling it we're in America/Moncton (UTC - 4) and manually switching it back to EST (UTC - 5) the night before our transitions, but thats not really in the spirit of automation so I'd rather not.

Any help?


Solution

  • America/New_York
    

    SOLVED

    this worked. im a dingus. if i knew how to read and FOLLOW DIRECTIONS i would have read to use tz_database_name instead of its common abbreviation.

    credit to reddits u/kb5zuy