[{"data":1,"prerenderedAt":-1},["ShallowReactive",2],{"project-118004":3},{"id":4,"name":5,"fullName":6,"owner":7,"repo":5,"description":8,"homepage":9,"htmlUrl":9,"language":10,"languages":9,"totalLinesOfCode":9,"stars":11,"forks":12,"watchers":13,"openIssues":14,"contributorsCount":14,"subscribersCount":14,"size":14,"stars1d":15,"stars7d":16,"stars30d":16,"stars90d":14,"forks30d":14,"starsTrendScore":17,"compositeScore":18,"rankGlobal":9,"rankLanguage":9,"license":19,"archived":20,"fork":20,"defaultBranch":21,"hasWiki":20,"hasPages":20,"topics":22,"createdAt":9,"pushedAt":34,"updatedAt":35,"readmeContent":36,"aiSummary":9,"trendingCount":14,"starSnapshotCount":14,"syncStatus":37,"lastSyncTime":38,"discoverSource":39},118004,"minecraft-server-on-orange-cloud","sshkeda\u002Fminecraft-server-on-orange-cloud","sshkeda","Run a Minecraft Java server entirely on Cloudflare. Sleeps when nobody's playing.",null,"TypeScript",427,9,1,0,12,89,113,91.9,"MIT License",false,"main",[23,24,25,26,27,28,29,30,31,32,33],"bun","cloudflare","cloudflare-containers","cloudflare-workers","durable-objects","effect","minecraft","minecraft-server","papermc","spectrum","typescript","2026-11-21 08:57:40","2026-11-24 20:51:39","# Minecraft Server on Orange Cloud\n\nPut your Minecraft server behind the orange cloud! No VPS to patch and no ports to forward.\n\nThis runs a [Paper](https:\u002F\u002Fpapermc.io) server for Minecraft Java entirely on Cloudflare. You deploy it with one command into your own Cloudflare account, and players join at a hostname on your domain.\n\n![Players connect over TCP to Spectrum, then a Worker and a Durable Object, which starts the Paper container and answers while it wakes. The container saves the world to R2 about every 5 minutes.](assets\u002Fhow-it-works.png)\n\n## How it works\n\n1. [Spectrum takes the player's TCP connection](https:\u002F\u002Fdevelopers.cloudflare.com\u002Fspectrum\u002Fhow-to\u002Froute-tcp-traffic-to-a-worker\u002F) on port 25565 and hands it to a Worker.\n\n2. The Worker passes the connection to a Durable Object, which starts the [Paper container](https:\u002F\u002Fdevelopers.cloudflare.com\u002Fcontainers\u002F) and relays bytes to it.\n\n3. After 10 minutes with nobody online, the server saves the world and sleeps. The next player to connect wakes it in about 30 seconds.\n\n4. While it's awake, the container saves the world to R2 about every 5 minutes. Each wake restores the world before Paper starts.\n\nThis setup isn't free. The fixed cost is $25 to $30 a month:\n\n- The $5 Workers Paid plan.\n- A zone on the [Pro plan](https:\u002F\u002Fwww.cloudflare.com\u002Fplans\u002F) or Business, because Spectrum doesn't work on Free zones. Pro is $25 a month, or $20 a month billed yearly.\n\nOn top of that, you pay for the container only while it's awake. With Cloudflare's [published rates](https:\u002F\u002Fdevelopers.cloudflare.com\u002Fcontainers\u002Fplatform\u002Fpricing\u002F), a server played two hours a day adds about $5 a month, and one that never sleeps adds about $40 to $90.\n\n## Get started\n\n### What you need\n\n- macOS or Linux with glibc. Windows and Alpine aren't supported.\n- [Bun](https:\u002F\u002Fbun.sh) 1.4.4 or newer, [Node.js](https:\u002F\u002Fnodejs.org) 22.12 or newer, and [Docker](https:\u002F\u002Fwww.docker.com) running.\n- A Cloudflare account on Workers Paid, with R2 enabled and a workers.dev subdomain set up. Alchemy keeps its deploy state in a Worker on that subdomain.\n- A domain on Cloudflare whose zone is on the Pro or Business plan, or has Spectrum Enterprise. Free zones can't use Spectrum.\n- To accept the [Minecraft EULA](https:\u002F\u002Fwww.minecraft.net\u002Feula).\n\n### Steps\n\n1. Install the dependencies.\n\n   ```sh\n   bun install --frozen-lockfile\n   ```\n\n2. Connect your Cloudflare account. The project deploys with [Alchemy](https:\u002F\u002Falchemy.run), and this script signs it in.\n\n   ```sh\n   bun scripts\u002Fsetup-alchemy.ts\n   ```\n\n   Select **OAuth** when asked how to sign in, keep **All Scopes**, then approve access in your browser. Basic Scopes can't create the Spectrum route. If you have more than one account, pick the one to deploy to.\n\n3. Create a `.env` file. Use a hostname that has no DNS record yet.\n\n   ```dotenv\n   MINECRAFT_EULA=true\n   MINECRAFT_SPECTRUM_HOST=play.example.com\n   MINECRAFT_PLAYERS=Alice,Bob\n   ```\n\n4. Deploy. The script shows its changes and asks before applying them. Add `--dry-run` to only preview. The first run, even a dry run, sets up Alchemy's state store in your account.\n\n   ```sh\n   bun scripts\u002Fdeploy.ts\n   ```\n\n5. In Minecraft, open **Multiplayer**, choose **Add Server** and enter your hostname. If the server was asleep, the first connection wakes it, so refresh or join again after about 30 seconds.\n\n## Settings\n\nTo apply a change, put these in `.env` and deploy again.\n\n| Setting                                         | What it does                                                                                                                                                                                     |\n| ----------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ |\n| `MINECRAFT_EULA`                                | Must be `true`.                                                                                                                                                                                  |\n| `MINECRAFT_SPECTRUM_HOST`                       | The hostname players join. Clear it and deploy to remove the route.                                                                                                                              |\n| `MINECRAFT_PLAYERS`                             | Usernames allowed to join, separated by commas. With the whitelist on, an empty list lets nobody join.                                                                                           |\n| `MINECRAFT_WHITELIST`                           | `true` by default. Set `false` to let any Minecraft Java account join.                                                                                                                           |\n| `MINECRAFT_VERSION` and `MINECRAFT_PAPER_BUILD` | A version and stable build from [Paper downloads](https:\u002F\u002Fpapermc.io\u002Fdownloads\u002Fpaper), such as `1.21.11` and `132`. Use 1.21 or newer. Set both or neither. The default is Paper 26.3 build 257. |\n\nTo run a separate server with its own world, pass `--stage \u003Cname>` to `scripts\u002Fdeploy.ts`. Each stage needs its own hostname. Pro and Business zones allow one Spectrum route to a Worker, so a second public stage needs another zone unless you have Spectrum Enterprise. A world can't move to an older Minecraft version, so use a new stage for that.\n\n## Manage your server\n\nTo download your world, open **R2** in the Cloudflare dashboard, open the `backupBucket` the deploy printed, and download `survival\u002Flatest.tar.gz`.\n\nTo shut down and stop paying for the container:\n\n```sh\nbun alchemy destroy --stage production --profile default scripts\u002Fstack.ts\n```\n\nUse the same `--stage` and `--profile` you deployed with. That command keeps the R2 bucket so your world isn't lost by accident. Deploying again afterwards creates a new, empty bucket. To bring the world back:\n\n1. Deploy with `MINECRAFT_SPECTRUM_HOST` cleared, so nobody can start a new world.\n2. Copy `survival\u002Flatest.tar.gz` from the old bucket to the same path in the new one.\n3. Set the hostname again, deploy, and join to check the world.\n\nDelete the old bucket only after that.\n\n## Limits\n\n- One world per stage, and no console, plugins or mods.\n- Only the latest checkpoint is kept. If the container stops uncleanly, you lose the play since the last successful save. The loss is usually a few minutes, but longer if saves to R2 were failing.\n- The world and a compressed copy of it must fit together on the container's 12 GB disk.\n- Any Minecraft connection wakes the server, including server list refreshes. Port scans that send no Minecraft handshake don't. Nothing in the world runs while it sleeps, and bigger worlds take longer to wake.\n- One Spectrum route to a Worker per Pro or Business zone.\n- Spectrum routes to Workers are in public beta, and Alchemy is in beta.\n\n## Development\n\nThe end-to-end test runs the Worker and Paper locally and checks that a fresh container restores the world.\n\n```sh\nbunx --no-install @sshkeda\u002Fcheck\nMINECRAFT_EULA=true bun scripts\u002Fe2e.ts\n```\n\nNot affiliated with Mojang, Microsoft or Cloudflare.\n\n[MIT](LICENSE)\n",2,"2026-11-25 05:02:34","CREATED_QUERY"]