Runs a Minecraft Server inside a Docker container.
Go to file
2024-07-10 12:50:35 +02:00
.dockerignore Initial commit 2024-01-25 23:12:09 +01:00
.gitignore Add jvm to .gitignore 2024-07-10 12:50:35 +02:00
config.example.env Add custom JVM support 2024-07-10 12:35:59 +02:00
docker-compose.yml Add Arch Linux dockerfile 2024-07-10 12:49:58 +02:00
Dockerfile Add Java 21 support + fix Java 8 2024-07-10 12:35:48 +02:00
Dockerfile.arch Add Arch Linux dockerfile 2024-07-10 12:49:58 +02:00
entrypoint.sh Add binary check 2024-07-10 12:41:53 +02:00
LICENSE Update LICENSE and more 2024-01-27 17:13:25 +01:00
Makefile Rename example conf, change Makefile & entrypoint 2024-01-27 16:32:41 +01:00
rcon.sh Mark rcon.sh as executable 2024-04-20 17:17:29 +02:00
README.md Add RCON support 2024-04-20 16:53:15 +02:00

MCServerDocker

Runs a Minecraft Server inside a Docker container.

Java Edition only

This only supports the true version of Minecraft, not that phone and console spinoff named "Bedrock Edition".

Setting up

Step 1: Installing

This will bootstrap MCSD.

git clone "https://git.staropensource.de/JeremyStarTM/mcserverdocker.git"
cd mcserverdocker
mkdir server
cp config.example.env config.env

Step 2: Installing the server software

Rename the jar file of your preferred server software to server.jar and move it into the server/ directory.

Step 3: Modify the configuration

Take a look at the environment variables inside the config.env file.

Step 4: Launching the server

You need to start your server two times as we need to generate the server.properties file first. MCSD will do this automatically for you.

# Use this to launch your server every time you need it
docker compose up -d

Using RCON

To access your server console you must use RCON. To use it, set enable-rcon to true and rcon.password to mcsdrcon in your server.properties file.
After doing that one-time setup, you simply need to execute ./rcon.sh and you'll connect to your server's console.

Security

You might be worried that the RCON port 25575 is accessible to the public. One quick look into the docker-compose.yml file however will tell you that it's not possible to access the RCON port unless the attacker has direct access to the machine.