"> Dockerfile:

"> Dockerfile:

" />

Auf diesen Seiten findest Du die Projekte und Blogposts von Carsten Ringe.

Running Minecraft in a Docker container

02 October 2014

If you ever want to run a minecraft server, but you don’t want to add all the Java and minecraft files directly to your servers filesystem, you can use the following Dockerfile:

FROM google/debian:wheezy
RUN apt-get -y update
RUN apt-get -y install openjdk-7-jre-headless wget
RUN wget
EXPOSE 25565
RUN echo eula=true > eula.txt
CMD ["java", "-jar", "minecraft_server.1.8.jar"]

You can then build a Docker container with the following command:

sudo docker build .

After that, you have a Minecraft 1.8 server running and you can connect to with your Minecraft client. Enjoy!