Finally got docker pi-hole to run on a Mac mini, but now it's hardly blocking any ads (< 1%). For context, I'm currently just setting my computer's (MacBook) WiFi DNS to the IP address of the machine running docker pi-hole.
I'm able to run nslookup pi.hole successfully:
But it looks like ads aren't being blocked from domains like flurry.com using the same nslookup tool:
The contents shown (e.g. "# Title: StevenBlack/hosts") matches the actual contents of the file hosted at that URL.
It would seem that while the download of that blocklist succeeded, your Pi-hole container may not receive the correct file contents when reading it.
This may suggest that file system/permission issues may be involved.
Please share your docker-compose or docker run file.
Permission issues sound likely - I get a lot of messages like this in the container's logs:
2023-09-15 09:36:09 sed: couldn't open temporary file /etc/pihole/sedBpZgVk: Permission denied
Here's my docker-compose.yml file:
version: "3"
# Example taken from the README in pi-hole's github
services:
pihole:
container_name: pihole
image: pihole/pihole:latest
ports:
- "53:53/tcp"
- "53:53/udp"
- "80:80/tcp"
environment:
TZ: 'America/Denver'
WEBPASSWORD: '***'
WEBTHEME: 'default-dark'
FTLCONF_LOCAL_IPV4: 192.168.0.19
DNSMASQ_LISTENING: all
# Volumes store your data between container upgrades
volumes:
- './etc-pihole:/etc/pihole'
restart: unless-stopped
Would you happen to know which filesystem ASUSTOR and/or Docker are applying, specifically for the volume mounts (./etc-pihole:/etc/pihole)?
Our development tells me that there may be an issue with certain filesystem types for sed, where sed may use an incorrect umask for temporary files.
Reportedly, this seems to be the case for fuse-overlayfs.
I don't know, and I'm not sure how I'd figure it out.
I fixed the problem though - the issue was that my docker-compose was lacking a top-level volumes attribute, so the volume was never fully created (i.e., docker volume ls didn't show any volumes, Docker Desktop didn't display any volumes, despite there being a local ./etc-pihole directory that docker created).
Here's my final docker-compose.yml that worked:
version: "3"
# Example taken from the README in pi-hole's github
services:
pihole:
container_name: pihole
image: pihole/pihole:latest
ports:
- "53:53/tcp"
- "53:53/udp"
- "80:80/tcp"
environment:
TZ: 'America/Denver'
WEBPASSWORD: '***'
WEBTHEME: 'default-dark'
FTLCONF_LOCAL_IPV4: 192.168.0.19
DNSMASQ_LISTENING: all
# Volumes store your data between container upgrades
volumes:
- 'etc-pihole:/etc/pihole'
restart: unless-stopped
volumes:
etc-pihole: