-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
2 changed files
with
16 additions
and
6 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,8 +1,8 @@ | ||
FROM internetsystemsconsortium/bind9:9.16 | ||
LABEL org.opencontainers.image.source="https://github.com/matjazp/ubuntu-bind" | ||
RUN apt-get -qqqy update && apt-get -qqqy install nano dnsutils iputils-ping ifupdown | ||
#RUN echo include "/etc/bind/named.conf.log"; >> /etc/bind/named.conf | ||
#RUN mkdir -p /var/log/bind | ||
#RUN chown bind:bind /var/log/bind | ||
#COPY --chown=root:bind named.conf.log /etc/bind/named.conf.log | ||
CMD [ "bash" ] | ||
RUN apt-get -qqy update && apt-get -qqy install dnsutils iputils-ping ifupdown less nano | ||
COPY startup.sh /startup.sh | ||
RUN chmod +x /startup.sh | ||
COPY --chown=root:bind named.conf.log /etc/named.conf.log | ||
ENTRYPOINT [ "./startup.sh"] | ||
CMD [ "/usr/bin/bash" ] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
#! /usr/bin/bash | ||
# make sure log file is included only once | ||
grep -Fxq 'include "/etc/named.conf.log";' /etc/bind/named.conf || echo 'include "/etc/named.conf.log";' >> /etc/bind/named.conf | ||
# echo 'include "/etc/named.conf.log";' >> /etc/bind/named.conf | ||
if [ ! -d "/var/log/bind" ]; then | ||
mkdir -p /var/log/bind | ||
chown bind:bind /var/log/bind | ||
fi | ||
|
||
exec "$@" |