This Repo is designed for Smart Home inspiration. The configuration, devices and layout should help inspire you to jump head first into the IOT world. This is the live working configuration of my Smart Home. Use the menu links to jump between sections. All of the code is free to use and contribute to. This readme is based on the great documentation of CCOSTAN
This repository is a companion to my appdeamon-scripts where all my automations are.
- Docker - Docker runs on a Ubuntu Server compose file at the bottom
- Home Assistant Container - It all starts here
- DDNS via Strato
- SSL via letsencrypt - Support a more secure and privacy-respecting Web
- Indoor positioning with find3 - Machine Learning tells your phone location without any other hardware
- MQTT Broker mosquitto-docker
- Face Recognition Container - Forked from JanLoebel
- MySQL Docker
- Appdaemon - See my Appdaemon scripts here
- HAASKA Haaska-repo - Alexa Smarthome V3 API for all your HA devices
- Tasmota Tasmota-repo - Custom Firmware for ESP8266 devices offering MQTT and much more.
- Raspberry Pi running PiHole - DNS Server and AdBlocker
- hassalarm - link my android alarms to HA
Networking / Server | Alexa | Voice | Hubs | Lights | Switches | Cameras | TV Streaming | Sensors | Climate | docker-compose.yaml | Screenshots
Using a Fritzbox as this is one of the official supported modems for Telekom. The rest is running on Ubiquiti. Rock solid and fun to use. As a server running Homeassistant and everything else I use a HP Microserver Gen 10. Click on the sections to expand them Notify if an unkown device is found on the networkAllow a device internet access via Telegram Bot (Fritzbox only) | |||
The Alexa devices in my house are for automation overrides. They are primarily an input device into Home Assistant. Using haaska, I am able to turn on /off most HA devices even if they don't have native Alexa support. I use them for Multiroom Audio and some custom skills. Click on the sections to expand them Alexa tell Homeassistant to turn off Ventilator in 10 MinutesAlexa ask Home Assistant whether all windows are closedAlexa ask Home Assistant when the next bus departsTurn on Receiver Bluetooth when Alexa is playing something so it plays on the big speakers. | |||
Voice Notifications - Appdaemon App - Notifier | |||
I am using the great Alexa TTS Component by keatontaylor to let Alexa notify me of everything when I am home. Click on the sections to expand them Voice announcements whenever someone comes home.Notify if a user is leaving a zone after being there for a certain amount of time.Once you can teach your house to talk, you just keep expanding on it's vocabulary. It's addicting. :) | |||
The Hubs help the home communicate across all the various protocols running in the house. Most of my sensors are Xiaomi Sensors running over 1 gateway. I use the RM hubs to control non smart TVs and Receivers as well as my canopy via 433MHZ. | |||
Almost all of my lights are Xiaomi Yeelight Color bulbs. Before I started using them I used SonOffs with Tasmota and I stil do. You will find them in the switches section. I have one lightstrip under my bar table controlled by a MagicHome LED Controller also running Tasmota. Click on the sections to expand them Turn Bar Red when Homeassistant goes offline
As I sometimes restart HA when working on it from remote I turn the Bar lights to red with [this script](https://github.com/eifinger/homeassistant-config/blob/master/updateHomeassistant.sh). This way everyone can see HA is currently unavailable. If it comes back up again this | |||
Before I used smart bulbs I bought SonOff switches because they are much cheaper than a $20 bulb and put them in front of "normal" bulbs. I use 2 S20 to control lightstrips. Click on the sections to expand them Notify me when the dishwasher starts/stops | |||
I currently only use old Anroid Smartphones as IP Cameras. Click on the sections to expand them Selflearning Facerecognition for the Frontdoor | |||
Just the usual things for Netflix | |||
All of my windows have Xiaomi Contact Sensors and my Terrace Doors have two so I can distinguish between open and tilted. I have several Motion Sensors which I use for presence detection and light control. To get a good overview of the temperature distribution I use Xiaomi temperature sensors where I don't already have Sonoff TH16s. Click on the sections to expand them Turn on light when sun is down and motion detected
AppDaemon App - motionTrigger Alexa ask Home Assistant whether all windows are closedKnow the exact moment when someone leaves or comes home | |||
I am using a custom_component for Broadlink Thermostats which works perfectly. Click on the sections to expand them Turn on floor heating for 1 hour before wake up | |||
# Version > 3 does not work as it doesn't support 'depends_on'
version: '2.1'
services:
homeassistant:
container_name: homeassistant
image: homeassistant/home-assistant:2021.4.5
volumes:
- /home/admin/homeassistant:/config
- /etc/localtime:/etc/localtime:ro
restart: always
network_mode: host
depends_on:
influxdb:
condition: service_healthy
mysql-homeassistant:
condition: service_healthy
mosquitto:
condition: service_started
appdaemon:
container_name: appdaemon
restart: unless-stopped
image: acockburn/appdaemon:3.0.5
volumes:
- /etc/localtime:/etc/localtime:ro
- /home/admin/appdaemon:/conf
- /home/admin/homeassistant/www:/config/www
environment:
- HA_URL="https://hidden.de"
- TOKEN="secure"
- DASH_URL="http://hidden:5050"
ports:
- "5050:5050"
- "8124:8124"
links:
- facerec_service
depends_on:
- splunk
facerec_service:
container_name: facerec_service
restart: unless-stopped
image: eifinger/face_recognition:latest
volumes:
- /home/admin/facerec_service:/root/faces
ports:
- "9922:8080"
influxdb:
container_name: influxdb
restart: unless-stopped
image: influxdb:latest
healthcheck:
test: ["CMD", "curl", "-sI", "http://127.0.0.1:8086/ping"]
interval: 30s
timeout: 1s
retries: 24
volumes:
- /etc/localtime:/etc/localtime:ro
- /home/admin/influxdb:/var/lib/influxdb
ports:
- "8083:8083"
- "8086:8086"
- "8090:8090"
grafana:
container_name: grafana
restart: unless-stopped
image: grafana/grafana:7.0.3
volumes:
- grafana-storage:/var/lib/grafana
environment:
- GF_SECURITY_ADMIN_PASSWORD="admin"
- GF_ANALYTICS_REPORTING_ENABLED=false
- GF_USERS_ALLOW_SIGN_UP=false
- GF_AUTH_ANONYMOUS_ENABLED=false
- GF_RENDERING_SERVER_URL=http://grafana-renderer:8081/render
- GF_RENDERING_CALLBACK_URL=http://grafana:3000
ports:
- "3000:3000"
depends_on:
- influxdb
grafana-renderer:
image: grafana/grafana-image-renderer:latest
container_name: grafana-renderer
ports:
- "8081:8081"
mysql-homeassistant:
container_name: mysql-homeassistant
restart: unless-stopped
image: mysql:latest
healthcheck:
test: "/usr/bin/mysql --user=root --password=secure --execute \"SHOW DATABASES;\""
interval: 2s
timeout: 20s
retries: 10
environment:
- MYSQL_ROOT_PASSWORD=secure
- MYSQL_DATABASE=hass_db
- MYSQL_USER=hassuser
- MYSQL_PASSWORD=secure
volumes:
- /home/admin/mysql-homeassistant/mysql:/var/lib/mysql
ports:
- "3307:3306"
mosquitto:
container_name: mosquitto
restart: unless-stopped
image: eclipse-mosquitto
volumes:
- /home/admin/mosquitto/data:/mosquitto/data
- /home/admin/mosquitto/log:/mosquitto/log
- /home/admin/mosquitto/config:/mosquitto/config
ports:
- "1883:1883"
- "9001:9001"
- "8883:8883"
hass-data-detective:
container_name: hass-data-detective
hostname: hass-data-detective
restart: unless-stopped
image: kylerw/hass-data-detective:latest
network_mode: host
volumes:
- /home/admin/homeassistant:/hass-config:ro
- /etc/localtime:/etc/localtime:ro
- /home/admin/hass-data-detective/:/home/jovyan
environment:
- JUPYTER_ENABLE_LAB="yes"
depends_on:
- homeassistant
glances:
container_name: glances
image: eifinger/glances-docker:3.1.4
restart: unless-stopped
pid: "host"
volumes:
- /var/run/docker.sock:/var/run/docker.sock:ro
- /home/admin/glances/conf/glances.pwd:/root/.config/glances/glances.pwd
- /media:/media:ro
environment:
- "GLANCES_OPT=-w --password"
ports:
- "61208:61208"
- "61209:61209"
esphome:
container_name: esphome
image: esphome/esphome:1.14.3
volumes:
- /home/admin/esphome:/config
- /etc/localtime:/etc/localtime:ro
restart: always
network_mode: host
seq:
container_name: seq
image: datalust/seq:2020.1.4212
volumes:
- /home/damin/seq/data:/data
ports:
- "5342:80"
- "5341:5341"
environment:
- "ACCEPT_EULA=Y"
volumes:
grafana-storage: | |||
All files are now being edited with VSCode.
All of my configuration files are tested against the most stable version of home-assistant using Github Actions.
Still have questions on my Config? Message me on twitter : @eifinger