Self hosting
HyperPath lets you self-host its back-end components on your own infrastructure for complete control and privacy. This enables you to keep both your data and control plane within your own network, and even run HyperPath on air-gapped networks.
Overview
The self-hosted solution can be deployed using a single Docker Compose file. It includes the following services:
- Controller: The Controller is the central management component of the HyperPath network.
- Admin Console: The Admin Console is a web-based interface that allows you to manage your HyperPath network by interacting with the controller backend.
- Database: The Database is used to store the configuration and performance data of the HyperPath network.
- Caddy Server: The Caddy server is used as a reverse proxy and provides SSL termination for the Admin Console and Controller.
- CoTurn Server: The CoTurn server is used for NAT traversal and is required for establishing connections between nodes that are behind NATs or firewalls.
Prerequisites
To self-host HyperPath, you need the following:
- Virtual machine: running any Linux OS with at least 2 CPU cores, 4GB of RAM, and 20GB of disk space
- Domain name: pointing to the public IP address of your Virtual Machine, at least during the initial setup, to obtain SSL certificates from Let's Encrypt
Installation
Step 1: Install Docker and Docker Compose
First, you need to install Docker and Docker Compose on your Virtual Machine.
Step 2: Create the configuration files
To simplify the process, we created a setup script that will create the Docker compose and Caddy config files. You can run the script by running the following command:
bash -c "$(curl -fsSL http://www.hyperpath.ie/create-hyperpath-selfhosting.sh)"
The command will ask for
- Domain name: The domain name that you will be using to access the Admin Console
- API port: The port that the controller WebSocket API will listen on
After running the script, you will have a docker-compose.yml
file and a Caddyfile
in the current directory.
Run
To start the services, run the following command:
docker-compose up -d
This will start the HyperPath controller, Admin Console, Database, Caddy server, and CoTurn server. The Admin Console will be accessible at https://<your-domain-name>
. You will be greeted with a login page where you can sign up and create your first HyperNet.
The installation commands for HyperPath nodes and Docker containers in the Admin console will automatically include the new domain provided during the setup.