author | Luke Hoersten <luke@hoersten.org> |
Sat, 10 Jul 2021 13:28:05 -0500 | |
changeset 161 | edc41ae39fb8 |
parent 156 | ebd8a21a0e62 |
permissions | -rw-r--r-- |
19 | 1 |
[Unit] |
111
1c1a911b26aa
Made minecraft role support vanilla and paper forks.
Luke Hoersten <luke@hoersten.org>
parents:
108
diff
changeset
|
2 |
Description=Minecraft Server |
1c1a911b26aa
Made minecraft role support vanilla and paper forks.
Luke Hoersten <luke@hoersten.org>
parents:
108
diff
changeset
|
3 |
Documentation=https://minecraft.gamepedia.com/Tutorials/Setting_up_a_server |
19 | 4 |
|
5 |
Wants=network.target |
|
6 |
After=network.target |
|
7 |
||
8 |
[Service] |
|
111
1c1a911b26aa
Made minecraft role support vanilla and paper forks.
Luke Hoersten <luke@hoersten.org>
parents:
108
diff
changeset
|
9 |
User={{minecraft_user}} |
1c1a911b26aa
Made minecraft role support vanilla and paper forks.
Luke Hoersten <luke@hoersten.org>
parents:
108
diff
changeset
|
10 |
Group={{minecraft_user}} |
1c1a911b26aa
Made minecraft role support vanilla and paper forks.
Luke Hoersten <luke@hoersten.org>
parents:
108
diff
changeset
|
11 |
WorkingDirectory={{minecraft_dir}} |
19 | 12 |
Restart=on-failure |
13 |
RestartSec=20 5 |
|
111
1c1a911b26aa
Made minecraft role support vanilla and paper forks.
Luke Hoersten <luke@hoersten.org>
parents:
108
diff
changeset
|
14 |
ExecStart=/usr/bin/java -Xms{{minecraft_mem}} -Xmx{{minecraft_mem}} -XX:+UseG1GC -XX:+ParallelRefProcEnabled -XX:MaxGCPauseMillis=200 -XX:+UnlockExperimentalVMOptions -XX:+DisableExplicitGC -XX:+AlwaysPreTouch -XX:G1NewSizePercent=30 -XX:G1MaxNewSizePercent=40 -XX:G1HeapRegionSize=8M -XX:G1ReservePercent=20 -XX:G1HeapWastePercent=5 -XX:G1MixedGCCountTarget=4 -XX:InitiatingHeapOccupancyPercent=15 -XX:G1MixedGCLiveThresholdPercent=90 -XX:G1RSetUpdatingPauseTimePercent=5 -XX:SurvivorRatio=32 -XX:+PerfDisableSharedMem -XX:MaxTenuringThreshold=1 -Dusing.aikars.flags=https://mcflags.emc.gs -Daikars.new.flags=true -jar server.jar nogui |
19 | 15 |
|
16 |
PrivateTmp=true |
|
17 |
ProtectSystem=full |
|
18 |
NoNewPrivileges=true |
|
19 |
PrivateDevices=true |
|
20 |
||
21 |
[Install] |
|
22 |
WantedBy=multi-user.target |