A Discord bot for managing self-roles and persistent roles.
In February 2023, Discord integrated self-roles natively into Discord via Community Onboarding, which has made the majority of this bot's purpose obsolete. At a date TBA, a new bot under the same name will be purposed to handle activity roles in the Brackeys Community Discord server and will remain closed source to prevent gaming the system. As a result this repository will move to a new name and be publicly archived.
If you have forked or cloned this repository, be aware that your upstream URL will need to change when this happens.
Cloak is a Discord bot which provides features to allow members to assign self-roles, as well as for staff members to designate certain roles as "persistent", such that the roles are automatically reapplied to members who previously had them in the even that they leave and rejoin the guild.
Cloak runs in a Docker container, and there is a docker-compose.yaml file which simplifies this process.
To start off, clone the repository into your desired directory:
git clone https://github.com/BrackeysBot/Cloak.git
Step into the Cloak directory using cd Cloak
, and continue with the steps below.
The bot's token is passed to the container using the DISCORD_TOKEN
environment variable. Create a file named .env
, and add the following line:
DISCORD_TOKEN=your_token_here
Two directories are required to exist for Docker compose to mount as container volumes, data
and logs
:
mkdir data
mkdir logs
The logs
directory is used to store logs in a format similar to that of a Minecraft server. latest.log
will contain the log for the current day and current execution. All past logs are archived.
The data
directory is used to store persistent state of the bot, such as config values and the infraction database.
There is currently no configuration file required to run Cloak.
To launch Cloak, simply run the following commands:
sudo docker-compose build
sudo docker-compose up --detach
To update Cloak, simply pull the latest changes from the repo and restart the container:
git pull
sudo docker-compose stop
sudo docker-compose build
sudo docker-compose up --detach
For further usage breakdown and explanation of commands, see USAGE.md.
This bot is under the MIT License.
This bot is tailored for use within the Brackeys Discord server. While this bot is open source and you are free to use it in your own servers, you accept responsibility for any mishaps which may arise from the use of this software. Use at your own risk.