Files
nip/k8s/Dockerfile-pdns
Brian Cunnie 4164af4e9c k8s: introduce nginx Dockerfile
We now introduce a second Dockerfile, `Dockerfile-nginx`, to be used for
the web assets for sslip.io.

It does not run TLS; we assume that the load balancer will take care of
that.

We also gussied-up the PowerDNS Dockerfile with minor changes.
2020-07-05 15:49:42 -07:00

45 lines
1.3 KiB
Plaintext

# sslip.io PowerDNS Dockerfile
#
# Dockerfile of a DNS server that responds to DNS
# queries of hostnames with embedded IP addresses
# (e.g. "169.254.169.254.example.com") with the IP
# address ("169.254.169.254). See https://sslip.io
# for more information
#
# Typical start command:
#
# docker run --rm -p 53:53 -p 53:53/udp cunnie/sslip.io-pdns
#
# To test from host:
#
# dig +short 127.0.0.1.example.com @localhost
# 127.0.0.1
#
FROM fedora AS sslip.io-pdns
LABEL maintainer="brian.cunnie@gmail.com"
RUN dnf install -y iproute bind-utils neovim
RUN dnf install -y procps-ng nmap-ncat net-tools lsof
RUN dnf install -y pdns pdns-backend-pipe
RUN curl -o /usr/local/sbin/pdns_pipe.sh -L https://raw.githubusercontent.com/cunnie/bin/master/pdns_pipe.sh
RUN chmod 755 /usr/local/sbin/pdns_pipe.sh
COPY pdns.conf /etc/pdns/pdns.conf
COPY named.conf /etc/pdns/named.conf
ENTRYPOINT ["/usr/sbin/pdns_server", "--guardian=no", "--daemon=no", "--disable-syslog", "--log-timestamp=no", "--write-pid=no"]
# for testing:
# ENTRYPOINT /usr/sbin/pdns_server --guardian=no --daemon=no --disable-syslog --log-timestamp=no --write-pid=no
# DNS listens on port 53 UDP, but sometimes connects via TCP (AXFR).
# The `EXPOSE` directive doesn't do much in our case. We use it for documentation.
EXPOSE 53/udp
EXPOSE 53/tcp