How to fix your Pi-Hole integration with Home Assistant
My Pi Hole has been broken for a while now. Not the actual Pi Hole service but the integration with Home Assistant. For a few months now, people have been letting me know that my house bot (@BearStoneHA) has been tweeting out broken stats on the ad blocking on our network.
If you are not familiar with Pi Hole, it is open source ad blocking software that you can run on almost any device (famously, a raspberry pi) and use it to block malware, advertisements, tracking cookies and other internet annoyances. In my Smart Home, we run it on a Raspberry Pi Zero that my friend Jacques Bensimon purchased for a buck at MicroCenter. We use it for DHCP and DNS services in addition to the blacklisting service. It’s rock solid on the Zero and the Home Assistant integration worked all the way up to version 0.99 of Home Assistant. That’s when a breaking change was introduced.
The fix is relatively easy and it actually simplifies the configuration in your yaml by removing a lot of the superfluous entries. PiHole is no longer a sensor but instead a platform with a suite of sensors. 🙂
You can watch the video above to see how I implemented this easy fix.
Enjoy the Video
–Carlo