Home Assistant Community Add-on: Pi-hole

No idea what problem I´m facing? Opening the UI from supervisor does not require a login. When using http://homeassistant:80 I can login with my user credentials but behavior is same.
See my last post here:
Home Assistant Community Add-on: Pi-hole

I’ve been using pihole regularly without Hassio, but no matter what settings I use I can’t make it work with hassio.

I have an ASUS router, if I add the local hassio ip there it doesn’t work.

I would appreciate any help to set it up, or an example please.

pihole is really a crazy thing.
Tried to use that service call and pihole is not starting, while other addons do…and i don’t have any error in log.

'1584345413987':
  alias: Reboot_Addons
  sequence:
  - data:
      addon: a0d7b954_nodered
    service: hassio.addon_restart
  - data:
      addon: core_configurator
    service: hassio.addon_restart
  - data:
      addon: a0d7b954_pi_hole
    service: hassio.addon_restart

no error, but only pihole is not restarting.
i’m starting to really hate pihole :triumph:

EDIT: seems not working via script or automation, but works with nodered.
Just make an http request node to fire when any pihole sensor became “unavailable” ( events state node ).
The http node needs to send a POST to:

http://IP:8123/api/hassio/addons/a0d7b954_pi-hole/restart

Authtentication Type bearer and insert a long live token ( generate one from HA ).
As soon as nodered read the unavailable state for the sensor, pihole is restarted.
A bit tricky but this one works.

Confirmed that this change worked for me. Many thanks.

1 Like

Ok, i found something strange: if i start hassio.addon_restart with a0d7b954_pi-hole i have this error messagge:

If i launch the script with a0d7b954_pi_hole it starts but it does nothing.
Maybe the problem is that _ instead of - ?
:thinking:

Really not sure why but I cannot get my Pi Hole stats to display in my Lovelace cards - it just says everything is unavailable. It used to work but stopped last year and now I cannot work out why. Pi Hole itself works fine.

I’ve Googled it and tried every suggestion I could see - every host variation with / without port, putting verify_ssl = true, etc. Does anyone have anything else I could try?

pi_hole:
  host: 'localhost:4865'
  ssl: true
  verify_ssl: false
  api_key: ""
update_lists_on_start: false
ssl: true
certfile: fullchain.pem
keyfile: privkey.pem
interface: ''
ipv6: true
ipv4_address: ''
ipv6_address: ''
hosts: []
virtual_host: <my DuckDNS address>

In the log I just get this:

2020-03-23 20:05:56 ERROR (MainThread) [homeassistant.components.pi_hole] Unable to fetch data from Pi-hole
2020-03-23 20:11:06 ERROR (MainThread) [hole] Can not load data from *hole: localhost:4865
1 Like

i have this entry in configuration.yaml

pi_hole:
  host: 'localhost:4865'
  ssl: false
  verify_ssl: false

on both my nuc and raspPI and i can see all pihole entities.

1 Like

Yeesh… I’m baffled. I changed my SSL value to false and … it started working after a few minutes (after restart).

I can’t explain why… I do use SSL…

Well, either way, thank you very much for your help.

Happy you fixed the issue :slightly_smiling_face:

:tada: Release v4.1.2

Full Changelog

:warning: This add-on is now deprecated and will not receive any maintenance beyond this point.

Please consider moving to the AdGuard Home add-on.

:hammer: Changes

  • :arrow_up: Upgrades add-on base image to v7.0.5
  • :arrow_up: Upgrades gcc to 9.2.0-r4
  • :arrow_up: Upgrades musl-dev to 1.1.24-r2
  • :arrow_up: Upgrades php7 to 7.3.16-r0
  • :arrow_up: Upgrades Pi-hole AdminLTE to v4.3.3
  • :warning: Adds deprecation notices

Questions? Join our Discord server! https://discord.me/hassioaddons

1 Like

Since this add-on is now deprecated, I’ll go ahead and close this topic.