Last active
April 20, 2024 01:43
-
-
Save stjohnjohnson/d441e26e4d77a975fd3ebb4e6f19e3d6 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
version: '3' | |
services: | |
pihole: | |
image: pihole/pihole | |
hostname: pihole | |
restart: unless-stopped | |
ports: | |
- 53:53/tcp | |
- 53:53/udp | |
- 80:80/tcp | |
dns: | |
- 127.0.0.1 | |
- 1.1.1.1 | |
volumes: | |
- ./internal.conf:/etc/dnsmasq.d/02-internal.conf | |
- ./internal.list:/etc/pihole/internal.list | |
environment: | |
ServerIP: "10.0.0.205" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
addn-hosts=/etc/pihole/internal.list |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# This is a single domain to a server | |
10.0.0.210 plex.example.com | |
# Multiple domains can point to the same server | |
# (routed via different ports or a proxy like nginx) | |
10.0.0.205 haas.example.com | |
10.0.0.205 pihole.example.com | |
# Here is an example of short name | |
# (useful for things like short-url services) | |
10.0.0.215 go | |
# IPs do not need to be in your network | |
192.168.100.1 modem |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
all: build test clean | |
test: | |
@echo "========== Internal Domains ==========" | |
dig @127.0.0.1 haas.example.com +short | |
dig @127.0.0.1 pihole.example.com +short | |
dig @127.0.0.1 plex.example.com +short | |
dig @127.0.0.1 go +short | |
dig @127.0.0.1 modem +short | |
@echo "========== External Domains ==========" | |
dig @127.0.0.1 google.com +short | |
dig @127.0.0.1 github.com +short | |
build: | |
docker-compose up -d | |
until curl -f -I http://127.0.0.1; do sleep 1; done | |
clean: | |
docker-compose down -v |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment