Find your next open-source project

Search by name, purpose, or keyword — or paste a GitHub repository URL

sshkeda/minecraft-server-on-orange-cloud

Games

Deploy a Paper Minecraft Java server on Cloudflare that sleeps when idle and wakes on player connect.

332
7
TypeScript
MIT
1 day old

What it is

This project deploys a Paper Minecraft Java server entirely inside a Cloudflare account. Players connect over TCP to a hostname on your own domain; Spectrum forwards the connection to a Worker and Durable Object, which starts a Paper container and relays bytes while the container boots. World data is saved to R2 roughly every five minutes, and after 10 minutes with no players the container saves and stops, cutting idle cost. The next connection wakes it in about 30 seconds.

The approach removes the VPS to patch and the port forwarding to configure, but it is not free and depends on several Cloudflare products being set up in advance.

Cost and prerequisites

The README states fixed costs of $25–30 per month: the $5 Workers Paid plan plus a domain on Pro ($25 monthly, $20 billed yearly) or Business, because Spectrum is not available on Free zones. While the container is awake you also pay for it; at Cloudflare's published rates, roughly two hours of play per day adds about $5 a month, and a never-sleeping server adds $40–90.

You need macOS or Linux with glibc (Windows and Alpine are not supported), Bun 1.4.4+, Node.js 22.12+, Docker running, a Workers Paid account with R2 enabled and a workers.dev subdomain, a Pro/Business zone, and acceptance of the Minecraft EULA.

Quick start

  1. Install dependencies:

    bun install --frozen-lockfile
    
  2. Sign in the deploy tool, Alchemy, and choose OAuth with All Scopes when prompted:

    bun scripts/setup-alchemy.ts
    
  3. Create .env with a hostname that has no DNS record yet:

    MINECRAFT_EULA=true
    MINECRAFT_SPECTRUM_HOST=play.example.com
    MINECRAFT_PLAYERS=Alice,Bob
    
  4. Deploy. The script previews changes and asks for confirmation; add --dry-run to preview only:

    bun scripts/deploy.ts
    
  5. In Minecraft, open Multiplayer → Add Server and enter the hostname. If the server was asleep, the first connection wakes it; refresh or join again after about 30 seconds.

Settings are applied by editing .env and redeploying. MINECRAFT_WHITELIST defaults to true; MINECRAFT_VERSION and MINECRAFT_PAPER_BUILD must be set together and use Minecraft 1.21 or newer. To download the world, open the backupBucket printed by the deploy in R2 and fetch survival/latest.tar.gz. To stop container billing, run bun alchemy destroy --stage production --profile default scripts/stack.ts, using the same stage and profile as the deploy.

Limits

  • One world per stage; no console, plugins or mods.
  • Only the latest checkpoint is kept. An unclean container stop loses play since the last successful save — usually a few minutes, longer if R2 saves were failing.
  • The world and a compressed copy must both fit on the 12 GB container disk.
  • Any Minecraft connection wakes the server, including server list refreshes; bigger worlds take longer to wake.
  • Pro and Business zones allow one Spectrum route to a Worker, so a second public stage needs another zone unless you have Spectrum Enterprise.
  • Spectrum routes to Workers and Alchemy are both in beta.
  • The world cannot move to an older Minecraft version; use a new stage for that.

HotRepo's take

The repository is a small TypeScript deploy tool rather than a fork of server software: it wires Cloudflare Spectrum, Workers, Durable Objects, Containers and R2 around an unmodified Paper server. The interesting trade-off is explicit in the README — idle sleeping keeps container costs low, but the $25–30 monthly fixed fee and the Pro/Business zone requirement make this more expensive than a cheap VPS for light use. The 12 GB disk and checkpoint-only backups are practical constraints worth checking against an existing world size before adopting it. HotRepo recorded the project on the new-project list on 2026-11-22, gaining 27 stars in the hour from 112 to 139; there is no GitHub daily rank record and no Hacker News discussion data.

Written by AI from the project's public information and HotRepo's records, updated . The project's own docs are the source of truth.

You might also like

  1. PaperMC/PaperA drop-in high-performance Minecraft Java server for admins, plus a plugin API for developers.Java12,781
  2. rivet-dev/open-orangeRuns existing Cloudflare Workers and Durable Objects on AWS, GCP, Azure, or self-hosted servers without code changes.TypeScript107
  3. Pumpkin-MC/PumpkinA Rust reimplementation of the Minecraft server for admins who want vanilla compatibility without the JVM.Rust12,616
  4. PojavLauncherTeam/PojavLauncherRuns Minecraft: Java Edition on Android phones, including old and new versions and Forge/Fabric mods, for players without a PC.Java9,468
  5. rociiu/talorysA single-user chat assistant that stores memory, tasks, notes and reminders in your own Cloudflare account, with no server to run.TypeScript1,383