在线时间:8:00-16:00
迪恩网络APP
随时随地掌握行业动态
扫描二维码
关注迪恩网络微信公众号
开源软件名称(OpenSource Name):mtoensing/Docker-Minecraft-PaperMC-Server开源软件地址(OpenSource Url):https://github.com/mtoensing/Docker-Minecraft-PaperMC-Server开源编程语言(OpenSource Language):Dockerfile 48.8%开源软件介绍(OpenSource Introduction):Docker Minecraft JAVA PaperMC Server 1.19Docker Minecraft PaperMC server for 1.19, 1.18, 1.17 for AMD64 and ARM64 platforms. Works on Synology, Raspberry Pi 4 or any other systems that support docker. Quick Startdocker run --rm --name mcserver -e MEMORYSIZE='1G' -v /home/joe/mcserver:/data:rw -p 25565:25565 -i marctv/minecraft-papermc-server:latest The server will generate all data including the world and config files in How-to install on a Raspberry Pi 4
ssh pi@raspberrypi
sudo apt update && sudo apt upgrade
curl -fsSL https://get.docker.com -o get-docker.sh
chmod +x get-docker.sh
./get-docker.sh
apt-get install -y uidmap
dockerd-rootless-setuptool.sh install
sudo usermod -aG docker $USER
newgrp docker
cd
mkdir mcserver
docker run -d --rm --name mcserver -e MEMORYSIZE='1G' -e PAPERMC_FLAGS='' -v /home/pi/mcserver:/data:rw -p 25565:25565 -it marctv/minecraft-papermc-server:latest The server will generate all data including the world and config files in
docker attach mcserver Here, you can use Minecraft server commands like How do I update the container?On Synology DSM
On Terminaldocker pull marctv/minecraft-papermc-server:latest
sudo docker stop mcserver Run as non-root userYou can get the desired UID/GID (xxx) with the ID command (id username) then add the following to your docker run command: -e PUID=xxx
-e PGID=xxx Docker ComposeIf you prefer to use Start the server: docker-compose up Stop the server: docker-compose stop Issue server commands after attaching to the container: docker attach mcserver
# then you can type things like "list"
list
# which will show the current players online or
help
# to see all the commands available How to use the Makefile with Docker ComposeAdditionally, a make start # equivalent to `docker-compose up -d --build`
make stop # equivalent to `docker-compose stop --rmi all --remove-orphans`
make attach # equivalent to `docker attach mcserver`
make help # prints a help message Environment variablesMEMORYSIZE = 1G Not more than 70% of your RAM for your container. This is important. Because this is the RAM, your Minecraft Server will use within the container WITHOUT the operating system. TZ = Europe/Berlin Sets the timezone for the container. A list of valid values can be found on Wikipedia: https://en.wikipedia.org/wiki/List_of_tz_database_time_zones PAPERMC_FLAGS = --nojline Sets the command-line flags for PaperMC. Remove TutorialTutorial (german) https://marc.tv/anleitung-stabiler-minecraft-server-synology-nas/ CreditsOn GitHub https://github.com/mtoensing/Docker-Minecraft-PaperMC-Server This server is live here: https://mc.marc.tv Based on the work of Felix Klauke Thanks for your help! |
2023-10-27
2022-08-15
2022-08-17
2022-09-23
2022-08-13
请发表评论