pi-hole

Discussion on apps, protocols, APIs, specifications, and more. You are welcome to join us as a TOS app developer!
Post Reply
User avatar
Meeni
Posts: 6
Joined: 11 Mar 2021, 05:00

pi-hole

Post by Meeni »

Pi-Hole is a DNS for ad-blocking/privacy protection

https://pi-hole.net
User avatar
iggyboo
Posts: 4
Joined: 18 Mar 2021, 04:11

Re: pi-hole

Post by iggyboo »

couln't you do this using the Docker features?
User avatar
matt_30
Posts: 67
Joined: 02 Jan 2021, 23:22

Re: pi-hole

Post by matt_30 »

I think I have got this working using docker compose.

You will need to:
  • Create 2 folders. One for /etc/pihole, and one for /etc/dnsmasz.d.
  • Pick 2 ports not in user to redirect port 80 and port 443 traffic (For this example I used 8085 and 503 to replace port 80 and 443).
  • Determine your IP
Docker Compose Script:

Code: Select all

version: "3"
services:
  pihole:
    container_name: pihole
    image: pihole/pihole:latest
    ports:
      - "53:53/tcp"
      - "53:53/udp"
      - "67:67/udp"
      - "8085:80/tcp"
      - "503:443/tcp"
    environment:
      TZ: 'Europe/London'
      ServerIP: <IP_OF_DEVICE>
    volumes:
      - '<PATH_TO_FOLDER>:/etc/pihole/'
      - '<PATH_TO_FOLDER>:/etc/dnsmasq.d/'
    restart: unless-stopped
Handy URL''s When I tried to connect on port 503(443) I could not connect however, when I connected on 8085 (80) I was greeted with the Pi Hole GUI :).
Image


I currently have this running on a Raspberry PI, I hope to be able to move this onto my TNAS.

Please feel free to post any questions or contact me regrading this.

Updates to follow.
Attachments
2021-03-19 15_34_08-Pi-hole - 534a05c8ac87.png
User avatar
justsimon
Posts: 69
Joined: 22 Sep 2020, 15:18

Re: pi-hole

Post by justsimon »

It may be best to run pi-hole with its own IP address in the same subnet as your main LAN.
This will avoid any port mapping issues, as all ports will be available.

You can follow this guide to create a network in docker that uses the same IP range as your LAN.
Just make sure any IP addresses you give to docker containers, are also listed as static/assigned IPs in your router, this will remove them from the DHCP pool, and your router won't try assigning the same IP address to another device.

The network created won't be available via the TOS Docker app, but will be available via Portainer.
Portainer, by the way, is far superior to the TOS Docker app for deploying containers.

When deploying via Portainer, you get a drop-down list to select the network, and can type in an IPv4 address of your liking.
User avatar
snapperheadjoeTM
Posts: 18
Joined: 03 Mar 2021, 23:50

Re: pi-hole

Post by snapperheadjoeTM »

I was able to follow this video and successfully setup my "Pi-Hole" Docker instance on my TNAS F4-210. https://www.youtube.com/watch?v=XziNCmcxB_c

The walk through is straight forward and works perfectly. I run Unifi for my network infrastructure, so I point DNS on my USG to the IP of the Pi-Hold Docker instance and now all devices on my whole network are enjoying Pi-Hole Goodness! I have 90+ wired/wireless clients on my network including security devices, smart devices, TVs etc. and none are experiencing any issues.

I've had no issues with black or whitelisting so far. I work from home and VPN to my company and have not seen any issues.
Post Reply