summaryrefslogtreecommitdiffstats
path: root/CONTEXT.md
blob: 0fd7b0dcf7c39ecaad6cd1a816758cc9721673d4 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
# CONTEXT — Minecraft Server Manager

## Glossary

- **Server Instance** — The bundled combination of a World, a Version, a Type (mod loader), optionally a Modpack, and a set of server properties (difficulty, gamemode, max players, memory allocation, etc.). Multiple Server Instances can exist, but at most one is *active* (running) at any time. Users can create, modify, delete, and choose which Instance to activate. Editing an active Instance's properties causes a container restart to apply the change.

- **Instance State** — The lifecycle of an Instance relative to the Docker container: **Inactive** (exists, not selected), **Starting** (container spinning up, Minecraft not yet ready), **Running** (container up, RCON responding), **Crashed** (container up, RCON unreachable — "check Docker logs"), **Stopping** (container shutting down), **Stopped** (container stopped, but still marked as the active Instance).

- **World** — A Minecraft save (chunks, player data, etc.). Created either by generating a fresh world from a seed and level type, or by uploading a pre-existing save as a ZIP archive. Worlds can be exported (downloaded as ZIP) and imported independently of full Backups. World exports are transient — streamed to the browser and discarded server-side.

- **World Generation** — The act of creating a new World during Instance creation. The user supplies an optional seed and a level type. Once generated, the seed is immutable for that World.

- **Version** — A mainline Minecraft server version (e.g., 1.8.9, 1.12.2, 1.21). Discovered from the official Minecraft version manifest API.

- **Type** — The server software flavor: `VANILLA`, `FORGE`, or `FABRIC`. Determines which mod loader is installed. Chosen during Instance creation and cannot be changed afterward (changing Type means creating a new Instance).

- **Mod** — A Forge or Fabric mod packaged as a `.jar` file (or nested inside a `.zip` archive) that extends the Minecraft server with new features. Uploaded per-Instance into `data/mods/`.

- **Mod Validation** — The two-layer inspection applied to every uploaded Mod before it is written to disk: (1) metadata check — reads `META-INF/mods.toml` (Forge) or `fabric.mod.json` (Fabric) for the declared side; (2) class scan — walks all `.class` entries in the jar looking for references to `net/minecraft/server` vs `net/minecraft/client`. A Mod is **accepted** if it contains any server-class reference (with or without client classes). It is **rejected** if every class references only the client side.

- **Client-side-only Mod** — A Mod that contains zero server-side classes. These are rejected because they would crash the Minecraft server with a `ClassNotFoundException` or linkage error.

- **Modpack** — An optional set of server-side mods packaged as a ZIP. Applied on top of a World + Version + Type to produce a modded Server Instance.

- **Backup** — A full snapshot of an Instance's entire `/data` directory at a point in time (world, server properties, mods, whitelist — everything). Stored as a ZIP archive inside the Server Directory. Restoring a Backup creates a new Server Instance; it does not overwrite the original.

- **Whitelist** — The list of Minecraft player usernames allowed to join the server. Managed through RCON commands. Since all Instances run in offline mode, the webUI sends usernames directly; the Minecraft server handles UUID assignment internally.

- **OP** — A player granted operator (admin) privileges on the Minecraft server. Managed through RCON commands, analogous to the Whitelist.

- **Ban** — A player banned from joining the server. Managed through RCON commands. Includes both username bans and IP bans.

- **RCON Password** — A secret auto-generated string per Instance, stored in the Instance's `server.properties` and in the webUI database. Used internally for the webUI to authenticate RCON commands to the Minecraft server. Never exposed to the user.

- **Account** — A set of credentials (username + hashed password) that authenticates a person to the webUI. All accounts have equal access to Server Instances and server operations.

- **Superuser** — An Account with elevated privileges. Only superusers can access the account management page (create/delete accounts, change passwords). At least one superuser must always exist. The initial superuser must change their password on first login.

- **Server Directory** — A configurable path on the host where all Minecraft data lives (world saves, configs, the `docker-compose.yml`, etc.). The Docker container mounts a subdirectory of this per active Instance. Backups are also stored here.

- **Container State** — The running Docker container is an external resource independent of the webUI process. The webUI inspects the container's actual state on startup and reconciles accordingly. If the webUI restarts while the container is running, the container continues unaffected and the webUI reattaches to it.