Setting up and configuring a node
As the builders of the Redbelly network, we understand that running a node can be a daunting task. That's why, with our team's knowledge and experience, we have come up with this guide in order to help you launch a Redbelly node on your preferred cloud platform, whether it's AWS, GCP, Azure, or your physical machine.
In this documentation, we will explore the steps you can take to launch your very own Redbelly Node on the Redbelly Network including:
DNS Configuration
You can use any DNS provider. We only need the Fully Qualified Domain Name (FQDN) to be mapped to the IP of the server joining the Redbelly Network.
An FQDN consists of three labels, including the hostname, second-level domain name, and top-level domain name (TLD), each separated by a period, ending with a trailing period.
The following is an example of what an FQDN looks like:
FQDN = https://rbn-gcp-australia-southeast1-a-0-b-v2.devnet.redbelly.network
Sub domain = rbn-gcp-australia-southeast1-a-0-b-v2.devnet
Second-level domain name = redbelly
Top-level domain name = network
FQDNs indicate unique addresses on the internet. They’re also required for installing SSL certificates.
Enable TLS
The steps below use LetsEncrypt as a certificate provider, however, you can use any certificate provider of your choice.
Note that SSL certificate generation requires a Fully Qualified Domain Name (FQDN) to be available, also the certificate issued by LetsEncrypt is valid for 90 days and must be renewed before expiration to allow communication between your node and other nodes on the network.
Step 1: Login/SSH into your server
Syntax
ssh -i <private_key_path> <user>@<server_ip>
ssh <user>@<server_ip>
Example
<private_key_path> : ~/.ssh/server.pem
<user> : ubuntu
<server_ip> : 10.10.10.10
ssh -i ~/.ssh/server.pem ubuntu@10.10.10.10
ssh ubuntu@10.10.10.10
Step 2: Check package list
sudo apt update
Step 3: Install Certbot utility
sudo snap install --classic certbot
sudo ln -s /snap/bin/certbot /usr/bin/certbot
Step 4: Check processes
netstat -an | grep 80
Step 5: Download certificates
email=<YOUR_EMAIL_ADDRESS>
fqn=<YOUR_DNS/HOSTNAME_ADDRESS>
sudo certbot certonly --standalone -d $fqn. --non-interactive --agree-tos -m $email
sudo chown -R $USER:$USER /etc/letsencrypt/
Install/upgrade dependencies
sudo apt-get update
sudo apt-get install -y cron curl unzip
sudo DEBIAN_FRONTEND=noninteractive apt-get -y upgrade
Redbelly Binary/Genesis.json
Before we proceed with the Redbelly node setup we need to download particular files to the machine.
Step 1: Download files
Important!
You will need to access the Redbelly Developer Support Portal which you would have received an invite to if you were accepted into the Node Operator program.
Step 2: Rename binary
mv <Path_to_RedbellyBinary> rbbc
Step 3: Transfer file
Syntax
scp -i <private_key_path> <file_path> <user_name>@<server_ip>:<remote_directory>
scp <file_path> <user_name>@<server_ip>:<remote_directory>
Examples
scp -i ~/.ssh/server.pem ~/Download/genesis.json user_name@10.10.10.10:/home/user_name
scp ~/Download/genesis.json user_name@10.10.10.10:/home/user_name
Firewall configuration rules
Ensure that the firewall is installed on your node.
We need to allow certain ports through the firewall for TCP inbound.
The following example uses UFW and allows ports 80, 8545, 1888, and 1111
sudo ufw enable
sudo ufw allow 22
sudo ufw allow 80
sudo ufw allow 8545
sudo ufw allow 1888
sudo ufw allow 1111
The below ports are recommended, however, make sure you supply the same port values in the node registration form which you will find in Node Registration defined in the next section:
- 8545: HTTP-RPC port:
- 8546: WS-RPC port
- 1111: Recovery port
- 1888: Consensus port