# Newbie here using Hassio

**URL:** <https://discourse.nodered.org/t/newbie-here-using-hassio/6362>\
**Category:** General\
**Created:** [3 January 2019 17:21 UTC](https://discourse.nodered.org/t/newbie-here-using-hassio/6362 "2019-01-03T17:21:45Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![Derekwit](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/derekwit/32/4900_2.png) [@Derekwit](https://discourse.nodered.org/u/Derekwit)\
**Post date:** [3 January 2019 17:21 UTC](https://discourse.nodered.org/t/newbie-here-using-hassio/6362/1 "2019-01-03T17:21:45Z")

</div>

I am trying to get some directions or guidance on how to setup some automations in Node Red that will work in Hassio. I have been stumbling through yaml and made a couple of automations that worked and now are no longer working. i was hoping to test in Node Red but little "Green" to say the least. I have (4) device\_trackers that I track their location and complete automation when they arrive home. Any suggestions would be great. I have attached code in yaml.

```auto
- id: '1536977150329'
  alias: Open Garage Door
  trigger:
  - platform: state
    entity_id:
      - device_tracker.xxxx
      - device_tracker.xxxx
      - device_tracker.xxxx
  condition:
  - condition: state
    entity_id: cover.my_house
    state: closed
  action:
  - entity_id: cover.my_house
    service: cover.open_cover
    
    
- id: '1536977383518'
  alias: Close Garage Door
  trigger:
  - entity_id: device_tracker.xxxx
    platform: state
    to: home
    for:
      minutes: 5
  - entity_id: device_tracker.xxxx
    platform: state
    to: home
    for:
      minutes: 5
  - entity_id: device_tracker.xxxx
    to: home
    for:
      minutes: 5
  condition:
  - condition: template
    value_template: '{{(as_timestamp(now()) - as_timestamp(states.device_tracker.xxxx.last_changed | default(0)) | int > 300 ) and (as_timestamp(now()) - as_timestamp(states.device_tracker.xxxx.last_changed | default(0)) | int > 300 ) and (as_timestamp(now()) - as_timestamp(states.device_tracker.xxxx.last_changed | default(0)) | int > 300 )}}'
  - condition: state
    entity_id: cover.my_house
    state: open
  action:
  - entity_id: cover.my_house
    service: cover.close_cover

```

---

<div class="post-metadata">

**Author:** ![knolleary](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/knolleary/32/3_2.png) [@knolleary](https://discourse.nodered.org/u/knolleary)\
**Post date:** [3 January 2019 17:53 UTC](https://discourse.nodered.org/t/newbie-here-using-hassio/6362/2 "2019-01-03T17:53:52Z")

</div>

Hi @Derekwit, I can't help with the specifics of your question, but I recommend you read this post about sharing code on the forum: [How to share code or flow json](https://discourse.nodered.org/t/how-to-share-code-or-flow-json/506). You may have noticed your YAML has been treated as markdown and completely reformatted by the forum.
