bot for monitoring EVM gas fees
Go to file
MrTuxedo 31d5a250b5 Don't import .env explicitly 2023-04-23 11:14:02 -07:00
src retry forever? 2023-04-22 20:48:28 -07:00
types Refactor to compute GasPrices differently 2023-04-22 15:58:38 -07:00
.dockerignore Initial commit 2023-04-17 18:49:20 -07:00
.gitignore Initial commit 2023-04-17 18:49:20 -07:00
Dockerfile Don't import .env explicitly 2023-04-23 11:14:02 -07:00
LICENSE Initial commit 2023-04-17 18:49:20 -07:00
README.md Don't import .env explicitly 2023-04-23 11:14:02 -07:00
docker-compose.yml save to disk every 5 minutes 2023-04-18 17:02:29 -07:00
package-lock.json handle observable errors 2023-04-22 11:46:24 -07:00
package.json handle observable errors 2023-04-22 11:46:24 -07:00
tsconfig.json Initial commit 2023-04-17 18:49:20 -07:00

README.md

Gwei Alert Bot

Introduction

This repo contains Docker build files for a Discord bot built with Node.js and utilizes a composed Redis container for storage.

Requirements

  • Docker + Docker Compose
  • A Discord bot token
  • A EVM RPC endpoint URL (websocket enabled) OR a local node running at localhost:8545 (using docker host network mode)

Usage

  1. Clone the repository to your local machine
git clone https://git.ssh.surf/MrTuxedo/gwei-alert-bot.git
  1. Add the following environment variables to the runtime container via docker-compose.yml:
RPC_URL=<your rpc url>
DISCORD_BOT_TOKEN=<your discord bot token>
DISCORD_CLIENT=<your discord client ID>
  1. Run the Docker container
docker compose up -d

Rebuilding with new changes

  1. Stop the running bot and remove container by same name
docker compose down
  1. Pull the new work
git pull
  1. Build and Run
docker compose up -d --build

Environment Variables

The following environment variables must be set in docker-compose.yml in order for the bot to function properly:

  • RPC_URL: Your RPC url
  • DISCORD_BOT_TOKEN: the Oauth2 token for your Discord bot.
  • DISCORD_CLIENT: the client ID for your Discord bot. (app ID)

License

WTFPL