-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathDockerfile
31 lines (22 loc) · 841 Bytes
/
Dockerfile
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
# FROM golang as build
# ARG COREDNS_VERSION=1.6.4
# WORKDIR /tmp
# COPY plugin.cfg /tmp/plugin.cfg
# RUN set -x \
# && apt update && apt install curl unzip make -y \
# && curl -Lo coredns.zip https://github.com/coredns/coredns/archive/v$COREDNS_VERSION.zip \
# && unzip coredns.zip \
# && cd coredns-$COREDNS_VERSION \
# && cp /tmp/plugin.cfg . \
# && make \
# && ./coredns -plugins \
# && mv coredns /tmp
FROM busybox
# get the config file from the local folder
COPY Corefile /etc/coredns/Corefile
# get thecoredns binary from internal coredn with plugins existing image
# COPY coredns /opt/coredns
COPY --from=registry:5000/infra/corednswithplugins:1.6.4-drop /tmp/coredns /opt/coredns
# COPY --from=build /tmp/coredns /opt/coredns
EXPOSE 53/udp 15353 19253
CMD ["/opt/coredns", "-conf", "/etc/coredns/Corefile"]