I'm trying to install a Pihole using Docker Compose using host networking
- Fedora Workstation 43
- GMKtek NucBox M3 (Intel 12th gen Core i5 12450H)
- Docker compose.yml:
services:
pihole:
container_name: pihole
network_mode: host
image: pihole/pihole:latest
environment:
TZ: "America/New_York"
FTLCONF_webserver_api_password: "**********"
volumes:
- './etc-pihole:/etc/pihole'
- './etc-dnsmasq.d:/etc/dnsmasq.d'
cap_add:
- NET_ADMIN
restart: unless-stopped
- Docker engine version
Client: Docker Engine - Community
Version: 28.2.2
API version: 1.48 (downgraded from 1.50)
Go version: go1.24.3
Git commit: e6534b4
Built: Fri May 30 12:09:10 2025
OS/Arch: linux/amd64
Context: desktop-linux
Server: Docker Desktop 4.40.0 (187762)
Engine:
Version: 28.0.4
API version: 1.48 (minimum version 1.24)
Go version: go1.23.7
Git commit: 6430e49
Built: Tue Mar 25 15:07:22 2025
OS/Arch: linux/amd64
Experimental: false
containerd:
Version: 1.7.26
GitCommit: 753481ec61c7c8955a23d6ff7bc8e4daed455734
runc:
Version: 1.2.5
GitCommit: v1.2.5-0-g59923ef
docker-init:
Version: 0.19.0
GitCommit: de40ad0
Actual Behaviour:
Pihole is running on my mini-pc through Docker compose. I can access the admin page through http://local-ip/admin. When I try from another PC, I am unable to access the page.
I've tried to perform an nslookup from another PC, and it fails:
nslookup cnn.com 192.168.1.76
;; communications error to 192.168.1.76#53: host unreachable