Warning
This is no longer supported as native Gnosis Chain support has been introduced. Please consider using the alternative setup path provided is official documentation.
This document describes how to run Nimbus beacon node + Nimbus validator for the Gnosis Beacon Chain.
See a similar repo with Prysm node setup - https://github.com/gnosischain/prysm-launch See a similar repo with Lighthouse node setup - https://github.com/gnosischain/lighthouse-launch
- This document assumes that you already have an xDai node available for your use (or public JSON RPC endpoint)
- You have already generated your validator accounts using the fork of the official deposit-cli - https://github.com/gnosischain/deposit-cli. You will need validator keystores and passwords for them to run the validator client.
- You might start your node and validator first, and only them make a deposit, once everything works.
- You have a persistent linux VM with docker installed on it, which is accessible from the public internet via a fixed IP address. We recommend using a VM with at least 4 vCPU, 8 GB RAM, 100 GB SSD
- Create an empty directory somewhere on the VM (e.g.
/root/gbc
) - Clone the repository with all necessary configs:
cd /root/gbc
git clone https://github.com/gnosischain/nimbus-launch .
- Copy all validators keystore files to the
./keys/validator_keys
directory. Ensure that copied keystores are only used on a single VM instance. - Create
.env
file from the example at.env.example
. Put the valid external IP address of your VM and an xDAI RPC url in the config. Other values can be left without changes.
If it is required to send the node and validator logs to a remote syslog server the following actions can be done (it is assumed that the node and validator will be run by using the docker-compose-syslog.yml
file with the docker-compose
command in the instructions below).
- Copy
./syslog/etc/logrotate.d/docker-logs
to/etc/logrotate.d/
. - Copy
./syslog/etc/rsyslog.d/30-gbc-local.conf
and./syslog/etc/rsyslog.d/35-gbc-remote-logging.conf
to/etc/rsyslog.d/
. - Modify
target
andport
in/etc/rsyslog.d/35-gbc-remote-logging.conf
to point to a remote syslog server. - Restart the rsyslog service by
systemctl restart rsyslog
.
- Run the following command to import and all added keystore files, you will be prompted to enter keystore password you have used during key generation:
docker-compose run validator-import
- Nimbus can be configured to start from the finalized state obtained from the trusted source. This allows to start validating almost immediately. Trusted sync can be executed before running the node for the first time:
docker-compose up trusted-sync
- Run the following command to start the beacon node:
docker-compose up -d node
docker-compose logs -f node
- Your node should find other peers and start syncing with the rest of the network
- Run the following command to start the prometheus server, it will allow to use grafana's dashboards (configured separately):
docker-compose up -d prometheus
Update repository configs to a newer version should be as easy as pulling new changes from the repo and restarting the node. For example, the following sequence of commands should work in most of the cases.
git pull
docker-compose down --remove-orphans
docker-compose up -d node prometheus