- You will need to create a discord bot (do this at https://discord.com/developers/applications)
- Give the bot the "bot" role and "Manage Roles" permission, copy the oauth url it gives, and authorize it for your discord server
- Make sure the role you give the bot in your discord is above all your users and make sure it also has "Manage Roles" permission checked
- Clone this repository
- Copy config.json.sample and rename config.json
- Enter your discord bot token (you get this from the discord bot developer section)
- Install nodejs on your OS
- Run the following command (in git directory) to install discord.js
npm install discord.js
- Run the following command (in git directory) to run the bot
node bot.js
- Install docker on your OS
- Run following command to build the docker image in git directory
docker build -t discord-bot .
- Run following command to run the newly created image
docker run -d discord-bot
- To see logs
docker logs <container-name>