Skip to content

A collection of scripts written in Bash that manage PaperMC servers.

License

Notifications You must be signed in to change notification settings

InvisaMage/papertray

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

28 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation


Logo

Papertray

A collection of scripts written in Bash that manage PaperMC servers.


Stargazers Issues MIT License

Table of Contents

About The Project

Product Name Screenshot

Papertray is a collection of scripts that allows you to easily manage a PaperMC Minecraft server.

I found myself manually navigating to the PaperMC website to check for and download new builds. Any repetitive task should be automated so I made Papertray and some other utility scripts.

Papertray can Backup, Trim, Update, and Start your PaperMC server.

This was made public in the hopes it's useful to others. Feel free to use this as a template and modify to suit your needs.

Features

  • Install and update PaperMC
  • Install and update Geyser
  • Backup the entire server directory to a specified location
  • Delete old backups (trim)
  • Start the server in a loop (for crash recovery)

Getting Started

These steps assume you are running a Debian/Ubuntu based distribution of Linux, however, these steps should be similar for all Linux distributions. To get a local copy up and running follow these simple steps.

Prerequisites

Papertray does not have many dependencies. Java packages are different for many distributions, you may need to lookup the package name for flavor of Linux.

  • jq
  • Java
  • curl
sudo apt install jq openjdk-16-jre curl

Installation

  1. Clone the repo
git clone https://github.com/InvisaMage/papertray.git
  1. Edit the papertray.conf file to suit your needs
  2. Make all the scripts executable
chmod +x *.sh

Usage

Simply run the main script and Papertray will take care of the rest.

./papertray.sh

Please note, on the first run, you will need to accept the Minecraft EULA manually.

The other scripts may be run as well, however, they are not well maintained. Use them at your own risk.

Recommended Usage

Papertray works best if it's ran using Crontab and screen

Here's an example of a crontab file:

@reboot cd /home/mc/server && /usr/bin/screen -d -m -h 500 ./papertray.sh

This will run Papertray every time the computer reboots and runs it under the screen terminal multiplexer.

Roadmap

See the open issues for a list of proposed features (and known issues).

Contributing

Contributions are what make the open source community such an amazing place to be learn, inspire, and create. Any contributions you make are greatly appreciated.

  1. Fork the Project
  2. Create your Feature Branch (git checkout -b feature/AmazingFeature)
  3. Commit your Changes (git commit -m 'Add some AmazingFeature')
  4. Push to the Branch (git push origin feature/AmazingFeature)
  5. Open a Pull Request

License

Distributed under the MIT License. See LICENSE for more information.

Contact

Travis - support@invisamage.com

Project Link: https://github.com/InvisaMage/papertray

Acknowledgements