mode89 / vpn-server-docker

OpenVPN server wrapped into a docker container

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

This repository provides a docker image wrapping OpenVPN server.

Prerequisites

  • Docker

Usage

First, build the docker image and configure the OpenVPN server:

  • run the vpn-configure-server script. It will build the image and initialize the certificate storage.
  • The /srv/openvpn directory of the host filesystem keeps the server configurtion files and it is mounted inside the container. The server.conf file is the OpenVPN server configuration file. The client.ovpn.base file is a template used for generation of the OpenVPN client configuration files. Modify these files to fit your requirements. Please see OpenVPN's documentation for more details.

To launch the server, run the vpn-run-server script. To stop the server, stop the docker container.

The vpn-server.service script can be used to manage the server with systemd.

To generate a configuration file for a new client, run the vpn-configure-client script with a single argument specifying the client identification name. This will generate a certificate and create a <client-identification-name>.ovpn file inside the /srv/openvpn/client-config directory. Copy this file and pass it to the OpenVPN client.

Contributing

If you'd like to improve the project, please make a pull request.

License

MIT

About

OpenVPN server wrapped into a docker container

License:MIT License


Languages

Language:Shell 89.8%Language:Dockerfile 10.2%