Skip to content
Snippets Groups Projects
Commit abb0608e authored by nimrod's avatar nimrod
Browse files

Move from the knot image to Alpine.

The builds have been broken for a while. Because the knot image is based
on Debian. Use Alpine instead (not because I'm sure the image will be
smaller or better, but it's less work to keep the existing Alpine
stuff).
Also, run as a limited user.
parent 3a2cedf7
Branches
No related tags found
No related merge requests found
FROM cznic/knot-resolver FROM alpine:latest
RUN echo '@testing http://dl-cdn.alpinelinux.org/alpine/edge/testing' >> /etc/apk/repositories && \ RUN echo '@testing http://dl-cdn.alpinelinux.org/alpine/edge/testing' >> /etc/apk/repositories && \
echo '@community http://dl-cdn.alpinelinux.org/alpine/edge/community' >> /etc/apk/repositories && \
apk add --update --no-cache \ apk add --update --no-cache \
bash \
dma@testing \ dma@testing \
gosu@testing \
iproute2 \ iproute2 \
knot-resolver@community \
knot-utils \ knot-utils \
mailx \ mailx \
mtr mtr \
COPY entrypoint /entrypoint && \
ln -s /usr/bin/kdig /usr/local/bin/dig && \
ln -s /usr/bin/khost /usr/local/bin/host
COPY entrypoint /usr/local/sbin/entrypoint
WORKDIR / WORKDIR /
ENTRYPOINT [ "/entrypoint" ] ENTRYPOINT [ "entrypoint" ]
CMD [ "bash", "--login" ] CMD [ "bash", "--login" ]
#!/bin/sh #!/bin/sh
set -eu set -eux
echo "net = { '127.0.0.1', '::1'}" | nohup kresd -f1 & kresd --addr '127.0.0.1' --noninteractive &
echo 'nameserver 127.0.0.1' > /etc/resolv.conf echo 'nameserver 127.0.0.1' > /etc/resolv.conf
eval "exec $@" eval "exec gosu nobody:nobody $@"
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment