Workspace-Docker-ContainerMC / velocity_container

The modern, next-generation Minecraft server proxy in a docker container

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Docker container JDK with Velocity

About container:

This container is based on ubi9-minimal, and uses graalvm-ce 17 JDK. The container is built specifically for use as a minecraft proxy. This issues has been fixed in it. This allows you to fully use it as a server container without errors related to some plugins.

All builds take place automatically without human intervention. If the main repository is updated, the build process starts and you get the latest version.

About configuration:

In entrypoint.sh the start flags from Aikar's are specified. You can get them by following the link or on this website. entrypoint.sh it has one variable - MEMORYSIZE, which indicates how much will be allocated memory to the server (in this case, velocity) in -Xms and -Xmx. It is located here.

It is important! If you limit the container's memory using --memory in the docker command, or memory in docker-compose, keep in mind that you need to allocate memory with a margin. If you specified 1G in MEMORYSIZE, then you need to specify at least 2G for the docker container.If you specify less, the JVM uses all the RAM, and your process will be stopped by OOMKiller. Multiply your allocated memory number by 2-3. This will help to avoid problems with stopping the container.

If you need to change the JDK or flags, you need to create the container yourself. You can find out how to do this in the how to build section.

Download

How to download

Get docker image you can take here

Get the latest version сontainer:

docker pull workspacedockermc/el9-java17-velocity:latest

Use

How to use

You can run container with the docker command:

docker run --detach --name=proxy --interactive \
    --tty --restart=unless-stopped --env MEMORYSIZE=2G \
    --publish 25565:25565/tcp --cpus=2 --memory 5G \
    --volume /home/$USER/server/proxy:/proxy:rw,Z \
    docker.io/workspacedockermc/el9-java17-velocity:latest

Or use this docker-composes files:

docker-compose -f <NAME_DOCKER_COMPOSE_FILES> up -d

Build

How to build

Clone repo

git clone https://github.com/Workspace-Docker-ContainerMC/velocity_container

Go to directory

cd velocity_container

Get started build

docker build -t docker.io/$USER/ubi9-graalvm17-velocity:latest .

Contributer's & Credit's

I express my gratitude to these projects:

About

The modern, next-generation Minecraft server proxy in a docker container


Languages

Language:Dockerfile 71.4%Language:Shell 28.6%