From 615d12bce3166864c33e837c16549dff883e07cd Mon Sep 17 00:00:00 2001 From: Geoff Bourne Date: Sun, 9 Apr 2017 08:30:20 -0500 Subject: [PATCH] [mc] Upgrade to rcon-cli 1.3 --- minecraft-server/Dockerfile | 2 +- minecraft-server/README.md | 9 ++++++--- 2 files changed, 7 insertions(+), 4 deletions(-) diff --git a/minecraft-server/Dockerfile b/minecraft-server/Dockerfile index 5afa2b36..c9ffa118 100644 --- a/minecraft-server/Dockerfile +++ b/minecraft-server/Dockerfile @@ -28,7 +28,7 @@ RUN addgroup -g 1000 minecraft \ EXPOSE 25565 25575 ADD https://github.com/itzg/restify/releases/download/1.0.4/restify_linux_amd64 /usr/local/bin/restify -ADD https://github.com/itzg/rcon-cli/releases/download/1.2/rcon-cli_linux_amd64 /usr/local/bin/rcon-cli +ADD https://github.com/itzg/rcon-cli/releases/download/1.3/rcon-cli_linux_amd64 /usr/local/bin/rcon-cli COPY start.sh /start COPY start-minecraft.sh /start-minecraft COPY mcadmin.jq /usr/share diff --git a/minecraft-server/README.md b/minecraft-server/README.md index b261c0dd..577f0787 100644 --- a/minecraft-server/README.md +++ b/minecraft-server/README.md @@ -42,13 +42,16 @@ access the Minecraft server console: docker exec -i mc rcon-cli ``` -or +Note: The `-i` is required for interactive use of rcon-cli. + +To run a simple, one-shot command, such as stopping a Minecraft server, pass the command as +arguments to `rcon-cli`, such as: ``` -echo stop | docker exec -it mc rcon-cli +docker exec mc rcon-cli stop ``` -Note: The `-i` is needed to attach to the standard *input* of the rcon-cli. +_The `-i` is not needed in this case._ In order to attach and interact with the Minecraft server, add `-it` when starting the container, such as