Skip to content

MattLimb/mc-server-setup

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

15 Commits
 
 
 
 
 
 
 
 

Repository files navigation

Minecraft Server Setup

This repo is an open set of scripts which setup Fabric Minecraft as systemd Service on Ubuntu 24.04 Server.

Caution

This is a personal project. Please do read, understand and modify these scripts as appliciable.

This is a fork of jtait's minecraft systemd repo - but I intend to maintain this as a seperate project.

Install

  1. Install Just and Git
$ sudo apt install -y just git
  1. Git Clone
$ git clone https://github.com/MattLimb/mc-server-setup.git

Useful Commands

In all these commands <name> will be used to refer to the name of a Minecraft Server. If you are running multiple severs, these names MUST be unique.

Command Description
just install Install Java, setup folder structre, setup minecraft user account and setup systemd.
just new DEFAULT way to make a new minecraft server. This creates a minecraft server named server.
just name=<name> new Create a custom named minecraft server.
just name=<name> remove Stop and remove the named Minecraft server.
just name=<name> enable Start the <name>ed minecraft server from starting at boot time.
systemctl enable minecraft@<name> Start the <name>ed minecraft server from starting at boot time.
just name=<name> disable Start the <name>ed minecraft server from starting at boot time.
systemctl disable minecraft@<name> Stop the <name>ed minecraft server from starting at boot time.
systemctl status minecraft@<name> Get the current status of the <name>ed minecraft server.
journalctl -efu minecraft@<name> Get the logs for the <name>ed minecraft server. This auto-tails the logs, so press CTRL+C to exit.
systemctl stop minecraft@<name> Stop the <name>ed minecraft server.
systemctl start minecraft@<name> Start the <name>ed minecraft server.
systemctl disable minecraft@<name> Stop the <name>ed minecraft server from starting at boot time.
systemctl enable minecraft@<name> Start the <name>ed minecraft server from starting at boot time.
systemctl enable --now minecraft@<name> Start the <name>ed minecraft server from starting at boot time, and start the service now.

About

Setup Minecraft Servers on Ubuntu 24.04 Using systemd

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • Just 100.0%