binhex / arch-minecraftserver

Docker build script for Arch Linux base with Minecraft Java server
GNU General Public License v3.0
18 stars 27 forks source link

Allow garbage collection selection, additional startup args #5

Open weableandbob opened 3 years ago

weableandbob commented 3 years ago

I'm currently trying to get a Minecraft server copied over from my Windows desktop to my Unraid NAS that's running a FeedTheBeast modpack. However, the current Docker config does not allow me to set the necessary startup args that are necessary (or at least recommended).

Specifically, the command line I'm currently using is:

java.exe -server -XX:+UseG1GC -XX:+UnlockExperimentalVMOptions -Xmx6144M -Xms4096M -jar forge-1.12.2-14.23.5.2846-universal.jar nogui

-server, -Xmx, -Xms, -jar, and nogui are all already either configurable or not necessary. However, UseG1GC and UnlockExperimentalVMOptions are not. Additionally, I believe UseG1GC conflicts with the -XX:ParallelGCThreads that is currently getting passed in.

Would it be possible to add the option to set these properly? Or alternatively, adding the option for a CUSTOM_STARTUP_COMMAND variable or similar that, if set, overrides the current startup command?