From fdc77f01212abddabe0ccc0d770feaf5e8802160 Mon Sep 17 00:00:00 2001
From: Erick Hitter <services@ethitter.com>
Date: Thu, 1 Sep 2016 23:54:45 -0700
Subject: [PATCH] Sync with upstream

22ef6f9
---
 automations/kitchen-light-timeout.yaml | 6 +++---
 configuration.yaml                     | 9 +++++++++
 scripts.yaml                           | 2 +-
 secrets.yaml                           | 2 ++
 4 files changed, 15 insertions(+), 4 deletions(-)

diff --git a/automations/kitchen-light-timeout.yaml b/automations/kitchen-light-timeout.yaml
index d4fd07d..1cae449 100644
--- a/automations/kitchen-light-timeout.yaml
+++ b/automations/kitchen-light-timeout.yaml
@@ -1,13 +1,13 @@
 alias: Turn off kitchen light after no motion
 trigger:
   - platform: state
-    entity_id: binary_sensor.kitchen
+    entity_id: switch.kitchen
     to: 'on'
 condition:
-  condition: or
+  condition: and
   conditions:
     - condition: state
-      entity_id: switch.kitchen
+      entity_id: binary_sensor.kitchen
       state: 'on'
 action:
   service: homeassistant.turn_on
diff --git a/configuration.yaml b/configuration.yaml
index 4d87869..0bdeefd 100644
--- a/configuration.yaml
+++ b/configuration.yaml
@@ -32,9 +32,18 @@ updater:
 # Enables the frontend
 frontend:
 
+# Set recorder options
+recorder:
+  # purge_days: 365
+  db_url: !secret mysql_recorder
+
 # Enables support for tracking state changes over time.
 history:
 
+# Save events to logentries service
+logentries:
+  token: !secret logentries_token
+
 # Discover some devices automatically
 discovery:
 
diff --git a/scripts.yaml b/scripts.yaml
index b6e8cc0..a51bff1 100644
--- a/scripts.yaml
+++ b/scripts.yaml
@@ -143,7 +143,7 @@ kitchen_light_timeout:
   alias: "Turn off kitchen light after 15 minutes of inactivity"
   sequence:
     - delay:
-        minutes: 15
+        minutes: 5
     - service: switch.turn_off
       data:
         entity_id: switch.kitchen
diff --git a/secrets.yaml b/secrets.yaml
index 2f623ad..24cc3cb 100644
--- a/secrets.yaml
+++ b/secrets.yaml
@@ -11,3 +11,5 @@ gravatar_chris:
 gravatar_chris_2:
 wunderground_key:
 wunderground_pws_id:
+logentries_token:
+mysql_recorder:
-- 
GitLab