https://github.com/officialrealtm/mcserver_installer
A powerful bash script for easy installation of a Minecraft server (Vanilla, Forge, Spigot & Paper)
https://github.com/officialrealtm/mcserver_installer
bash-script debian java minecraft minecraft-forge minecraft-paper minecraft-papermc-server minecraft-server papermc papermc-minecraft-server papermc-server python shell shell-script spigot spigot-server spigotmc ubuntu
Last synced: 4 months ago
JSON representation
A powerful bash script for easy installation of a Minecraft server (Vanilla, Forge, Spigot & Paper)
- Host: GitHub
- URL: https://github.com/officialrealtm/mcserver_installer
- Owner: officialrealTM
- License: other
- Created: 2022-06-08T02:38:05.000Z (over 3 years ago)
- Default Branch: main
- Last Pushed: 2024-12-05T21:27:10.000Z (about 1 year ago)
- Last Synced: 2025-01-31T17:39:32.462Z (about 1 year ago)
- Topics: bash-script, debian, java, minecraft, minecraft-forge, minecraft-paper, minecraft-papermc-server, minecraft-server, papermc, papermc-minecraft-server, papermc-server, python, shell, shell-script, spigot, spigot-server, spigotmc, ubuntu
- Language: Shell
- Homepage: https://github.com/officialrealTM/mcserver_installer
- Size: 150 KB
- Stars: 37
- Watchers: 3
- Forks: 10
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# Minecraft Server Installer Script (Vanilla, Forge, Spigot, Paper & Leaf) 1.7.X - 1.21+
## About the project
With this project, my goal was to make installing Minecraft servers, no matter if they are Vanilla, Forge, Spigot, Paper and Leaf, as easy and beginner-friendly as possible.
After making some Tutorials on my [YouTube Channel](https://youtube.com/realtm_csgo) and providing a detailed Documentation for them, there were still questions and problems on how to install a Minecraft Server on a Linux-Server.
Thats why I created this All-in-One solution for installing a Minecraft Server (Forge, Vanilla, Spigot, Paper & Leaf).
## Support the Project
This project was started with a simple goal: to make installing and managing a Minecraft server as easy and beginner-friendly as possible. Your contribution directly supports the project's future by helping to cover:
* **Continuous Development:** Keeping the installer compatible with the latest versions of Minecraft, Java, and all supported server platforms.
* **Infrastructure Costs:** Paying for the servers needed for testing, version checks, API and other backend features.
If you find this tool useful, please consider showing your support. Every little bit helps and is greatly appreciated!
[❤️ Sponsor on GitHub](https://github.com/sponsors/officialrealTM)
[☕ Buy Me A Coffee](https://www.buymeacoffee.com/realtm)
## Supported Distros
- Debian 10
- Debian 11
- Debian 12
- Ubuntu 18.04
- Ubuntu 20.04
- Ubuntu 22.04
- Ubuntu 24.04
## Requirements
- SSH-Connection to your server
- Root Access to server (Script need to be executed as root)
- Linux-based operating systems (only on [Supported Distros](https://github.com/officialrealTM/mcserver_installer#supported-distros))
- Git needs to be installed on the server --> [Installation](https://github.com/officialrealTM/mcserver_installer#installation)
# Features
### General Features:
- Graphical User Interface (GUI)
- Easy-to-Use (even for beginners!)
- Automatic installation of required programs/packages
- Automatic installation of Java Versions for different Minecraft Versions (Including Java 8, Java 16, Java 17 and Java 21)
- Creating Minecraft Server start-scripts (including a check if the correct Java Version is selcted)
- Adjustable RAM-Allocation when installing a Minecraft Server
- Installed Servers are stored in Sub-Folders, to install more than one instance
- Support for multiple Linux Distributions (Ubuntu & Debian)
### Minecraft Vanilla Features:
- Supported Minecraft Vanilla Versions: Minecraft 1.7.X - 1.21.X
### Minecraft Forge Features:
- Supported Minecraft Forge Versions: Minecraft 1.7.10 - 1.21.X
- Installing a specific Forge Version. (A Version Overview can be found [here](https://files.minecraftforge.net/net/minecraftforge/forge/))
### Minecraft Spigot Features:
- Supported Minecraft Spigot Versions: 1.8.X - 1.21.X
- Using Spigot's offical [BuildTools](https://www.spigotmc.org/wiki/buildtools/) to compile the spigot.jar(s)
- Caching of already compiled spigot.jar(s) to avoid unneccessary re-compilation of already compiled spigot.jar(s)
### Minecraft Paper Features:
- Supported Minecraft Paper Versions: 1.8.X - 1.21.X
- Possibility to install every existing build of Paper
- Show list of available builds for each version to select from
- Using Paper's official [API](https://api.papermc.io/docs/swagger-ui/index.html?configUrl=/openapi/swagger-config) to obtain available builds
- Adjusted Sub-Folder Naming (including the build-number)
### Minecraft Leaf Features:
- Supported Minecraft Leaf Versions: 1.19.2 - 1.21.X
- Possibility to install every existing build of Leaf
- Show list of available builds for each version to select from
- Automatic distinction between direct download versions and versions with build selection.
- Using Leaf's official [API](https://api.leafmc.one/docs/swagger-ui/index.html) for versions that support build selection.
- Adjusted Sub-Folder Naming (including the build-Number)
- Important: The Leaf developers recommend using version 1.21.4 or newer. Older versions are not recommended for production use.
## Installation
Prerequisites:
```bash
apt install git
```
Downloading the script:
```bash
git clone https://github.com/officialrealTM/mcserver_installer.git
```
## Run the Script
Go into the downloaded folder:
```bash
cd mcserver_installer
```
Start the Script:
```bash
./mcserver_installer.sh
```
## FAQ
#### **Can I use this Script on other Distros?**
No. At least not yet. The Script has been developed and tested on --> [Supported Distros](https://github.com/officialrealTM/mcserver_installer#supported-distros).
To disable the Distro check see: [Experimental Settings](https://github.com/officialrealTM/mcserver_installer#experimental-settings)
#### **Where are my Serverfiles located?**
You Minecraft Server files will get stored in `/Servers/Minecraft-`
When installing multiple servers of the same type (e.g. two Minecraft 1.8.9 Servers) the second folder will be called `Minecraft--1` (or 2 and so on)
#### **Can I run more than one server at once?**
Yes. But here you need to keep a few things in mind:
- Your Linux server need to be powerfull enough
- You need to adjust the Port of the second/third/etc. Minecraft server (because Port 25565 is already in use.) This can be adjusted in the `server.properties` file
#### **Can I change the amount of RAM allocated to my Minecraft Server after the installation?**
Yes. To do so go to your Server folder (`cd /Servers/Minecraft-`) and open the `start.sh`file.
In the last line of this file you can adjust the number after `-Xmx` to adjust more or less ram.
#### **Can I use this script to install Snapshot Versions of Minecraft?**
**No.** This script can only install full game versions. Snapshot Versions are not supported!
#### **I've accidentally closed my Minecraft console. How can I open it again?**
Dont worry, the console will kept open in the background using *screen*.
Use this command, to show all active screen sessions:`screen -ls`
If only one Sessions is active you can use this command, to open it: `screen -rx`
If multiple Sessions are active use this command: `screen -rx `
#### **How to close (detach) my console?**
To close (detach) you Minecraft Console press **[CTRL]**+**[A]** and than **[CTRL]**+**[D]**
#### **More questions?**
Feel free to ask me questions on my [Discord](https://realtm.link/discord).
## Contributing
You are very welcome to contribute to this project!
To do so, just create a Pull Request and describe your additions as accurate as possible!
Feel free to join my [Discord](https://realtm.link/discord) to ask questions about the code's structure etc.
## Roadmap
- Commenting & cleaning the sourcecode
## Tech Stack
These are all the packages used in this script:
**Used Packages:** dialog, sudo, wget, screen, jq, Python3, Python3-pip, Pip3-Packaging
**Python Script:** mcurlgrabber.py (Thanks to [Christian](https://github.com/christian-thiele)!)
## Experimental Settings
**Important:** With these experimental settings you can **disable** certain functions of the script.
Use them at your own risk and **only** if you know what you are doing!
**How to use:**
All these commands must be executed in the homedirectory of the script, namely: `/mcserver_installer`
Disable Distro-check:
```bash
touch .skip_distro_check
```
Disable Script Version check:
```bash
touch .skip_version_check
```
Disable Installed-check:
```bash
touch .installed
```
Disable caching/archiving of compiled Spigot.jar(s):
```bash
touch .disable_spigot_archive
```
### Undo experimental settings
Enable Distro-check:
```bash
rm .skip_distro_check
```
Enable Script Version check:
```bash
rm .skip_version_check
```
Enable Installed-check (can also be used to re-check installed packages):
```bash
rm .installed
```
Enable caching/archiving of compiled Spigot.jar(s):
```bash
rm .disable_spigot_archive
```
## Support
For support, join my [Discord](https://realtm.link/discord) and create a Ticket.
(*Support in German and English*)
## License
Shield: [![CC BY-NC-SA 4.0][cc-by-nc-sa-shield]][cc-by-nc-sa]
This work is licensed under a [Creative Commons Attribution-NonCommercial-ShareAlike 4.0 International License][cc-by-nc-sa].
[![CC BY-NC-SA 4.0][cc-by-nc-sa-image]][cc-by-nc-sa]
[cc-by-nc-sa]: http://creativecommons.org/licenses/by-nc-sa/4.0/
[cc-by-nc-sa-image]: https://licensebuttons.net/l/by-nc-sa/4.0/88x31.png
[cc-by-nc-sa-shield]: https://img.shields.io/badge/License-CC%20BY--NC--SA%204.0-lightgrey.svg
# Minecraft Server Installer Script (Vanilla, Forge, Spigot, Paper & Leaf) 1.7.X - 1.21+
## About the project
With this project, my goal was to make installing Minecraft servers, no matter if they are Vanilla, Forge, Spigot, Paper and Leaf, as easy and beginner-friendly as possible.
After making some Tutorials on my [YouTube Channel](https://youtube.com/realtm_csgo) and providing a detailed [Documentation](https://docs.realtm.de) for them, there were still questions and problems on how to install a Minecraft Server on a Linux-Server.
Thats why I created this All-in-One solution for installing a Minecraft Server (Forge, Vanilla, Spigot & Paper).
## Supported Distros
- Debian 10
- Debian 11
- Debian 12
- Ubuntu 18.04
- Ubuntu 20.04
- Ubuntu 22.04
- Ubuntu 24.04
## Requirements
- SSH-Connection to your server
- Root Access to server (Script need to be executed as root)
- Linux-based operating systems (only on [Supported Distros](https://github.com/officialrealTM/mcserver_installer#supported-distros))
- Git needs to be installed on the server --> [Installation](https://github.com/officialrealTM/mcserver_installer#installation)
# Features
### General Features:
- Graphical User Interface (GUI)
- Easy-to-Use (even for beginners!)
- Automatic installation of required programs/packages
- Automatic installation of Java Versions for different Minecraft Versions (Including Java 8, Java 16, Java 17 and Java 21)
- Creating Minecraft Server start-scripts (including a check if the correct Java Version is selcted)
- Adjustable RAM-Allocation when installing a Minecraft Server
- Installed Servers are stored in Sub-Folders, to install more than one instance
- Support for multiple Linux Distributions (Ubuntu & Debian)
### Minecraft Vanilla Features:
- Supported Minecraft Vanilla Versions: Minecraft 1.7.X - 1.21.X
### Minecraft Forge Features:
- Supported Minecraft Forge Versions: Minecraft 1.7.10 - 1.21.X
- Installing a specific Forge Version. (A Version Overview can be found [here](https://files.minecraftforge.net/net/minecraftforge/forge/))
### Minecraft Spigot Features:
- Supported Minecraft Spigot Versions: 1.8.X - 1.21.X
- Using Spigot's offical [BuildTools](https://www.spigotmc.org/wiki/buildtools/) to compile the spigot.jar(s)
- Caching of already compiled spigot.jar(s) to avoid unneccessary re-compilation of already compiled spigot.jar(s)
### Minecraft Paper Features:
- Supported Minecraft Paper Versions: 1.8.X - 1.21.X
- Possibility to install every existing build of Paper
- Show list of available builds for each version to select from
- Using Paper's official [API](https://api.papermc.io/docs/swagger-ui/index.html?configUrl=/openapi/swagger-config) to obtain available builds
- Adjusted Sub-Folder Naming (including the build-number)
### Minecraft Leaf Features:
- Supported Minecraft Leaf Versions: 1.19.2 - 1.21.X
- Possibility to install every existing build of Leaf
- Show list of available builds for each version to select from
- Automatic distinction between direct download versions and versions with build selection.
- Using Leaf's official [API](https://api.leafmc.one/docs/swagger-ui/index.html) for versions that support build selection.
- Adjusted Sub-Folder Naming (including the build-Number)
- Important: The Leaf developers recommend using version 1.21.4 or newer. Older versions are not recommended for production use.
## Installation
Prerequisites:
```bash
apt install git
```
Downloading the script:
```bash
git clone https://github.com/officialrealTM/mcserver_installer.git
```
## Run the Script
Go into the downloaded folder:
```bash
cd mcserver_installer
```
Start the Script:
```bash
./mcserver_installer.sh
```
## FAQ
#### **Can I use this Script on other Distros?**
No. At least not yet. The Script has been developed and tested on --> [Supported Distros](https://github.com/officialrealTM/mcserver_installer#supported-distros).
To disable the Distro check see: [Experimental Settings](https://github.com/officialrealTM/mcserver_installer#experimental-settings)
#### **Where are my Serverfiles located?**
You Minecraft Server files will get stored in `/Servers/Minecraft-`
When installing multiple servers of the same type (e.g. two Minecraft 1.8.9 Servers) the second folder will be called `Minecraft--1` (or 2 and so on)
#### **Can I run more than one server at once?**
Yes. But here you need to keep a few things in mind:
- Your Linux server need to be powerfull enough
- You need to adjust the Port of the second/third/etc. Minecraft server (because Port 25565 is already in use.) This can be adjusted in the `server.properties` file
#### **Can I change the amount of RAM allocated to my Minecraft Server after the installation?**
Yes. To do so go to your Server folder (`cd /Servers/Minecraft-`) and open the `start.sh`file.
In the last line of this file you can adjust the number after `-Xmx` to adjust more or less ram.
#### **Can I use this script to install Snapshot Versions of Minecraft?**
**No.** This script can only install full game versions. Snapshot Versions are not supported!
#### **I've accidentally closed my Minecraft console. How can I open it again?**
Dont worry, the console will kept open in the background using *screen*.
Use this command, to show all active screen sessions:`screen -ls`
If only one Sessions is active you can use this command, to open it: `screen -rx`
If multiple Sessions are active use this command: `screen -rx `
#### **How to close (detach) my console?**
To close (detach) you Minecraft Console press **[CTRL]**+**[A]** and than **[CTRL]**+**[D]**
#### **More questions?**
Feel free to ask me questions on my [Discord](https://realtm.link/discord).
## Contributing
You are very welcome to contribute to this project!
To do so, just create a Pull Request and describe your additions as accurate as possible!
Feel free to join my [Discord](https://realtm.link/discord) to ask questions about the code's structure etc.
## Roadmap
- Commenting & cleaning the sourcecode
## Tech Stack
These are all the packages used in this script:
**Used Packages:** dialog, sudo, wget, screen, jq, Python3, Python3-pip, Pip3-Packaging
**Python Script:** mcurlgrabber.py (Thanks to [Christian](https://github.com/christian-thiele)!)
## Experimental Settings
**Important:** With these experimental settings you can **disable** certain functions of the script.
Use them at your own risk and **only** if you know what you are doing!
**How to use:**
All these commands must be executed in the homedirectory of the script, namely: `/mcserver_installer`
Disable Distro-check:
```bash
touch .skip_distro_check
```
Disable Script Version check:
```bash
touch .skip_version_check
```
Disable Installed-check:
```bash
touch .installed
```
Disable caching/archiving of compiled Spigot.jar(s):
```bash
touch .disable_spigot_archive
```
### Undo experimental settings
Enable Distro-check:
```bash
rm .skip_distro_check
```
Enable Script Version check:
```bash
rm .skip_version_check
```
Enable Installed-check (can also be used to re-check installed packages):
```bash
rm .installed
```
Enable caching/archiving of compiled Spigot.jar(s):
```bash
rm .disable_spigot_archive
```
## Support
For support, join my [Discord](https://realtm.link/discord) and create a Ticket.
(*Support in German and English*)
## License
Shield: [![CC BY-NC-SA 4.0][cc-by-nc-sa-shield]][cc-by-nc-sa]
This work is licensed under a [Creative Commons Attribution-NonCommercial-ShareAlike 4.0 International License][cc-by-nc-sa].
[![CC BY-NC-SA 4.0][cc-by-nc-sa-image]][cc-by-nc-sa]
[cc-by-nc-sa]: http://creativecommons.org/licenses/by-nc-sa/4.0/
[cc-by-nc-sa-image]: https://licensebuttons.net/l/by-nc-sa/4.0/88x31.png
[cc-by-nc-sa-shield]: https://img.shields.io/badge/License-CC%20BY--NC--SA%204.0-lightgrey.svg