u/tnacomtr

I wrote a secure Python Script that Deploys Minecraft Servers in under a Minute!

Hey everyone! I've been deploying servers for 6 years and got fed up with how long it takes to properly configure a secure VPS when migrating hosts. I looked for an easy Minecraft server deployer on GitHub but the script I found wasn't quite secure as it ran the server as "root". Besides I wanted my script to also set up necessary packages and automatically configure firewall rules and such.

I built deploymcserver to provide a script for people like me. It’s a single Python script that goes from a fresh Linux install to a running, public-facing server in under a minute. Plus It's extremely noob-friendly so it has no complexity to run whatsoever.

What it actually does:

  • Creates an isolated, unprivileged minecraft system user.
  • Dynamically fetches the latest Vanilla, Paper, Leaf, or Forge versions via their official APIs (no hardcoded versions, all are dynamically fetched).
  • Generates proper systemd unit files (starts on boot, restarts on crash).
  • Configures ufw or firewalld automatically. (adds tcp 25565 and tcp 22 to allowlist)
  • Schedules daily backups.
  • sets up mcrcon and saves the auto-generated password as a file so you don't lose it.

I also provided an uninstaller script that lets you select and remove each individual packet the installer script installed on your computer and basically undoes everything else (the script doesn't close port 22 on the firewall). ,

I made the code very modular so adding a new Distro or Server JAR support is as easy as creating a new Class, so if you want to contribute, it should be very easy!

Feel free to check out my project here.

reddit.com
u/tnacomtr — 7 days ago