diff --git a/Dockerfile b/Dockerfile index ff19a12..2a0a9dd 100644 --- a/Dockerfile +++ b/Dockerfile @@ -2,7 +2,7 @@ FROM alpine:latest MAINTAINER Jochen Welzel -RUN apk update && apk upgrade && apk add bash && apk add nsd +RUN apk update && apk upgrade && apk add bash && apk add openssl && apk add nsd RUN mkdir -p /var/db/nsd/zones/master && mkdir /var/db/nsd/zones/slave && mkdir /var/run/nsd COPY nsd.conf.example /tmp COPY entrypoint.sh / diff --git a/entrypoint.sh b/entrypoint.sh index 3f7da15..24e8347 100644 --- a/entrypoint.sh +++ b/entrypoint.sh @@ -4,6 +4,9 @@ set -e if [ ! -f "/etc/nsd/nsd.conf" ]; then cp /tmp/nsd.conf.example /etc/nsd/nsd.conf fi +if [ ! -f "/etc/nsd/nsd_control.pem" ]; then + nsd-control-setup +fi exec nsd -d