No description
- Shell 89.1%
- Dockerfile 10.9%
| sources | ||
| static | ||
| tests | ||
| .gitignore | ||
| Dockerfile | ||
| entrypoint.sh | ||
| healthcheck.sh | ||
| README.md | ||

PowerDNS Authoritative Server - Docker Image
Image Docker personnalisée pour PowerDNS Authoritative Server avec support complet de SQLite3, MySQL/MariaDB et PostgreSQL.
Quick Start
SQLite3
docker run -d \
--name powerdns \
-p 53:53/udp \
-p 53:53/tcp \
-p 8081:8081/tcp \
-e PDNS_LAUNCH=gsqlite3 \
-e PDNS_API=yes \
-e PDNS_API_KEY=your-secret-key \
-e PDNS_WEBSERVER=yes \
-e PDNS_WEBSERVER_ADDRESS=0.0.0.0 \
-e PDNS_WEBSERVER_ALLOW_FROM=0.0.0.0/0 \
-v ./data:/data \
forge.hutit.fr/docker/pdns:latest
MySQL/MariaDB
docker run -d \
--name powerdns \
-p 53:53/udp \
-p 53:53/tcp \
-p 8081:8081/tcp \
-e PDNS_LAUNCH=gmysql \
-e PDNS_GMYSQL_HOST=your-mysql-host \
-e PDNS_GMYSQL_USER=powerdns \
-e PDNS_GMYSQL_PASSWORD=your-password \
-e PDNS_GMYSQL_DBNAME=powerdns \
-e PDNS_GMYSQL_INIT_SCHEMA=true \
-e PDNS_API=yes \
-e PDNS_API_KEY=your-secret-key \
-e PDNS_WEBSERVER=yes \
-e PDNS_WEBSERVER_ADDRESS=0.0.0.0 \
-e PDNS_WEBSERVER_ALLOW_FROM=0.0.0.0/0 \
forge.hutit.fr/docker/pdns:latest
PostgreSQL
docker run -d \
--name powerdns \
-p 53:53/udp \
-p 53:53/tcp \
-p 8081:8081/tcp \
-e PDNS_LAUNCH=gpgsql \
-e PDNS_GPGSQL_HOST=your-postgres-host \
-e PDNS_GPGSQL_USER=powerdns \
-e PDNS_GPGSQL_PASSWORD=your-password \
-e PDNS_GPGSQL_DBNAME=powerdns \
-e PDNS_GPGSQL_INIT_SCHEMA=true \
-e PDNS_API=yes \
-e PDNS_API_KEY=your-secret-key \
-e PDNS_WEBSERVER=yes \
-e PDNS_WEBSERVER_ADDRESS=0.0.0.0 \
-e PDNS_WEBSERVER_ALLOW_FROM=0.0.0.0/0 \
forge.hutit.fr/docker/pdns:latest
Configuration
Principe
Toutes les options PowerDNS sont supportées via des variables d'environnement préfixé par PDNS_.
Conversion automatique :
PDNS_API_KEY→--api-key=valuePDNS_WEBSERVER_ADDRESS→--webserver-address=valuePDNS_LOCAL_PORT→--local-port=value
Les underscores (_) sont convertis en tirets (-) et tout est mis en minuscules.
Documentation complète : PowerDNS Settings
Initialisation des backends
Chaque backend possède une variable permettant l'initialisation de ce dernier.
PDNS_GSQLITE3_INIT_SCHEMA=trueinitialise automatiquement le schéma SQLite3PDNS_GMYSQL_INIT_SCHEMA=true: initialise automatiquement le schéma MySQLPDNS_GPGSQL_INIT_SCHEMA=true: initialise automatiquement le schéma PostgreSQL
Build
git clone https://forge.hutit.fr/docker/pdns.git
cd pdns
docker build -t powerdns-auth:latest .
Tests
cd tests
# SQLite3
docker compose -f docker-compose.sqlite3.yml up
# MariaDB
docker compose -f docker-compose.mariadb.yml up
# PostgreSQL
docker compose -f docker-compose.pgsql.yml up
Logs
docker logs powerdns
docker logs -f powerdns # Suivre en temps réel
Support
- Issues : https://forge.hutit.fr/docker/pdns/issues
- Documentation PowerDNS : https://doc.powerdns.com/authoritative/
Licence
Cette image est sous licence GPLv3-or-later.
PowerDNS est sous licence GPLv2 : https://www.powerdns.com/