Sentinel dVPN OpenVPN Node Hosting

October 25, 2018 ยท View on GitHub

This is a complete guide to enable a configure use the Sentinel dVPN OpenVPN Node on Linux with docker and share unused bandwidth to the Sentinel Network.

Setup Instructions

Here are the steps involved in getting a Sentinel dVPN OpenVPN Node up and running:

  1. Install docker
  2. Build/pull the Sentinel dVPN docker image
  3. Configure Node

Installing the latest version of docker in Ubuntu or Debian based releases

Below are the instructions on installing docker:

  1. Install required dependencies to get docker installation script from get.docker.com

    sudo apt install -y curl

    curl -fsSL get.docker.com -o /tmp/get-docker.sh

  2. Run the downloaded script to setup & install docker

    sudo sh /tmp/get-docker.sh

  3. Add current user to the docker group to give required access

    sudo usermod -aG docker $USER

Running the Sentinel dVPN Node

You can set up and run VPN node in two ways:

  1. Quick Run - download docker image from Docker Hub
  2. DIY - build your own docker image from the Sentinel code repository

Method #1 [Download docker image from Docker Hub]

  1. Navigate to the User's home directory

    cd ~

  2. Create a new folder to pull the docker image and run it

    mkdir -p $HOME/.sentinel

  3. Pull the official Sentinel docker image from Docker Hub & configure the node

    sudo docker run -it --privileged --mount type=bind,source=$HOME/.sentinel,target=/root/.sentinel -p 3000:3000 -p 1194:1194/udp sentinelofficial/sentinel-vpn-node

Method #2 [Build Your Own Docker Image]

Do-it-Yourself setup by building your own docker image

  1. Navigate to the root folder or anywhere that you want to set up the project and download code from the repository

    cd ~

  2. Clone the Sentinel repository

    git clone https://github.com/sentinel-official/sentinel.git

  3. Navigate to the folder with code to build the docker image

    cd ~/sentinel/vpn-node-docker

  4. Build the docker image

    sudo docker build --file Dockerfile.prod --tag sentinel-vpn-node --force-rm --no-cache .

  5. Navigate to the folder where the docker container was set up. In our case, it is the User's home directory.

    mkdir -p $HOME/.sentinel

  6. Run the image and configure the node

    sudo docker run -it --privileged --mount type=bind,source=$HOME/.sentinel,target=/root/.sentinel -p 3000:3000 -p 1194:1194/udp sentinel-vpn-node

Updating an existing Sentinel dVPN OpenVPN Node

  1. Stop the running docker container

    sudo docker stop $(sudo docker ps -aq -f ancestor=sentinelofficial/sentinel-vpn-node)

  2. Remove the older version of docker container

    sudo docker rm -f $(sudo docker ps -aq -f ancestor=sentinelofficial/sentinel-vpn-node)

  3. Remove the older version of docker image

    sudo docker rmi -f $(sudo docker images -aq -f reference=sentinelofficial/sentinel-vpn-node)

  4. Set the token value to an EMPTY STRING in the config file

    Config file location: $HOME/.sentinel/config.data

    Example: {"token": "", "enc_method": "AES-256-CBC", "account_addr": "0x656b756e6c6335302e676c343572357232786970", "price_per_gb": 125.0}

After completing the above steps please follow the instructions on Method #1 to get the node up and running again.

Helpful docker commands to interact with the Sentinel dVPN Node