Skip to content
This repository has been archived by the owner on Sep 29, 2023. It is now read-only.

A discord bot to manage trainings and sign ups for the Crossroads Inn Guild Wars 2 community

License

Notifications You must be signed in to change notification settings

salcatroppa/crossroadsbot

 
 

Repository files navigation

Crossroads

Crossroads Inn signup bot

Setup

Following a non config file approach required tokens and paths are passed to the application with environment variables. To not pollute your environment while developing check out the .env file section below

Docker Compose setup

Copy docker-compose.yml.example to docker-compose.yml like so: cp docker-compose.yml.example docker-compose.yml. Then edit docker-compose.yml and fill the missing fields with your discord bot token and your discord guild and role id's. At last start the bot and the postgres database in detached mode with docker-compose up -d.

Environment variables

DATABASE_URL

URL to postgres database.
Example: DATABASE_URL=postgres://username:password@localhost/crossroad

DISCORD_TOKEN

The discord bot token to be used. Check here for more information.

APPLICATION_ID

The application id of the bot. This is required to use buttons

MAIN_GUILD_ID

The main discord guild id the bot will be used on. This is also the discord where role permissions are taken from

EMOJI_GUILD_ID

The discord guild the bot will load and use custom emojis from.

SQUADMAKER_ROLE_ID

The discord role id for MAIN_GUILD_ID that has access to all commands

RUST_LOG

Amount of LOG verbosity. Options are: warn, info, debug

.env file

A .env file can be placed in the root directory of the project that will be sourced when the application is started and for all tests.
Example ./.env file content:

DATABASE_URL=postgres://username:password@localhost/crossroad
DISCORD_TOKEN=AVERYLONGSECRETTOKENTHATSHOULDNEVERBEMADEPUBLIC
MAIN_GUILD_ID=111222333444555666
EMOJI_GUILD_ID=111222333444555666
SQUADMAKER_ROLE_ID=666777888999000111
RUST_LOG=info

About

A discord bot to manage trainings and sign ups for the Crossroads Inn Guild Wars 2 community

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • Rust 99.2%
  • Other 0.8%