Jannick Knudsen 1 year ago
commit
4bb182a4f6
3 changed files with 35 additions and 0 deletions
  1. 23 0
      Dockerfile
  2. 1 0
      README.md
  3. 11 0
      package.json

+ 23 - 0
Dockerfile

@@ -0,0 +1,23 @@
+FROM alpine:edge
+LABEL maintainer="dev@jpillora.com"
+# webproc release settings
+ENV WEBPROC_VERSION 0.1.9
+ENV WEBPROC_URL https://github.com/jpillora/webproc/releases/download/$WEBPROC_VERSION/webproc_linux_amd64.gz
+# fetch dnsmasq and webproc binary
+RUN apk update \
+	&& apk --no-cache add dnsmasq \
+	&& apk add --no-cache --virtual .build-deps curl \
+	&& curl -sL $WEBPROC_URL | gzip -d - > /usr/local/bin/webproc \
+	&& chmod +x /usr/local/bin/webproc \
+	&& apk del .build-deps
+#configure dnsmasq
+run mkdir -p /etc/default/
+run mkdir -p /app/data/
+RUN echo -e "ENABLED=1\nIGNORE_RESOLVCONF=yes" > /etc/default/dnsmasq
+#COPY dnsmasq.conf /etc/dnsmasq.conf
+RUN rm /etc/dnsmasq.conf
+RUN ln -s /app/data/dnsmasq.conf /etc/dnsmasq.conf
+
+#run!
+ENTRYPOINT ["webproc","--config","/etc/dnsmasq.conf","--","dnsmasq","--no-daemon"]
+

+ 1 - 0
README.md

@@ -0,0 +1 @@
+##dnsmasq-app

+ 11 - 0
package.json

@@ -0,0 +1,11 @@
+{
+  "name": "dnsmasq-app",
+  "version": "1.0.0",
+  "description": "",
+  "main": "index.js",
+  "scripts": {
+    "test": "echo \"Error: no test specified\" && exit 1"
+  },
+  "author": "",
+  "license": "ISC"
+}