From 4a4688223e8a247248bb79293c5da71685e18862 Mon Sep 17 00:00:00 2001 From: kev Date: Wed, 17 Jun 2015 11:51:23 +0800 Subject: [PATCH] update --- dante/Dockerfile | 36 ++++++++++++++++++++++++------- dante/{danted.conf => sockd.conf} | 10 +++++---- 2 files changed, 34 insertions(+), 12 deletions(-) rename dante/{danted.conf => sockd.conf} (58%) diff --git a/dante/Dockerfile b/dante/Dockerfile index 829409d..44d2321 100644 --- a/dante/Dockerfile +++ b/dante/Dockerfile @@ -5,15 +5,35 @@ FROM debian:jessie MAINTAINER kev -RUN apt-get update \ - && apt-get install -y curl \ - && curl -o dante-server.deb http://ftp.us.debian.org/debian/pool/main/d/dante/dante-server_1.1.19.dfsg-3+b3_amd64.deb \ - && dpkg -i dante-server.deb || apt-get install -f -y \ - && apt-get purge -y --auto-remove curl \ - && rm -rf dante-server.deb /var/lib/apt/lists/* -ADD danted.conf /etc/danted.conf +ENV DANTE_VER 1.4.1 +ENV DANTE_URL https://www.inet.no/dante/files/dante-$DANTE_VER.tar.gz +ENV DANTE_MD5 68c2ce12119e12cea11a90c7a80efa8f +ENV DANTE_FILE dante.tar.gz +ENV DANTE_TEMP dante +ENV DANTE_DEPS build-essential curl + +RUN apt-get update \ + && apt-get install -y $DANTE_DEPS \ + && mkdir $DANTE_TEMP \ + && curl -sSL $DANTE_URL -o $DANTE_FILE \ + && echo "$DANTE_MD5 $DANTE_FILE" | md5sum -c \ + && tar xzf $DANTE_FILE --strip 1 \ + && ./configure \ + && make install \ + && cd .. \ + && rm -rf $DANTE_TEMP \ + && apt-get purge -y --auto-remove $DANTE_DEPS \ + && rm -rf /var/lib/apt/lists/* + +ADD sockd.conf /etc/sockd.conf + +ENV CFGFILE /etc/sockd.conf +ENV PIDFILE /tmp/sockd.pid +ENV WORKERS 10 +ENV VERBOSE 4 EXPOSE 1080 -CMD danted -f /etc/danted.conf +CMD sockd -f $CFGFILE -p $PIDFILE -N $WORKERS -d $VERBOSE + diff --git a/dante/danted.conf b/dante/sockd.conf similarity index 58% rename from dante/danted.conf rename to dante/sockd.conf index 5e27a3f..15ba1d5 100644 --- a/dante/danted.conf +++ b/dante/sockd.conf @@ -1,16 +1,18 @@ logoutput: stderr internal: eth0 port = 1080 external: eth0 -method: username none -clientmethod: username none -user.privileged: root -user.notprivileged: nobody +socksmethod: username none +clientmethod: none +user.privileged: nobody +user.unprivileged: nobody client pass { from: 0.0.0.0/0 port 1-65535 to: 0.0.0.0/0 + log: connect error } pass { from: 0.0.0.0/0 to: 0.0.0.0/0 protocol: tcp udp + log: connect }