sudo apt update
sudo apt install direnv
# bash users - add the following line to your ~/.bashrc
eval "$(direnv hook bash)"
source ~/.bashrc
# zsh users - add the following line to your ~/.zshrc
eval "$(direnv hook zsh)"
source ~/.zshrc
change the NODE_ETHEREUM_MAINNET
NODE_ETHEREUM_MAINNET="https://rpc.api.moonbase.moonbeam.network"
Start Services
Load env vars into the shell.
$ direnv allow .
# make sure you see output these being loaded
direnv: loading ~/rudder/.envrc
direnv: loading ~/rudder/.envrc.local
direnv: export +BLOCK_RESULT_OPERATOR_PRIVATE_KEY +ERIGON_NODE +EVM_SERVER_URL +IPFS_PINNER_URL +NODE_ETHEREUM_MAINNET +WEB3_JWT
Start all 3 services in the background for Moonbase alpha
$ docker compose -f "docker-compose-mbase.yml" up -d --remove-orphans
[+] Running 3/3
⠿ Container rudder Started 3.2s
⠿ Container ipfs-pinner Started 1.9s
⠿ Container evm-server Started 1.8s
NOTE: On a system where an ipfs-pinner instance is already running, check the instruction in the Appendix to run rudder docker alongside.
Monitor the logs for Block Result submissions.
$ docker compose -f "docker-compose-mbase.yml" logs -f
rudder | [info] curr_block: 4591264 and latest_block_num:4591263
ipfs-pinner | 2023/06/22 13:45:49 Received /health request: source= 127.0.0.1:54420 status= OK
rudder | [info] curr_block: 4591264 and latest_block_num:4591263
ipfs-pinner | 2023/06/22 13:46:00 Received /health request: source= 127.0.0.1:54430 status= OK
rudder | [info] curr_block: 4591264 and latest_block_num:4591264
rudder | [info] listening for events at 4591264
rudder | [info] found 0 bsps to process
Deployment As Service Unit
Optional
Here you can find an example of a systemd service unit file that can be used to auto-start/restart of the docker-compose service for Refiner.