Find a file
2022-07-16 02:16:14 +01:00
auth Store oauth session for redirect, invite un-authed 2022-07-06 00:17:41 +01:00
invite Remove - from token generation for invites 2022-07-15 17:38:53 +01:00
minecraft Tests for Minecraft, minor refactoring 2022-07-16 02:16:14 +01:00
mocks Tests for Minecraft, minor refactoring 2022-07-16 02:16:14 +01:00
store Switch to using user ID for invite log 2022-07-06 17:55:18 +01:00
transport Tests for Minecraft, minor refactoring 2022-07-16 02:16:14 +01:00
.build.yml Tests for Minecraft, minor refactoring 2022-07-16 02:16:14 +01:00
.gitignore Initial commit of MVP API 2022-07-05 11:10:18 +01:00
Dockerfile sr.ht build config 2022-07-06 20:54:49 +01:00
go.mod Starting to write unit tests! 2022-07-16 02:00:55 +01:00
go.sum Starting to write unit tests! 2022-07-16 02:00:55 +01:00
homepage.png Expand README 2022-07-15 17:20:48 +01:00
LICENSE Add LICENSE 2022-07-15 17:22:33 +01:00
main.go Tests for Minecraft, minor refactoring 2022-07-16 02:16:14 +01:00
README.md Expand README 2022-07-15 17:34:19 +01:00

Minecraft Server Invites mc.gmem.ca

Generate Discord-like invites for your Minecraft server

Homepage screenshot

Looking for the frontend? See here: https://git.sr.ht/~gmem/minecraft-server-invites-frontend

About

Sometimes you want to allow people to play on your Minecraft server, but you don't necessarily want to go through the whole process of asking for their username, then manually sending the command to add them to the whitelist*. Instead, this application offers the ability to generate a short link that directs a user through an OAuth flow to automatically fetch their Minecraft account (assuming the account has been migrated - I have no plans at this time to support non-migrated accounts, despite how I may personally feel about them) and send a command over RCON to your server to add them to the whitelist. It will then give them the address to connect to the server.

This is currently hosted at mc.gmem.ca while being developed. It's currently free, and while I do want to eventually monetize this hosted version, you are more than welcome to host your own instance (this is actually recommended if you have the ability, since it allows you to keep RCON private). I do happily accept donations though!

*while the term "whitelist" is by and large being replaced in places, this is still the term Minecraft servers utilise, and is therefore the term used in this application. Should it be changed, use of the term here will also be changed.

Building

# Docker
docker build . -t whitelistmanager
# Non-docker
go build -o wlm -ldflags "-s -w"

Running

This project aims to be as dependency free as possible. The SQLite database will be automatically created on first run.

You will need to generate the keys for the Microsoft OAuth flow by following this guide.

The keys can then be saved to environment variables as follows:

AZURE_OAUTH_CLIENT_ID=<client id>
AZURE_OAUTH_CLIENT_SECRET=<client secret>
AZURE_OAUTH_CLIENT_SECRET_ID=<client secret id> # technically unused at the moment
# Docker
docker run whitelistmanager
# Non-docker
go run ./...