I’m a total newbie and have started using the automation editor in the Hass.io web ui. An automation I made isn’t working; I’m trying to turn on a switch if my pi reboots between sunrise & sunset and the switch is off. It occurs to me that choosing ‘before sunrise’ is looking at this morning’s sunrise. is there a way to change it to something like ‘next_sunrise’? The automation works without the ‘before sunrise’ condition.
This is what it looks like now:
- action:
- delay: 00:03:00
- after: sunset
after_offset: 00:30:00
condition: sun
- before: sunrise
condition: sun
- condition: state
entity_id: switch.chickens
state: 'off'
- data:
entity_id: automation.coop_close
service: automation.trigger
alias: Reboot Night
condition: []
id: '1523244718205'
trigger:
- event: start
platform: homeassistant