diff --git a/.gitignore b/.gitignore index 50a2891..f5453ac 100644 --- a/.gitignore +++ b/.gitignore @@ -1,4 +1,3 @@ -dnsmasq.hosts watchmen/watchmen-config/hosts.js saltfiles *.container.id diff --git a/dnsmasq/Dockerfile b/dnsmasq/Dockerfile index a241184..5afb2cb 100644 --- a/dnsmasq/Dockerfile +++ b/dnsmasq/Dockerfile @@ -1,12 +1,15 @@ -FROM ubuntu +FROM sroegner/centos-base-ssh:6 +MAINTAINER Steffen Roegner 'steffen.roegner@gmail.com' -VOLUME [ "/dnsmasq.hosts" ] -RUN DEBIAN_FRONTEND=noninteractive apt-get install -y --force-yes dnsmasq-base dnsutils -ADD dnsmasq.conf /etc/dnsmasq.conf -ADD resolv.dnsmasq.conf /etc/resolv.dnsmasq.conf +RUN yum -y install dnsmasq -EXPOSE 5353/udp +COPY dnsmasq.conf /etc/ +COPY resolv.dnsmasq.conf /etc/ + +VOLUME /dnsmasq.hosts + +EXPOSE 5353 + +ENTRYPOINT ["/usr/sbin/dnsmasq", "-d"] -CMD ["/usr/sbin/dnsmasq", "-d"] -#ENTRYPOINT ["/usr/sbin/dnsmasq"] diff --git a/dnsmasq/Makefile b/dnsmasq/Makefile index b4a8618..0259c2e 100644 --- a/dnsmasq/Makefile +++ b/dnsmasq/Makefile @@ -1,17 +1,8 @@ -all: - echo "Can do 'clean', 'image' or 'container'" -clean: - sudo docker stop dnsmasq - sudo docker rm dnsmasq - -image: - sudo docker build -rm -t='sroegner/dnsmasq' . +hostname := dnsmasq +thirdoctet := 24 +include ../shared/Makefile.vars +include ../shared/Makefile container: - sudo docker run \ - -v="$$(pwd)/dnsmasq.hosts:/dnsmasq.hosts" \ - -name=dnsmasq \ - -p='127.0.0.10:53:5353/udp' \ - -d sroegner/dnsmasq - sudo docker ps - sudo docker logs $$(sudo docker ps -l -q) + $(DOCKER_CMD) run -d -v=$(CURDIR)/dnsmasq.hosts:/dnsmasq.hosts --name=$(container_name) --publish=$(IP):5353:5353 $(tag) + diff --git a/dnsmasq/dnsmasq.conf b/dnsmasq/dnsmasq.conf index e7cebff..25c4433 100644 --- a/dnsmasq/dnsmasq.conf +++ b/dnsmasq/dnsmasq.conf @@ -1,13 +1,8 @@ port=5353 bind-interfaces -#listen-address=172.17.0.2 resolv-file=/etc/resolv.dnsmasq.conf -#conf-dir=/etc/dnsmasq.d -#domain-needed -#local=/sqrrl-docker.net/ -#no-hosts -addn-hosts=/dnsmasq.hosts/ +addn-hosts=/dnsmasq.hosts expand-hosts -domain=sqrrl-lab.net +domain=testdomain.local log-queries diff --git a/dnsmasq/dnsmasq.hosts/README b/dnsmasq/dnsmasq.hosts/README new file mode 100644 index 0000000..fb9ffe5 --- /dev/null +++ b/dnsmasq/dnsmasq.hosts/README @@ -0,0 +1 @@ +# place hosts files in this directory and dnsmasq will pick them up at startup (no automatic re-load) diff --git a/zookeeper/Makefile b/zookeeper/Makefile index ae1775d..e4d915b 100644 --- a/zookeeper/Makefile +++ b/zookeeper/Makefile @@ -1,7 +1,6 @@ hostname := centos-base -thirdoctet := 20 +thirdoctet := 28 include ../shared/Makefile.vars -tag := "$(reg)/$(box_name):6" include ../shared/Makefile image: @@ -11,6 +10,4 @@ image: container: $(DOCKER_CMD) run -d --name=$(container_name) --publish=$(IP):2181:2181 $(tag) - $(DOCKER_CMD) ps -