From 71b8803f6b5ffc82eb2a55ef852f0ce3709dc893 Mon Sep 17 00:00:00 2001 From: Paul Date: Sat, 15 Aug 2020 01:15:51 +0200 Subject: [PATCH] Initial commit --- Dockerfile | 17 +++++++++++++++++ README.md | 34 ++++++++++++++++++++++++++++++++++ docker-compose.yml | 13 +++++++++++++ 3 files changed, 64 insertions(+) create mode 100644 Dockerfile create mode 100644 README.md create mode 100644 docker-compose.yml diff --git a/Dockerfile b/Dockerfile new file mode 100644 index 0000000..59ed4e5 --- /dev/null +++ b/Dockerfile @@ -0,0 +1,17 @@ +FROM debian:buster +MAINTAINER Chris +EXPOSE 53 53/udp + +WORKDIR /root + +# Install dependencies and sources +RUN \ + apt-get update \ + && apt-get install --yes dnsutils bind9 \ + # Trim down the image + && apt-get clean \ + && rm -rf /var/lib/apt/lists/* /tmp/* /var/tmp/* + +VOLUME /etc/bind/ +ENTRYPOINT ["/usr/sbin/named"] +CMD ["-f"] diff --git a/README.md b/README.md new file mode 100644 index 0000000..9c202e3 --- /dev/null +++ b/README.md @@ -0,0 +1,34 @@ +## BIND DNS +bind is a dns server. + +### Building bind + +``` +docker build -t zombi/bind . +``` + +### Running bind + +``` + docker run -d \ + -p 53:53 \ + -p 53:53/udp \ + --name dns \ + -v /data/bind/:/etc/bind/ \ + zombi/bind +``` + + +### Debugging + +If the DNS server does not start up the reason is probably a syntax error in the configuration files. +Unfortunately these errors aren't logged on startup. + +run `named-checkconf` for debugging which should tell you where the error is + +``` + docker run -it --rm \ + --entrypoint /usr/sbin/named-checkconf \ + -v /data/bind/:/etc/bind/ \ + zombi/bind +``` diff --git a/docker-compose.yml b/docker-compose.yml new file mode 100644 index 0000000..eda4ec6 --- /dev/null +++ b/docker-compose.yml @@ -0,0 +1,13 @@ +version: '2' + +services: + bind: + build: . + ports: + - "53:53" + - "53:53/udp" + volumes: + - /data/bind/:/etc/bind/ + + webhook: + image: adnanh/webhook