Monitoring Bot Setup
Overview of How To Set-up and Run an oSnap Monitoring Bot
The oSnap Monitoring Bot monitors all transactions to your oSnap module. It also verifies that proposed transactions are valid according to the rules of the oSnap module (ie. the snapshot quorum and voting period meet the oSnap rules). Any unverified proposed transactions should be reviewed further and possibly disputed.
All oSnap propsals are already monitored by bots run by UMA's core team and a decentralized group of human verifiers. You may wish to run this bot so you can monitor your oSnap module yourself.
This tutorial walks through an example of how to setup the oSnap monitoring bot from UMA's protocol repository that watches for emitted contract events and sends alerts.
The Node package method described below is also available on Youtube.
Installation
Docker method
The instructions assume you have Docker installed and its server daemon is running.
Get the latest UMA protocol image that among others includes the required monitoring bot:
Node package method
The instructions assume you have already the latest long term support version of Node.js.
Initialize new project directory and install @uma/monitor-v2
package that contains the oSnap monitoring bot:
Basic configuration
All configuration for the monitor bot should be set in a .env file in your working directory. Please see basic configuration variables below:
Running the bot
Docker method
Instruct docker to run the oSnap monitor bot by appending COMMAND
environment variable to the same .env
file where other configuration is stored:
Start the monitoring bot from the same working directory where the .env
configuration file is located:
This should start the oSnap module monitoring bot in a looping mode detached from console where all configured events will be sent to the provided notification channels.
Stop the running bot container with:
Node package method
Start the monitoring bot from the root of your project directory where node package was installed and .env
configuration file is stored:
This starts the oSnap module monitoring bot in a looping mode where all configured events will be logged in the console.
Last updated