#307 and a little something extra.

This commit is contained in:
ccostan 2018-01-31 22:17:09 -05:00
parent 32cbbeec34
commit 8442b1a384
2 changed files with 33 additions and 5 deletions

View File

@ -16,14 +16,33 @@ sensor:
name: Bear Stone name: Bear Stone
server: !secret minecraft server: !secret minecraft
#------------------------------------------- #-------------------------------------------
# group: group:
# finance: Minecraft:
# entities: entities:
# - sensor.tesla - sensor.bear_stone
# - sensor.bitcoin
############################################################################## ##############################################################################
### Automations - Detect when things are not right. Like any Good Watchdog. ### Automations - Detect when things are not right. Like any Good Watchdog.
############################################################################## ##############################################################################
#automation: #automation:
#Tweets pushed out to twitter. #Tweets pushed out to twitter.
automation:
- alias: Someone on the MC server!
trigger:
- platform: state
entity_id: sensor.bear_stone
condition:
- condition: template
value_template: >
{% if not is_state('sensor.bear_stone', '0/10') %}
false
{% else %}
true
{% endif %}
action:
- service: script.notify_engine
data_template:
value1: "The following users are online: {{ states.sensor.bear_stone.attributes.users_online }}"
who: 'carlo'

View File

@ -148,6 +148,15 @@ automation:
- sensor.network - sensor.network
- binary_sensor.carlowink - binary_sensor.carlowink
condition:
- condition: template
value_template: >
{% if not is_state('sensor.network_detail', ' ') %}
false
{% else %}
true
{% endif %}
action: action:
- service: script.notify_engine - service: script.notify_engine
data_template: data_template: