ioprodz deploy / throwaway production

throwaway is live

Service app on port 3000, environment production. This page is the starter app from ioprodz-deploy: build your app in its place.

This is a pull request's preview: its own data and variables, never production's. Merging the pull request deploys it to production; closing it removes this preview.

Start building on a dev machine

A dev machine is the repo on a branch, running in dev mode in the cloud, with VS Code and Claude in your browser. Nothing to install.

Open a dev machine
  1. Under New dev machine, pick throwaway and type a new branch name (it starts from main).
  2. In a minute or two you get the Editor, with Claude open in the terminal: tell it what to build. It knows this project's setup from AGENTS.md.
  3. The app runs at its own address and restarts on every save (node --watch server.js, set in .devcontainer/devcontainer.json). Switch between Editor, Split (Claude next to the app), App and Logs.
  4. Share link lets someone without an account see it for 1 to 24 hours. The machine sleeps after 2 hours idle and wakes when you open it; it has its own database (Reset DB empties it).

Changing the stack (Next.js, Vite, Python…)? Ask Claude to update .devcontainer/devcontainer.json and the Dockerfile with it, then Rebuild the dev machine.

From branch to production

  1. Push the branch. Claude pushes its work to the dev machine's branch (never to main).
  2. Open a pull request on Gitea. It gets a preview at https://throwaway-pr-<N>.ioprodz.com with its own data, linked in a PR comment. Previews are LAN only; the label preview-public makes one public. Closing the PR removes it.
  3. Merge into main. CI builds the image, pushes it to Harbor and deploys to throwaway.ioprodz.com: CI runs.

In the deploy app

What the repo holds

DockerfileBuilds the production image. The container must listen on $PORT (3000).
server.js, index.html, dev.htmlThis placeholder: replace them with your app. dev.html is the page a dev machine shows (IODEPLOY_ENV=dev).
.devcontainer/devcontainer.jsonThe dev machine: image, install step, dev command, port.
AGENTS.mdHow this project runs, for Claude and other agents. Keep it current.
.gitea/workflows/deploy.yml: build and deploy on push to main; preview.yml: a preview per pull request.

Environment variables

Already set for this app in production. Previews and dev machines get their own values, never production's.

APP_URL
IODEPLOY_ENV
DATABASE_URL

URLs

Prefer your own computer?

Clone and run it locally
git clone https://git.ioprodz.com/osminosm/throwaway.git
# or over SSH
git clone ssh://[email protected]:222/osminosm/throwaway.git
cd throwaway
node --watch server.js   # http://localhost:3000

Then the same flow: a branch, a pull request, merge.