Copy the .env.example file to .env and set the appropriate environment variables:
cp.env.example.env
The "email" section of the .env file is optional. If you want to receive emails when layer is down, input your gmail username and password. We recommend using an app password for your gmail account.
Other than the email section, all .env variables can alternatively be set through the CLI. We recommend setting your ethereum private key in the .env file for security reasons. For convenience, you should set any parameters which tend to remain constant across runs in the .env file. CLI arguments will override .env variables.
Additional Requirements for Ubuntu
If you are running the relayer on ubuntu, you may need to install additional tools:
After installing these dependencies, proceed with the setup instructions above.
Usage
The relayer provides several commands through its CLI:
Start Relaying
Update Oracle Data Once
Relay Token Bridge Withdraw
Initialize Data Bridge
This command initializes the TellorDataBridge contract after deployment. This must be run by the contract deployer address.
Reset Data Bridge
This command resets the validator set in the TellorDataBridge contract in the event that the last relayed validator set is over 21 days old. This can only be run by the TellorDataBridge contract’s guardian address.