From 0f1c44e21bb74cc8f975977cfe912a20abe583fe Mon Sep 17 00:00:00 2001 From: yohan <783b8c87@scimetis.net> Date: Sun, 14 Apr 2019 18:38:58 +0200 Subject: [PATCH] Initial commit. --- Dockerfile | 12 ++++++++++++ build | 1 + 2 files changed, 13 insertions(+) create mode 100644 Dockerfile create mode 100644 build diff --git a/Dockerfile b/Dockerfile new file mode 100644 index 0000000..5a62b16 --- /dev/null +++ b/Dockerfile @@ -0,0 +1,12 @@ +FROM debian:stretch +MAINTAINER yohan <783b8c87@scimetis.net> +ENV DEBIAN_FRONTEND noninteractive +RUN echo "deb http://http.debian.net/debian stretch-backports main" >> /etc/apt/sources.list +RUN apt-get update && apt-get -y install openvpn procps iptables +ENV TZ=Europe/Paris +RUN ln -snf /usr/share/zoneinfo/$TZ /etc/localtime && echo $TZ > /etc/timezone +RUN mkdir -p /etc/openvpn/server/ccd +RUN mkdir -p /etc/openvpn/server/keys +RUN touch /etc/openvpn/server/server.conf +EXPOSE 1194/udp +ENTRYPOINT ["/usr/sbin/openvpn", "--mode", "server", "--topology", "subnet", "--proto", "udp", "--port", "1194", "--dev", "tun", "--server", "192.168.102.0", "255.255.255.0", "--push", "route 192.168.102.0 255.255.255.0", "--client-to-client", "--keepalive", "10", "120", "--persist-tun", "--persist-key", "--comp-lzo", "yes", "--remote-cert-tls", "client", "--cipher", "AES-256-CBC", "--ca", "/etc/openvpn/server/keys/ca.crt", "--cert", "/etc/openvpn/server/keys/server.crt", "--dh", "/etc/openvpn/server/keys/dh1024.pem", "--key", "/etc/openvpn/server/keys/server.key", "--client-config-dir", "/etc/openvpn/server/ccd", "--config", "/etc/openvpn/server/server.conf"] diff --git a/build b/build new file mode 100644 index 0000000..190b2cc --- /dev/null +++ b/build @@ -0,0 +1 @@ +docker build -t openvpn-server .