Added rcon
This commit is contained in:
parent
4a91292607
commit
cbe856d0c0
4 changed files with 11 additions and 2 deletions
|
@ -36,6 +36,12 @@ WORKDIR /data
|
|||
# Obtain runable jar from build stage
|
||||
COPY --from=build /opt/minecraft/paperspigot.jar /opt/minecraft/paperspigot.jar
|
||||
|
||||
# Install and run rcon
|
||||
ARG RCON_CLI_VER=1.4.6
|
||||
ADD https://github.com/itzg/rcon-cli/releases/download/${RCON_CLI_VER}/rcon-cli_${RCON_CLI_VER}_linux_amd64.tar.gz /tmp/rcon-cli.tgz
|
||||
RUN tar -x -C /usr/local/bin -f /tmp/rcon-cli.tgz rcon-cli && \
|
||||
rm /tmp/rcon-cli.tgz
|
||||
|
||||
# Obtain server config
|
||||
ADD server.properties /opt/minecraft/server.properties
|
||||
|
||||
|
|
2
rcon-cli.sh
Executable file
2
rcon-cli.sh
Executable file
|
@ -0,0 +1,2 @@
|
|||
docker exec -i mcserver rcon-cli --host localhost --port 25575 --password glaspalast timings report
|
||||
|
|
@ -4,5 +4,6 @@ docker run \
|
|||
-e MEMORYSIZE='1G' \
|
||||
-v /Users/mtoe/Documents/mcserver:/data:rw \
|
||||
-p 25565:25565 \
|
||||
-p 25575:25575 \
|
||||
-i marctv/minecraft-papermc-server:latest
|
||||
docker attach mcserver
|
||||
|
|
|
@ -33,12 +33,12 @@ view-distance=10
|
|||
resource-pack=
|
||||
spawn-animals=true
|
||||
white-list=false
|
||||
rcon.password=mcserver
|
||||
rcon.password=minecraft
|
||||
generate-structures=true
|
||||
online-mode=true
|
||||
max-build-height=256
|
||||
level-seed=
|
||||
prevent-proxy-connections=false
|
||||
use-native-transport=true
|
||||
enable-rcon=false
|
||||
enable-rcon=true
|
||||
motd=A DOCKER Minecraft Server
|
||||
|
|
Loading…
Add table
Reference in a new issue