A bot used in my software engineering team's Discord server.
- Go 1.16
- discordgo
I wanted to create something in Go and creating a discord bot in order to make my team's lives easier was a good motivator!
The purpose of the bot is to return important information related to the class. It currently only returns the database instance assigned to each user in data.json
.
See .example.data.json
for what data.json
should look like.
These commands will work in any channels the bot has access to.
Command | Description |
---|---|
!db | Returns the connection details of the database instance assigned to you |
- Create a Discord bot here and invite it to your server.
- Copy the contents of
.example.data.json
to a file calleddata.json
and fill it out. - Copy the contents of
.example.dev
to a file called.env
and add your bot token to it. - Docker and Docker compose
Make sure you are in the root directory of the project when running these commands.
- Launching the bot:
sudo docker-compose up --build -d
- Stopping the bot:
sudo docker-compose down