Created
March 4, 2015 22:21
-
-
Save nemosupremo/261205f2d4418ea93cdb to your computer and use it in GitHub Desktop.
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
FROM golang:1.4.1-wheezy | |
MAINTAINER ChannelMeter <product@channelmeter.com> | |
RUN go get github.com/miekg/dns | |
RUN go get github.com/mesosphere/mesos-dns | |
RUN cd $GOPATH/src/github.com/mesosphere/mesos-dns && go build -o /opt/mesos-dns | |
ENV MESOS_MASTERS mesos1:5050,mesos2:5050,mesos3:5050 | |
ENV DNS_REFRESH_SECONDS 50 | |
ENV DNS_TTL 60 | |
ENV DNS_DOMAIN mesos | |
ENV DNS_RESOLVERS 8.8.8.8 | |
ENV DNS_TIMEOUT 10 | |
ENV DNS_LISTENER 0.0.0.0 | |
ENV DNS_EMAIL root.mesos-dns.mesos | |
EXPOSE 53 | |
EXPOSE 53/udp | |
CMD ["/bin/bash", "-c", "echo { \\\"masters\\\": [\\\"`echo ${MESOS_MASTERS} | sed -e s/,/\\\",\\\"/g`\\\"], \\\"refreshSeconds\\\": ${DNS_REFRESH_SECONDS}, \\\"ttl\\\": ${DNS_TTL}, \\\"domain\\\": \\\"${DNS_DOMAIN}\\\", \\\"port\\\": 53, \\\"resolvers\\\": [\\\"`echo ${DNS_RESOLVERS} | sed -e s/,/\\\",\\\"/g`\\\"], \\\"timeout\\\": ${DNS_TIMEOUT}, \\\"listener\\\": \\\"${DNS_LISTENER}\\\", \\\"email\\\": \\\"${DNS_EMAIL}\\\"} > /opt/config.json && /opt/mesos-dns -config=/opt/config.json"] |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment