/homeassistant

Example Home Assistant Configs

Primary LanguageShell

Overview

My personal Home Assistant configurations with 300+ automations. These are my active automations and configurations that I use every day. Updated frequently as I add more devices and come up with more and more complicated ways to do simple tasks.

Published configruations working with Home Assistant Version: 0.96.1

Menu

| Hubs | Lighting | Climate| Outlets & Switches| Locks | Security | Voice Assistant | Media | Sensors | Cameras | Garage | Vacuum | Network | Other Hardware | Retired Devices | Software | Screenshots |

Hubs

| Go to Menu |

Device Quantity Connection Home Assistant Notes
Hue Hub v2 1 Ethernet Philips Hue Used to control all Zigbee smart bulbs
Lutron Smart Bridge 2 1 Ethernet Lutron Caseta Used to control Lutron Caseta light switches and dimmers
Vera Plus 1 Ethernet Vera Used as a dumb hub to connect Z-Wave devices.

Relevant hub configurations can be found within configuration.yaml

Lighting

| Go to Menu | Home Screenshot |

Device Quantity Connection Home Assistant Notes
Philips Hue White and Color Ambiance 9 Ethernet Philips Hue Light Color changing smart bulbs
Philips Hue White and Color Ambiance LightStrip Plus Dimmable 1 Hue Hub (Zigbee) Philips Hue Light Color changing smart led strip. Used as accent lighting
Philips Hue White 5 Hue Hub (Zigbee) Philips Hue Light Non color changing smart bulbs
Cree Connected 8 Hue Hub (Zigbee) Philips Hue Light Non color changing smart bulbs
Lutron Caseta Wireless Dimmer 17 Lutron Clear Connect Lutron Caseta Light Smart dimmer switches that do not require a neutral wire
Lutron Caseta Wireless Lighting Switch 2 Lutron Clear Connect Lutron Caseta Switch Smart on / off light switches
Lutron Caseta Pico Wireless Dimmer Switch 4 Lutron Clear Connect Lutron Caseta Light Decora wall mountable remote (that looks like a dimmer switch). Controls various lights

Many of my automations rely on some form of lighting but many examples can be found in lights.yaml and location.yaml.

Lights are grouped via light_group.yaml

Climate

| Go to Menu | Weather Screenshot |

Device Quantity Connection Home Assistant Notes
Ecobee 3 1 Wi-Fi ecobee / Ecobee Thermostat Used as primary thermostat
Ecobee Room Sensor 9 Ecobee3 Ecobee Binary Sensor Provides room temperature and room occupancy.
Dyson Pure Hot + Cool Link 1 Wi-Fi Dyson Dyson Fan with Heater and Air Purifier

I utilize a number of automations that adjust climate controls. Mostly they can be found in climate.yaml. Ecobee room sensors are heavily used in occupancy.yaml and as conditions in many automations

Outlets & Switches

| Go to Menu | Home Screenshot |

Device Quantity Connection Home Assistant Notes
Wemo Mini Smart Plug 4 Wi-Fi Belkin WeMo Smart outlets utilized to control various devices via powering the outlet on/off (fans, Christmas Tree, etc)
Wemo Insight Smart Plug 1 Wi-Fi Belkin WeMo Smart outlet utilized to monitor power to washing machine
GE Z-Wave Wireless Smart Lighting Control Outdoor Module 3 Vera Plus (Z-Wave) Vera Switch Used to control low voltage outdoor lighting transformers
Remotec Zwave Dry Contact Fixture Module 1 Vera Plus (Z-Wave) Vera Switch Used to control gas fireplace
Dome Home Automation Water Shut-Off Valve 1 Vera Plus (Z-Wave) Vera Switch Used to shut off Water Main Supply to House in the event of water leak detected or while on Vacation

Switches and outlets are used in various capacities, some are for lighting and some are for fans type devices. lights.yaml and occupancy.yaml should have some good examples.

Washing machine is automated around the Wemo Insight Plug. This outlet can monitor power consumption, I created a sensor based on the power reading that shows a simple status of running or not running thus automating around that sensor.

Locks

| Go to Menu | Automation Screenshot |

Device Quantity Connection Home Assistant Notes
Schlage Connect Touchscreen Deadbolt 3 Vera Plus (Z-Wave) Vera Lock Smart locks used in automations to auto lock / unlock doors

Locks are used mostly as a way to lock / unlock doors based on locations, see location.yaml and locks.yaml for some examples

Security

| Go to Menu | Automation Screenshot |

Device Quantity Connection Home Assistant Notes
GoControl Door/Window Sensor 3 Vera Plus (Z-Wave) Vera Binary Sensor Door sensors to detect if exterior doors have been opened / closed
GoControl Siren and Strobe 1 Vera Plus (Z-Wave) Vera Switch Alarm used for when alarm is triggered or when you want to get someone's attention

Door sensors are used in many different ways. I trigger on them via doors.yaml, use them for security in security.yaml, and as various conditions in notification_audio.yaml and climate.yaml. The alarm siren is used in security.yaml and in the security scene. I've also implemented the alarm as part of water_sensors.yaml.

Voice Assistant

| Go to Menu |

Device Quantity Connection Home Assistant Notes
Amazon Echo 1 Wi-Fi Emulated Hue Bridge Audio only Voice Assistant
Amazon Echo Dot 6 Wi-Fi Emulated Hue Bridge Audio only Voice Assistant
Amazon Echo Spot 1 Wi-Fi Emulated Hue Bridge Voice Assistant with small display
Amazon Echo Show 1 Wi-Fi Emulated Hue Bridge Voice Assistant with display

I go for native Echo integration wherever possible, but a few devices are not currently supported where I've had to implement some work arounds via emulated hue. Most of these are just exposed via an input_boolean and customize.yaml. This allows the ability to have echo turn on or off an input_boolean in turn triggering an automation.

Media

| Go to Menu | Media Screenshot |

Device Quantity Connection Home Assistant Notes
Apple TV 4k 2 Wi-Fi Apple TV Used for media playback on 4k TVs
Apple TV 4 2 Wi-Fi Apple TV Used for media playback on TVs
Sonos Play:1 10 Wi-Fi Sonos Audio playback and Home Assistant TTS
Sonos Connect 1 Ethernet Sonos Audio playback and Home Assistant TTS. Connects Sonos to existing surround sound system
Sonos Connect:AMP 1 Wi-Fi Sonos Audio playback and Home Assistant TTS. Connects Sonos to outdoor speakers
Lutron Caseta Pico Remote Control for Audio 2 Lutron Clear Connect Lutron Caseta Decora wall mountable remote. Used to control Sonos
Logitech Harmony Hub 3 Wi-Fi Harmony Hub Remote Controls various AV equipment and other devices that utilize infrared remotes
Yamaha RX-V483BL 1 Wi-Fi Yamaha Network Receivers Surround Sound Receiver. Works in conjunction with the Sonos Connect, Harmony Hub, Apple TV 4k and various other media devices
Plex Media Server 1 Ethernet Plex / Plex Activity Monitor Media Server

Most media player based automations can be found in media.yaml and some Text to Speech (TTS) based automation in notification_audio.yaml .

Harmony Hubs work via a combination of input_selects, scripts, and automations in media.yaml.

Sensors

| Go to Menu | Sensors Screenshot |

Device Quantity Connection Home Assistant Notes
Nest Protect v2 Battery 6 Wi-Fi Nest Smoke Alarm and CO Alarm. I realized most of my Smoke Alarms had long suprased the 10 year mark and it was time for some replacements. I usually avoid Google owned products for various reasons, but the Nest Protect line has high praise.
Dome Motion Detector - Light Sensor 6 Vera Plus (Z-Wave) Vera Binary Sensor Motion and Light Level sensor used to automate around motion events and current room brightness.
GoControl PIR Motion Detector 1 Vera Plus (Z-Wave) Vera Binary Sensor Motion sensor used to automate around motion events.
Dome Home Automation Leak Sensor 7 Vera Plus (Z-Wave) Vera Binary Sensor Water sensors used to detect the pressence of water as a preventive measure
Aeon Labs Water Sensor 2 Vera Plus (Z-Wave) Vera Binary Sensor Water sensors used to detect the pressence of water as a preventive measure

Water sensors serve one major function, to alert me to the presence of water. Almost all of those automations can be fond via water_works.yaml

Smoke detectors, like the water sensors, have one real function to alert me of smoke or CO2. Almost all of those automations can be fond via smoke_alarm.yaml

Cameras

| Go to Menu | Cameras Screenshot |

Device Quantity Connection Home Assistant Notes
Ring Video Doorbell 1 Wi-Fi Ring / Ring Binary Sensor Automated around binary sensors via motion or doorbell button press
Ubiquiti UVC-G3 UniFi Video Camera 2 Ethernet Generic IP Camera 1080p POE Camera.
Ubiquiti UniFi Video G3 Flex 5 Ethernet Generic IP Camera 1080p POE Camera.
Ubiquiti UniFi Cloud Key Gen2 Plus 1 Ethernet Generic IP Camera Unifi Protect NVR.

Nothing is currently automated around cameras, just a UI element. The Ring doorbell is used in a number of ways to trigger an action based on motion detection or someone ringing the doorbell. Examples can be found in doorbell.yaml

I also send camera feeds as a payload on a few iOS notifications, those can mostly be found in notification_text.yaml

Garage

| Go to Menu | Auto Screenshot |

Device Quantity Connection Home Assistant Notes
Insignia - Wi-Fi Garage Door Controller 1 Wi-Fi HomeKit Controller Automated to open / close garage door on location and auto close after specific time intervals

Similar to locks, the Garage door is mostly automated to open / close based on location and after a set amount of time. Examples can be found in location.yaml and garage.yaml

Vacuum

| Go to Menu | Home Screenshot |

Device Quantity Connection Home Assistant Notes
iRobot Roomba 980 2 Wi-Fi iRobot Roomba Automated to run at specific times based on presence detection
iRobot Roomba 650 1 NA NA Currently not integrated into Home Assistant. Investigating options for future integration
iRobot Braava jet 240 1 Bluetooth NA Currently not integrated into Home Assistant. Unknown if this can ever be automated

All Roomba related automations can be found in roomba.yaml

Network

| Go to Menu | Sensors Screenshot |

Device Quantity Connection Home Assistant Notes
Ubiquiti UniFi Cloud Key Gen2 Plus 1 Ethernet Ubiquiti Unifi WAP Unifi Controller. Presence detection for non household members and devices
Ubiquiti Networks Unifi Security Gateway (USG) 1 Ethernet Ubiquiti Unifi WAP Primary Router. Presence detection for non household members and devices
Ubiquiti Networks UniFi Switch - 24 Ports (US-24-250W) 1 Ethernet Ubiquiti Unifi WAP Primary Switch. Presence detection for non household members and devices
Ubiquiti Networks 8-Port UniFi Switch (US-8-150W) 1 Ethernet Ubiquiti Unifi WAP Secondary Switch. Presence detection for non household members and devices
Ubiquiti Networks Unifi AP PRO (UAP-AC-PRO-US) 3 Ethernet Ubiquiti Unifi WAP Wireless Access Point for interior and exterior use. Presence detection for non household members and devices.
Ubiquiti Networks Unifi AP Long Range (UAP-AC-LR-US) 1 Ethernet Ubiquiti Unifi WAP Wireless Access Point for interior use. Presence detection for non household members and devices.
Ubiquiti Networks Unifi AP Lite (UAP-AC-LITE) 1 Ethernet Ubiquiti Unifi WAP Wireless Access Point for interior use. Presence detection for non household members and devices.
Ubiquiti Networks airGateway LR Wireless AP 1 Wi-Fi NA Used to connect Ubiquiti UVC-G3 UniFi Video Camera to the wireless network where running an ethernet cable wasn't feasible. Connects to POE injector

Since I don’t use the network equipment as my primary presence detection method most of the automation is around house guests via house_guest.yaml. The main function of the network equipment is to be network equipment for my fiber internet service.

Other Hardware

| Go to Menu | System Screenshot |

Device Quantity Connection Home Assistant Notes
QNAP TS-453 Pro 1 Ethernet QNAP Sensor Main storage array. Docker Containers and Plex media server run off this device. Configured with 4x WD Red Pro 4TB NAS Hard Disk Drives
APC 1500VA Back-Up UPS 1 USB / Ethernet NUT Sensor Primary Uninterruptible Power Supply (UPS). Connected via the NUT component utlizing the QNAP NAS native UPS server component

Retired

| Go to Menu |

Device Quantity Connection Home Assistant Notes
Wink Hub v1 1 Wi-Fi Wink Semi retired, using it as a z-wave repeater for Vera. Once upon a time I really loved Wink, but when you don't stock hardware for almost a year and your buisness model is selling hardware... time for that slow ride to the Cloud API in the sky. Not to mention the massive outages when staff clock out and don't fix until morning (forget to renew an expired certificate anyone). It was a fun ride Wink, hopefully your death will not be to slow and painful, but i.am+ wants to watch the world burn... probably.
Quirky + GE Aros Smart Window Air Conditioner 1 Wi-Fi Wink Climate No longer used after new HVAC system installed. Cooling effieceny had dropped and was more of an energy hog than actually making a difference in temprature comfort.
Frigidaire Cool Connect Smart Portable Air Conditioner 1 Wi-Fi Harmony Hub Remote No longer in daily use after new HVAC system installed. May be brought back into service as needed.
iHome WiFI Smart Plug 2 Wink Hub (Wi-Fi) Wink Switch Not using these anymore due to overall poor reliability
Foscam FI9800P 1 Wi-Fi Foscam IP Camera Replaced by Unifi G3 Flex
Ubiquiti UniFi Cloud Key 1 Ethernet Ubiquiti Unifi WAP Unifi Controller. Replaced by CloudKey gen2 Plus
Locative iOS App 2 NA Locative Retired in favor of native iOS app
MyQ Smart Garage Door Opener 1 Wi-Fi MyQ Cover Got fed up with the sheer disrepect this device had for reliability. Would work great for months, then decide it had enough and work when it felt like.
MyQ Home Bridge 1 Wi-Fi MyQ Cover See Above
TP-Link Smart Plug HS100 1 Wi-Fi TP-Link Switch No longer needed, might re-use at some point
Wink Relay 2 Wi-Fi Wink Wall mounted touch screen. Wink interface was rubbish and was replaced with the Home Assistant dashboard. It provides binary sensors for the two push buttons, temperature, and humidity sensors. Doesn't get used much but looks cool. Turns out it was just rubbish and decided to go into an endless reboot loop, on top of the screen already having burn in problems even when not on all the time. Retired to the trash can.

Software

| Go to Menu |

Device Quantity Connection Home Assistant Notes
iOS App 2 NA iOS Used as Home Assistant interface on mobile devices and primary method of presence detection.
Docker 1 Ethernet Installation on Docker Home Assistant install runs as a Docker Container
Pi-hole 2 Ethernet / Wi-Fi Pi-Hole Sensor Ad blocking. Primary instance runs within a Docker container and the secondary runs on a Raspberry-pi Zero W
Home Assistant Management Tool 1 Ethernet NA Custom Shell script for managing Home Assistant

The iOS app is used for some notifications in notification_text.yaml. Locative is the main method of doing any location based automations via location.yaml and many of the conditions I use are based on presence detection of household members provided by Locative.

The Home Assistant Management Tool is something I built for my personal use, but can easily be modified to suite different setups. Adjust the variables to your settings and setup shared SSH keys (if desired). Probably a million other more efficient ways to do this, but it has worked out so far for me. I had a previous version that I was using before converting to a Docker based installation. That one works with a more traditional installation. You can check out that version here

Overview:

  • Bash Shell script, should work anywhere you can use Bash
  • All HA configs are stored on my local workstation within Dropbox (doesn’t have to be but I like the versioning and access to it from any machine).
  • Edit locally with Text Editor. Currently using Atom and VIM

Options:

  1. Deploy Home Assistant Configs
    • Creates tar file of current configs
    • Backs up tar file to local workstation (I use a Dropbox Folder)
    • rsyncs config directory from local workstation (Dropbox Folder)
  2. Restart Home Assistant
    • Restarts the Home Assistant Docker container, thus restarting Home Assistant
  3. Stop Home Assistant
    • Stops the Home Assistant Docker Container
  4. Start Home Assistant
    • Starts the Home Assistant Docker Container
  5. Upgrade Home Assistant
    • Does a docker pull for the latest version of Home Assistant
    • Stops the Home Assistant Docker Container
    • Deletes the Home Assistant Docker Container
    • Creates a new Home Assistant Docker Container
  6. Check Database Size
    • Check the size of the MySQL Database
  7. Validate Home Assistant Config
    • Runs a config check using a Docker Container
  8. Backup Home Assistant
    • Creates tar file of current configs
    • Backs up tar file to local workstation (Dropbox Folder)
  9. Copy Configs to GitHub
  10. Renew SSL Certificate
    • Runs a certbot (Let's Encrypt) Docker container that generates a new SSL certificate

x) Exit – I shouldn’t need to explain that one

Variables:

hauser=“USER_ACCOUNT” <-- Home Assistant User Account

habin="/usr/local/bin/hass" <-- Home Assistant Binary

haconfigdir="/home/USER/.homeassistant" <-- Home Assistant Config Directory

hahost=“HOSTNAME/IP” <-- Home Assistant Hostname or IP address

localuser=“USER_ACCOUNT” <-- Local Computer Username, account from where this shell script will run

localhost=“HOSTNAME/IP” <-- Local Computer Hostname or IP address

localpath=“PATH_TO_LOCAL_HA_CONFIGS” <-- Where I store my local HA configs and backups

docker="/PATH/TO/DOCKER/bin " <-- Docker Binary

Within the local folder, variable localpath="PATH_TO_LOCAL_HA_CONFIGS", I have two folders:

Config: All of the .yaml files for Home Assistant

Backup: Place for backup tar file

Screenshots

| Go to Menu |

UI UI UI UI UI UI UI UI UI UI UI UI UI UI UI UI

| Go to Menu |