Skip to content

Latest commit

 

History

13 Commits

Folders and files

NameName
Last commit message
Last commit date
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Plesk Minecraft Manager

Run Minecraft servers from inside Plesk, with the features people expect from Aternos and Exaroton: a live console, one-click plugin and mod installs, world management, scheduled backups, player and ban management, sleep-and-wake-on-join, and a token-authenticated REST API.

Tested against Plesk Obsidian 18.0.77 on Ubuntu 24.04, driving a live Paper 26.2 server.

The server console inside Plesk

What it does

Server software — Vanilla, Paper, Purpur, Folia, Fabric, Quilt, Forge, NeoForge, Spigot and CraftBukkit (built on the host with BuildTools), plus the Velocity and Waterfall proxies. Versions and builds come from each project's own API at the moment you open the dialog, so the list is never stale. Forge, NeoForge, Quilt and Spigot ship installers rather than runnable jars; those are executed for you and the result is detected automatically.

Java — nothing to install. The right Temurin JRE is downloaded on demand into the data directory and picked per server from the Minecraft version (26.x needs Java 25, 1.20.5+ needs 21, 1.18+ needs 17, 1.17 needs 16, older needs 8).

Console — real stdout, streamed to the browser, with command input wired to the process's stdin. ANSI colour codes and JLine prompt artefacts are stripped so the log stays readable. RCON is configured and managed for you and is used for the player list and for flushing the world before a backup.

Sleep and wake on join — the Aternos trick. mcpd owns the public port while the server itself binds loopback. A sleeping server still answers the multiplayer list with its own MOTD and player cap; a join attempt starts it and tells the player to reconnect. Once it is up the proxy is a transparent splice. Idle servers stop again after a configurable number of empty minutes.

Plugins and mods — search and install from Modrinth, Hangar, SpigotMC (via Spiget) and CurseForge, filtered to what actually fits the server's loader and version. Installed items are tracked so updates can be detected, and files dropped in by hand are still listed.

Worlds — every world in the directory is discovered and its level.dat parsed for seed, generator version, game mode and difficulty. Switch the active world, reset one with a new seed, import a world zip, or download one.

Backups — gzip tar archives with save-off / save-all flush / save-on around them so a region file is never captured mid-write. Restore keeps the previous tree until the extract succeeds. Scheduled backups support retention.

Scheduling — five-field cron for restart, start, stop, backup, prune and arbitrary console commands, with an in-game countdown before a scheduled restart.

Multi-tenant — a Plesk permission gates the extension, and servers can be assigned to a customer or shared with several. Resellers and customers only ever see their own.

REST API — 75 endpoints, scoped bearer tokens, WebSocket console. See docs/API.md.

Localised — the interface ships in all 32 languages Plesk supports. A locale missing a string falls back to English for that string alone, so a partial translation never shows a raw key.

Installing

Download the packaged extension from the releases page, or build it:

sh tools/build.sh          # writes build/minecraft-manager-<version>-<release>.zip

Then, on the Plesk host:

plesk bin extension --install /path/to/minecraft-manager-1.0.0-1.zip

That is the whole install: the package carries the daemon, and the extension's root helper lays it down at /opt/plesk-minecraft, writes the plesk-minecraftd systemd unit and starts it. Requirements are Plesk Obsidian 18.0.40+, Linux, and Python 3.9 or newer — which Plesk hosts already have.

See docs/INSTALL.md for firewall notes, DNS and troubleshooting.

How it is put together

Browser ──HTTPS──> Plesk extension (PHP) ──HTTP+token──> mcpd (Python, root)
                                                            │
                                                            └──> Minecraft servers
                                                                 (one user each)

The PHP half holds no state; it renders and proxies. mcpd is the long-lived owner that holds each server process, keeps its console buffer, runs the scheduler and sits on the port for wake-on-join. It is written against the Python standard library only — no pip, no venv, nothing to install at extension-install time, which matters on a hardened host where Ubuntu marks the system interpreter externally managed.

docs/ARCHITECTURE.md explains the design decisions, including why servers are supervised directly rather than as generated systemd units.

Layout

Path What
daemon/mcpd/ the control-plane daemon
daemon/systemd/ the unit file
extension/ the Plesk extension (meta.xml, plib/, htdocs/, sbin/)
tools/build.sh assembles the installable zip
tools/devdeploy.sh rsyncs a working tree onto an installed extension
docs/ architecture, API and install notes

Development

python3 -m unittest discover -s tests -t .   # 107 tests, no dependencies
sh tools/build.sh                            # build the installable package
sh tools/devdeploy.sh                        # push a working tree to a test host

The test suite covers the deterministic parts: path containment, the server.properties schema and its writer, cron parsing, the wire protocol, level.dat across three format generations, the console parsers and the file manager sandbox. CI additionally runs them on Python 3.9 through 3.13, lints the PHP on three versions, and refuses any third-party Python import or any asset loaded from a CDN.

Translating

Message catalogues live in extension/plib/resources/locales/. en-US.php is the source of truth; the others may be partial, since anything missing falls back to it per string. Keep %%placeholder%% markers intact and leave product and protocol names (Minecraft, Paper, RCON, cron, server.properties) in English.

Security notes

The daemon listens on loopback unless a public API port is deliberately enabled. Its token lives in a 0600 root-owned file and is mirrored into Plesk's encrypted settings store. Minecraft servers never run as root: each gets its own system account and can only reach its own directory. Every path that reaches the filesystem is resolved with realpath and re-checked against the server root, so a symlink planted by a plugin cannot escape. Console input is written to the JVM's stdin and is never passed through a shell.

Documents

Licence

MIT. See LICENSE. The extension also ships an end-user licence agreement, shown before first use, at extension/plib/EULA.txt.

About

Run Minecraft servers from inside Plesk: live console, plugin/mod installer, worlds, backups, scheduling, sleep-and-wake-on-join, and a scoped REST API.

Topics

Resources

Security policy

Stars

0 stars

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages