Skip to content

Commit

Permalink
bump to webproc 0.2.2 and dnsmasq 2.80
Browse files Browse the repository at this point in the history
  • Loading branch information
jpillora committed Dec 22, 2018
1 parent 7ec5a8d commit 915ca1b
Show file tree
Hide file tree
Showing 5 changed files with 46 additions and 46 deletions.
1 change: 0 additions & 1 deletion .gitignore

This file was deleted.

4 changes: 2 additions & 2 deletions Dockerfile
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
FROM alpine:edge
LABEL maintainer="[email protected]"
# webproc release settings
ENV WEBPROC_VERSION 0.1.9
ENV WEBPROC_VERSION 0.2.2
ENV WEBPROC_URL https://github.com/jpillora/webproc/releases/download/$WEBPROC_VERSION/webproc_linux_amd64.gz
# fetch dnsmasq and webproc binary
RUN apk update \
Expand All @@ -11,7 +11,7 @@ RUN apk update \
&& chmod +x /usr/local/bin/webproc \
&& apk del .build-deps
#configure dnsmasq
run mkdir -p /etc/default/
RUN mkdir -p /etc/default/
RUN echo -e "ENABLED=1\nIGNORE_RESOLVCONF=yes" > /etc/default/dnsmasq
COPY dnsmasq.conf /etc/dnsmasq.conf
#run!
Expand Down
2 changes: 1 addition & 1 deletion LICENSE
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
The MIT License (MIT)

Copyright (c) 2016 Jaime Pillora
Copyright (c) 2018 Jaime Pillora

Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
Expand Down
78 changes: 39 additions & 39 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,57 +9,58 @@ dnsmasq in a docker container, configurable via a [simple web UI](https://github

1. Create a [`/opt/dnsmasq.conf`](http://oss.segetech.com/intra/srv/dnsmasq.conf) file on the Docker host

``` ini
#dnsmasq config, for a complete example, see:
# http://oss.segetech.com/intra/srv/dnsmasq.conf
#log all dns queries
log-queries
#dont use hosts nameservers
no-resolv
#use google as default nameservers
server=8.8.4.4
server=8.8.8.8
#serve all .company queries using a specific nameserver
server=/company/10.0.0.1
#explicitly define host-ip mappings
address=/myhost.company/10.0.0.2
```
```ini
#dnsmasq config, for a complete example, see:
# http://oss.segetech.com/intra/srv/dnsmasq.conf
#log all dns queries
log-queries
#dont use hosts nameservers
no-resolv
#use cloudflare as default nameservers, prefer 1^4
server=1.0.0.1
server=1.1.1.1
strict-order
#serve all .company queries using a specific nameserver
server=/company/10.0.0.1
#explicitly define host-ip mappings
address=/myhost.company/10.0.0.2
```

1. Run the container

```
$ docker run \
--name dnsmasq \
-d \
-p 53:53/udp \
-p 5380:8080 \
-v /opt/dnsmasq.conf:/etc/dnsmasq.conf \
--log-opt "max-size=100m" \
-e "HTTP_USER=foo" \
-e "HTTP_PASS=bar" \
--restart always \
jpillora/dnsmasq
```
```
$ docker run \
--name dnsmasq \
-d \
-p 53:53/udp \
-p 5380:8080 \
-v /opt/dnsmasq.conf:/etc/dnsmasq.conf \
--log-opt "max-size=100m" \
-e "HTTP_USER=foo" \
-e "HTTP_PASS=bar" \
--restart always \
jpillora/dnsmasq
```

1. Visit `http://<docker-host>:5380`, authenticate with `foo/bar` and you should see

<img width="833" alt="screen shot 2017-10-15 at 1 41 21 am" src="https://user-images.githubusercontent.com/633843/31580966-baacba62-b1a9-11e7-8439-ca1ddfe828dd.png">
<img width="833" alt="screen shot 2017-10-15 at 1 41 21 am" src="https://user-images.githubusercontent.com/633843/31580966-baacba62-b1a9-11e7-8439-ca1ddfe828dd.png">

1. Test it out with

```
$ host myhost.company <docker-host>
Using domain server:
Name: <docker-host>
Address: <docker-host>#53
Aliases:
```
$ host myhost.company <docker-host>
Using domain server:
Name: <docker-host>
Address: <docker-host>#53
Aliases:
myhost.company has address 10.0.0.2
```
myhost.company has address 10.0.0.2
```

#### MIT License

Copyright &copy; 2016 Jaime Pillora &lt;[email protected]&gt;
Copyright &copy; 2018 Jaime Pillora &lt;[email protected]&gt;

Permission is hereby granted, free of charge, to any person obtaining
a copy of this software and associated documentation files (the
Expand All @@ -80,5 +81,4 @@ CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.


[dockerhub]: https://hub.docker.com/r/jpillora/dnsmasq/
7 changes: 4 additions & 3 deletions dnsmasq.conf
Original file line number Diff line number Diff line change
Expand Up @@ -4,9 +4,10 @@
log-queries
#dont use hosts nameservers
no-resolv
#use google as default nameservers
server=8.8.4.4
server=8.8.8.8
#use cloudflare as default nameservers, prefer 1^4
server=1.0.0.1
server=1.1.1.1
strict-order
#serve all .company queries using a specific nameserver
server=/company/10.0.0.1
#explicitly define host-ip mappings
Expand Down

0 comments on commit 915ca1b

Please sign in to comment.