- work in progress - not ready !
This code repository wants to provide a libredns (kind of) quick solution for self-hosted environments.
This specific repo, uses OpenNic and StevenBlack default blacklisting.
Two step process:
- Get All files
- Run PowerDNS Recursor
---
services:
bash:
image: bashenv_file:
- path: ./default.envrequired: truecommand: > bash -c "mkdir -p recursor.d && cd recursor.d && apk add -q curl bind-tools && curl -sO https://raw.githubusercontent.com/ebal/libredns-docker/refs/heads/main/get_files.sh && bash get_files.sh"working_dir: /tmpvolumes:
- ./:/tmphealthcheck:
test: ["CMD", "test", "-f", "/tmp/OpenNIC"]interval: 10stimeout: 5sretries: 5start_period: 5spdns-rec:
image: powerdns/pdns-recursor-52hostname: pdns-reccontainer_name: pdns-recdepends_on:
bash:
condition: service_completed_successfullyenv_file:
- path: ./default.envrequired: trueports:
- "1053:53/udp"volumes:
- ./recursor.d:/etc/powerdns/recursor.d:roWith docker compose up and down, you can also make the update on blacklist files.
docker compose up -dtakes a little time to start ... black host file is huge !
with
dig @127.0.0.1 -p 1053 analytics.google.comoutput should be something like:
analytics.google.com. 86400 IN A 0.0.0.0
