Code Monkey home page Code Monkey logo

build-vpn-server's Introduction

Build Your Own VPN Server

This project offers an automation tool to let you securely build your high speed Shadowsocks and/or Wireguard VPN servers in one minute ⚡ using Github.com Action. With a 💰 5 USD/month server from common cloud providers like Linode, Digital Ocean, and so on, you can stream 4K videos (Speed >= 25 Mpbs) in real time. Once you generate your VPN server(s) configurations, you can simply scan the QR-code on mobile and start using the service immediately.

Shortlink: http://git.io/buildVPN Read this in other languages: English, įŽ€äŊ“中文

How to use

In summary, you need to fork this repository, set up your server credentials via Github Secrets, then manually run the workflows/actions to build your VPN servers, then scan the resulting QR codes to configure your client side apps.

Detailed Instruction

  1. Prerequisite: have SSH access to a server with root permission. If you don't have a server yet, buying a $5/month instance from Linode or Digital Ocean would be an easy start.
  2. Sign in to GitHub
  3. Fork this repository, by click the Fork button in the top-right corner of the page ☝ī¸ . Fork this project
  4. In your forked/own repository, set up Github Encrypted Secrets for your server: HOST, USERNAME, either PASSWORD or KEY, and optionally PORT if your port number is not default. Set your SSH credentials via Github Secrets
  5. On your repository navigation, click Actions, then click Build Shadowsocks Server or Build Wireguard Server, then click Run workflow (from main). Trigger a build VPN workflow Shadowsocks builds have vanilla Shadowsocks and Shadowsocks over kcptun (optimized for real time). Either Shadowocks over kcptun or Wireguard is very fast, you can build both for redundency. Please see more additional documentation for use case comparsion and configurations.
  6. The build should take one minute, once it's finished, check the result, under Configure your client step, there are your configurations and QR-code Configure your client
  7. â€ŧī¸ If your repository is public, Delete workflow run immediately after you successfully configure your client side app. Because, even though your secrets are masked in the log output, the generated QR-Code can reveal your secrets. Failing to do so can result in other people using your VPN without your permission. Delete workflow run, more doc

Client Side App configuration

Please see Client side app configurations.

Updates

This project/tool is probably quite different from most apps you have used. You don't have to download anything or run the code in your computer. Once you forked this project as the instruction says, you can keep your copy updated by pull from upstream if you are familiar with Git. Or you can simply delete your forked repository then start over.

Support & Contributing

You can open bug report, feature request or support request on this main project issues. Also, please read Contributing to Open Source Guides

build-vpn-server's People

Contributors

certaintls avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar

build-vpn-server's Issues

Stop existing containers that might have conflict

If a pipeline runs in the same server that has the VPN service running from the previous attempt, the pipeline should be able to stop the service before the conflict happens.

However, if the intended port is used by the user already, then the pipeline probably doesn't know how to stop it, and just throw an error.

Doesn't work as expected as of 15 Oct 2023

Getting error after running command

Unable to find image 'thomasleplus/qrcode:latest' locally
docker: Error response from daemon: pull access denied for thomasleplus/qrcode, repository does not exist or may require 'docker login': denied: requested access to the resource is denied.

Seems the thomasleplus/qrcode image is deleted by user

Some VPS doesn't have usermod

AWS Debian 10 AMI doesn't have usermod. See https://github.com/certaintls/build-VPN-server/runs/4679434635?check_suite_focus=true

err: bash: line 2: usermod: command not found
out: 
out: ================================================================================
out: 
out: To run Docker as a non-privileged user, consider setting up the
out: Docker daemon in rootless mode for your user:
out: 
out:     dockerd-rootless-setuptool.sh install
out: 
out: Visit https://docs.docker.com/go/rootless/ to learn about rootless mode.
out: 
out: 
out: To run the Docker daemon as a fully privileged service, but granting non-root
out: users access, refer to https://docs.docker.com/go/daemon-access/
out: 
out: WARNING: Access to the remote API on a privileged Docker daemon is equivalent
out:          to root access on the host. Refer to the 'Docker daemon attack surface'
out:          documentation for details: https://docs.docker.com/go/attack-surface/
out: 
out: ================================================================================
out: 
err: Got permission denied while trying to connect to the Docker daemon socket at unix:///var/run/docker.sock: Post "http://%2Fvar%2Frun%2Fdocker.sock/v1.24/containers/gost-ss-kcp/stop": dial unix /var/run/docker.sock: connect: permission denied
err: Got permission denied while trying to connect to the Docker daemon socket at unix:///var/run/docker.sock: Post "http://%2Fvar%2Frun%2Fdocker.sock/v1.24/containers/gost-ss/stop": dial unix /var/run/docker.sock: connect: permission denied
err: docker: Got permission denied while trying to connect to the Docker daemon socket at unix:///var/run/docker.sock: Post "http://%2Fvar%2Frun%2Fdocker.sock/v1.24/containers/create?name=gost-ss-kcp": dial unix /var/run/docker.sock: connect: permission denied.
err: See 'docker run --help'.
err: docker: Got permission denied while trying to connect to the Docker daemon socket at unix:///var/run/docker.sock: Post "http://%2Fvar%2Frun%2Fdocker.sock/v1.24/containers/create?name=gost-ss": dial unix /var/run/docker.sock: connect: permission denied.
err: See 'docker run --help'.
20***/01/01 13:20:40 Process exited with status 126

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.