Open-source community made discord bot for discord.gg/Minehut
Report Bug
—
Request Feature
MinehutUtils is a community made discord bot for discord.gg/Minehut. It is made with Kotlin, JDA and Iron. For the full list of dependencies check out the dependency graph.
MinehutUtils is what's currently being used in the Minehut Official Discord and provides users with the functionality to view server information, network information, and advertise both their servers and services.
The following is a full list of commands that MinehutUtils provides:
Command | Description | Public |
---|---|---|
server |
Displays information about a Minehut Server | ✅ |
network |
Displays information about the Minehut Network | ✅ |
status |
Calculates the status of core Minehut services | ✅ |
marketplace |
Either request or offer your services | ✅ |
cooldown view |
View server and your cooldown | ✅ |
cooldown |
Manage user's cooldowns | ❌ |
settings |
Change the bot settings or behaviour | ❌ |
This guide assumes you've already made a Discord Bot and retrieved your bot token.
Running the bot with docker is the easiest way to get started and recommended for most users.
-
Pull the docker image from github packages
docker pull ghcr.io/santiomc/minehututils:master
-
Run the docker image
docker run -d --rm \ -e TOKEN=<your bot token> \ ghcr.io/santiomc/minehututils:master
Note: Since the bot uses a database to store cooldowns and settings, you'll need to mount a volume to store the database. You can do this by adding a mount for
/data
to the docker container.
If you want to run the bot with docker-compose, you can use the predefined docker-compose.yml file (or create your own).
-
Download the docker-compose.yml file
curl -O https://raw.githubusercontent.com/SantioMC/MinehutUtils/master/docker-compose.yml
-
Create a
.env
and attach your bot token.TOKEN=your bot token
-
Run the docker-compose.yml file
docker compose up -d
If you want to run the bot without a container, you can do so by following these steps:
-
Clone the repository
git clone https://github.com/SantioMC/MinehutUtils
-
Build the project
./gradlew shadowJar
-
Run the jar file
java -jar build/libs/MinehutUtils-<version>.jar
The bot by default should now have most things working, however a bit of configuration is needed
to get both the marketplace setup. You can use the settings command to configure how the marketplace works.
Start with using /settings channel marketplace channel:
to configure which channel marketplace postings are sent
to. You can then use /settings cooldown marketplace cooldown:
to configure the cooldown for the marketplace command.
The cooldown is applied per listing kind per user.
The bot no longer uses environment variables to configure the log channel, instead you can use the /settings log channel:
command to configure the log channel. This allows for per-guild log channels.
Below are a list of all possible environment variables that can be set to configure the bot.
Variable | Description | Default |
---|---|---|
DB_FILE | Where the sqlite file is located | data/minehut.db |
TOKEN | The bot token |
Thanks for everyone who has already contributed, and anyone willing to. This is a community bot and your contributions are what makes it great. If you aren't able to make a pull request, you can always open an issue with a bug report or feature request here on github
- Fork the repository
- Clone your fork
git clone https://github.com/YOUR_USERNAME/MinehutUtils
- Create the changes you want to make
- Commit and push your changes
git add . git commit -m "Your commit message" git push
- Create a pull request at https://github.com/SantioMC/MinehutUtils/pulls