Crates.io | minebot |
lib.rs | minebot |
version | 1.0.0 |
source | src |
created_at | 2024-07-31 17:12:21.04172 |
updated_at | 2024-07-31 17:12:21.04172 |
description | A simple Discord bot to interact with your Minecraft server |
homepage | https://github.com/The-Noah/minebot |
repository | https://github.com/The-Noah/minebot |
max_upload_size | |
id | 1321123 |
size | 56,032 |
A simple Discord bot to interact with your Minecraft server.
There are multiple ways to run the bot, or you can build from source.
compose.yaml
file with the following content:version: "3.8"
services:
minebot:
image: ghcr.io/the-noah/minebot:latest
container_name: minebot
restart: unless-stopped
environment:
- DISCORD_TOKEN=your_discord_bot_token
- GUILD_ID=your_discord_guild_id
- MINECRAFT_IP=your_minecraft_server_ip
docker compose up -d
docker run -d --name minebot \
-e DISCORD_TOKEN=your_discord_bot_token \
-e GUILD_ID=your_discord_guild_id \
-e MINECRAFT_IP=your_minecraft_server_ip \
ghcr.io/the-noah/minebot:latest
cargo install minebot
.env
file in the root of the project and add the following:DISCORD_TOKEN=your_discord_bot_token
GUILD_ID=your_discord_guild_id
MINECRAFT_IP=your_minecraft_server_ip
minebot
The bot will automatically register slash commands when it starts. You can use the following commands:
/ping
- Check if the bot is online/status
- Get the status of the Minecraft server with player info/say
- Send a message in Minecraft chat as the server (requires admin permissions on Discord)/whitelist
/whitelist add <username>
- Add a player to the whitelist (requires admin permissions on Discord)/whitelist remove <username>
- Remove a player from the whitelist (requires admin permissions on Discord)/whitelist list
- List all players on the whitelist (requires admin permissions on Discord)The bot will also automatically update its status to show the number of players online.
git clone https://github.com/The-Noah/minebot.git
cd minebot
cargo build --release
.env
file in the root of the project and add the following:DISCORD_TOKEN=your_discord_bot_token
GUILD_ID=your_discord_guild_id
MINECRAFT_IP=your_minecraft_server_ip
./target/release/minebot