Last active
August 17, 2020 02:45
-
-
Save JohnMertz/c6bb4a9298dd3dc53b8030ff50466226 to your computer and use it in GitHub Desktop.
Minecraft SystemD Unit File
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
[Unit] | |
Description=Minecraft | |
After=network.target | |
[Service] | |
Type=simple | |
User=minecraft | |
Group=minecraft | |
WorkingDirectory=/var/lib/minecraft/current | |
ExecStart=java -jar -Xmx2G -Xms1G server.jar --nogui | |
Restart=always | |
Environment=USER=minecraft HOME=/var/lib/minecraft/current | |
[Install] | |
WantedBy=multi-user.target |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment