/papermc-docker-distroless

This is a docker container running the Paper Minecraft Server and based off Google's distroless Java container, making it lighter and more secure.

Primary LanguageDockerfileMIT LicenseMIT

PaperMC Minecraft Server distroless docker container

Gitlab pipeline status Docker Automated build Docker Image Size (latest by date) Docker Pulls Docker Stars GitHub stars

This is a docker container running the Paper Minecraft Server and based off Google's distroless Java container, making it lighter and more secure.

PaperMC runs with aikar's optimized flags in order to try and improve the performance.

How to run

Launch the container, this will create the PaperMC directory in your current directory

optional: set -Xms2G -Xmx2G to the Amount of RAM to allocate to PaperMC

docker run

$ docker run \
    -v $(pwd)/papermc:/papermc \
    -e JAVA_TOOL_OPTIONS="-Xms2G -Xmx2G" \
    -p 25565:25565 \
    guillaumedsde/papermc-docker-distroless:latest

docker-compose

version: '3.3'
services:
    papermc:
        volumes:
            - '<data_dir>/papermc:/papermc'
        environment:
            - 'JAVA_TOOL_OPTIONS=-Xms2G -Xmx2G'
        ports:
            - '25565:25565'
        image: guillaumedsde/papermc-docker-distroless:latest

TODO

  • Run as non-root user (Docker volumes do not support this yet)