diff --git a/README.md b/README.md index 701f37f..b3e0eae 100644 --- a/README.md +++ b/README.md @@ -280,6 +280,7 @@ A collection of delicious docker recipes. - [x] stunnel-arm - [x] tinyproxy - [x] tor +- [x] wireproxy ## VPN diff --git a/wireproxy/Dockerfile b/wireproxy/Dockerfile new file mode 100644 index 0000000..4208467 --- /dev/null +++ b/wireproxy/Dockerfile @@ -0,0 +1,22 @@ +# +# Dockerfile for wireproxy +# + +FROM alpine:3 +MAINTAINER EasyPi Software Foundation + +ARG WIREPROXY_VERSION=1.0.8 +ARG WIREPROXY_OS=linux +ARG WIREPROXY_ARCH=amd64 +ARG WIREPROXY_FILE=wireproxy_${WIREPROXY_OS}_${WIREPROXY_ARCH}.tar.gz +ARG WIREPROXY_URL=https://github.com/pufferffish/wireproxy/releases/download/v${WIREPROXY_VERSION}/${WIREPROXY_FILE} + +RUN set -xe \ + && apk add --no-cache curl \ + && curl -sSL ${WIREPROXY_URL} | tar xz -C /usr/local/bin/ \ + && wireproxy --version \ + && apk del curl + +EXPOSE 9080 + +CMD ["wireproxy", "--info", "0.0.0.0:9080", "--config", "/etc/wireproxy/wireproxy.conf"] diff --git a/wireproxy/README.md b/wireproxy/README.md new file mode 100644 index 0000000..ac7693c --- /dev/null +++ b/wireproxy/README.md @@ -0,0 +1,17 @@ +wireproxy +========= + +[wireproxy][1] is a completely userspace application that connects to a +wireguard peer, and exposes a socks5/http proxy or tunnels on the machine. + +```bash +$ docker compose up -d +$ curl -x socks5h://127.0.0.1:1080 ipinfo.io +$ curl -x 127.0.0.1:3128 ipinfo.io +$ curl 127.0.0.1:9080/metrics +``` + +Click [here][2] to get a free wireguard account. + +[1]: https://github.com/pufferffish/wireproxy +[2]: https://opentunnel.net/wireguard/ diff --git a/wireproxy/data/wireproxy.conf b/wireproxy/data/wireproxy.conf new file mode 100644 index 0000000..0f6bb0a --- /dev/null +++ b/wireproxy/data/wireproxy.conf @@ -0,0 +1,20 @@ +[Interface] +PrivateKey = xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx +Address = 10.200.200.2/32 +DNS = 10.200.200.1 + +[Peer] +PublicKey = xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx +AllowedIPs = 0.0.0.0/0 +Endpoint = x.x.x.x:51820 +PersistentKeepalive = 25 + +[Socks5] +BindAddress = 0.0.0.0:1080 + +[http] +BindAddress = 0.0.0.0:3128 + +[TCPClientTunnel] +BindAddress = 0.0.0.0:5353 +Target = 8.8.8.8:53 diff --git a/wireproxy/docker-compose.yml b/wireproxy/docker-compose.yml new file mode 100644 index 0000000..b3dc97d --- /dev/null +++ b/wireproxy/docker-compose.yml @@ -0,0 +1,10 @@ +version: "3.8" +services: + wireproxy: + image: vimagick/wireproxy + ports: + - "1080:1080" + - "3128:3128" + volumes: + - ./data:/etc/wireproxy + restart: unless-stopped