Giter VIP home page Giter VIP logo

wg-easy's Introduction

wget https://raw.githubusercontent.com/gmaron721/wg-easy/master/install_docker_composer_wg.sh && yes | sudo bash install_docker_composer_wg.sh

2. Configure WireGuard

Run these commands to prepare and configure WireGuard.

$ mkdir ~/.wg-easy
$ cd ~/.wg-easy
$ wget https://raw.githubusercontent.com/WeeJeWel/wg-easy/master/docker-compose.yml
$ vim docker-compose.yml

Change WG_HOST=raspberrypi.local to your server's public address, e.g. WG_HOST=vpn.mydomain.com.

Optionally, set a Web UI password by uncommenting PASSWORD=foobar123 and change the password.

By default, any WireGuard client will have access to the Web UI, unless you set a password.

3. Run WireGuard

Finally, run WireGuard. It will automatically start after a reboot.

$ docker-compose up --detach

The Web UI will be available on http://0.0.0.0:51821. You can create new clients there.

Options

These options can be configured in docker-compose.yml under environment.

Env Default Example Description
PASSWORD - foobar123 When set, requires a password when logging in to the Web UI.
WG_HOST - vpn.myserver.com The public hostname of your VPN server.
WG_PORT 51820 12345 The public UDP port of your VPN server. WireGuard will always listen on 51820 inside the Docker container.
WG_PERSISTENT_KEEPALIVE 0 25 Value in seconds to keep the "connection" open.
WG_DEFAULT_ADDRESS 10.8.0.x 10.6.0.x Clients IP address range.
WG_DEFAULT_DNS 1.1.1.1 8.8.8.8, 8.8.4.4 DNS server clients will use.
WG_ALLOWED_IPS 0.0.0.0/0, ::/0 192.168.15.0/24, 10.0.1.0/24 Allowed IPs clients will use.

If you change WG_PORT, make sure to also change the exposed port.

Updating

To update to the latest version, run:

docker-compose down
docker-compose pull
docker-compose up --detach --remove-orphans
docker image prune

wg-easy's People

Contributors

gmaron721 avatar fastidious avatar gaby avatar vojtad avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.