From ab78ff93ae41623055ca9d8b8d651c6bc7f72289 Mon Sep 17 00:00:00 2001 From: Evan Date: Sun, 18 Jan 2026 11:13:57 -0600 Subject: [PATCH] update docs & organization for release v0.1.0 --- .dockerignore | 5 +++++ CHANGELOG.md | 5 +++++ Dockerfile | 4 ++-- README.md | 10 +++++++--- mcrcon => scripts/mcrcon | 0 start-server.sh => scripts/start-server.sh | 0 6 files changed, 19 insertions(+), 5 deletions(-) create mode 100644 .dockerignore create mode 100644 CHANGELOG.md rename mcrcon => scripts/mcrcon (100%) rename start-server.sh => scripts/start-server.sh (100%) diff --git a/.dockerignore b/.dockerignore new file mode 100644 index 0000000..0ca7b63 --- /dev/null +++ b/.dockerignore @@ -0,0 +1,5 @@ +.git +.gitignore +README.md +*.log +minecraft_data/ diff --git a/CHANGELOG.md b/CHANGELOG.md new file mode 100644 index 0000000..58f82b4 --- /dev/null +++ b/CHANGELOG.md @@ -0,0 +1,5 @@ +## v0.1.0 +- Initial release +- Graceful shutdown via SIGTERM / SIGINT +- RCON-based control +- Automatic volume initialization diff --git a/Dockerfile b/Dockerfile index 8198f4f..97034dd 100644 --- a/Dockerfile +++ b/Dockerfile @@ -11,9 +11,9 @@ RUN unzip -j /usr/bin/mcrcon.zip -d /usr/bin/mc-rcon && chmod a+x /usr/bin/mc-rc FROM eclipse-temurin:21 COPY --from=builder /usr/bin/mc-rcon /usr/bin/mc-rcon -COPY start-server.sh /usr/bin/start-server.sh +COPY scripts/start-server.sh /usr/bin/start-server.sh RUN chmod a+x /usr/bin/start-server.sh -COPY mcrcon /usr/bin/mcrcon +COPY scripts/mcrcon /usr/bin/mcrcon RUN chmod a+x /usr/bin/mcrcon COPY template/ /defaults/ diff --git a/README.md b/README.md index dc47316..a450843 100644 --- a/README.md +++ b/README.md @@ -1,7 +1,8 @@ # Minecraft Docker Server A docker image and compose build for running and controlling a Minecraft server from inside a Docker container. * Supports any version of Minecraft; you just need a link to the server.jar - * tested on 1.21, more to come + * tested on vanilla 1.21, more to come + * note: mod loaders (like Fabric, Forge, and Paper) are not officially supported, but they may still work * Server console access via [RCON](https://minecraft.wiki/w/RCON) * uses [Tiiffi/mcrcon](https://github.com/Tiiffi/mcrcon) as a prepackaged RCON client * All server files stored in a Docker volume @@ -19,7 +20,7 @@ docker build -t minecraft_server . ``` ### Run with Docker Compose -`docker-compose.yml` (included in this repository): +In the same directory as `docker-compose.yml` (included in this repository): ```sh docker compose up -d ``` @@ -27,6 +28,9 @@ docker compose up -d ### First Startup On first startup (when the data volume is empty): +* Make sure to update the environment variables in the `docker-compose.yml` file + * `MCRCON_PASS` is the password to your server's RCON panel + * `SERVER_JAR_DOWNLOAD_URL` is a web URL of a `server.jar` file that the container will run to start your server * `server.properties` is created from a template * `eula.txt` is generated and automatically accepted * A default RCON configuration is written @@ -35,7 +39,7 @@ On first startup (when the data volume is empty): On subsequent startups, existing files are reused unchanged and environment variables are unused. ### RCON Access -Minecraft implements the Remote Console (RCON) protocol, which allows server administrators to remotely execute commands. See more info [here](https://minecraft.wiki/w/RCON) and [here](https://developer.valvesoftware.com/wiki/Source_RCON_Protocol). RCON access is enabled automatically from inside the container. **Do not expose the RCON service to the internet directly!!!** RCON is not encrypted, so exposing this service can give hackers direct access to your server's administrator console. +Minecraft implements the Remote Console (RCON) protocol, which allows server administrators to remotely execute commands. See more info [here](https://minecraft.wiki/w/RCON) and [here](https://developer.valvesoftware.com/wiki/Source_RCON_Protocol). RCON access is enabled automatically from inside the container only. **Do not expose the RCON service to the internet directly!!!** RCON is not encrypted, so exposing this service can give hackers direct access to your server's administrator console. Log into the container: ```sh diff --git a/mcrcon b/scripts/mcrcon similarity index 100% rename from mcrcon rename to scripts/mcrcon diff --git a/start-server.sh b/scripts/start-server.sh similarity index 100% rename from start-server.sh rename to scripts/start-server.sh