Skip to content

Latest commit

 

History

2 Commits

Folders and files

NameName
Last commit message
Last commit date
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Instance

Always-on compute control plane: reserved RAM on European metal for bots, gateways, and workers.

This repo is the product shell described in fork-railway-rent-and-resell.md:

  • Web (web/) — Next.js site + dashboard, deploy to Vercel
  • API (api/) — Go control plane that quotes pricing and provisions Docker containers locally
  • Later — move the same API onto a Hetzner CX23 (customer zero), then a dedicated AX box when you sell slices

Railway itself is not forked. Instance is your brand and API; orchestration starts with local Docker and grows toward a Coolify-backed host.

Local run (test first)

Prerequisites

  • Go 1.22+
  • Node 20+
  • Docker Desktop running (optional — without it, API runs in mock provision mode)

1. API

cd api
cp ../.env.example ../.env   # optional
go mod tidy
go run ./cmd/server

API: http://127.0.0.1:8080
Health: GET /v1/health

2. Website

cd web
npm install
npm run dev

Site: http://localhost:3000
Dashboard: http://localhost:3000/dashboard

Or use the helper:

./scripts/dev.sh

Quick API smoke test

curl -s http://127.0.0.1:8080/v1/health
curl -s http://127.0.0.1:8080/v1/pricing
curl -s -X POST http://127.0.0.1:8080/v1/instances \
  -H 'Content-Type: application/json' \
  -d '{"name":"demo","memory_gb":1,"image":"nginx:alpine"}'

Pricing (public)

Resource Rate
Reserved RAM $8 / GB-month
Included CPU 0.25 vCPU per GB
Extra vCPU $8
Volume first 10 GB included, then $0.10 / GB-month

Bill monthly in advance. Do not meter per-second idle on metal you already pay for.

Vercel (website)

Production: https://instance.hyperlinks.space

The Vercel project is linked to this GitHub repo with install/build rooted at web/.

Until the API is public, local rewrites proxy /api/* to http://127.0.0.1:8080. Set INSTANCE_API_URL on Vercel when the Go API is reachable.

Buy machines (after local works)

Do not buy dedicated metal until local create/stop/start is boring.

  1. This project only: Hetzner Cloud CX23 (or CX33) in Falkenstein or Helsinki (~€5.49–€8.49/mo). Run the Go API + Docker there.
  2. When selling: Server Auction / AX41-1-LTD / AX42-1-LTD / AX42-1 in the same cities. Sell reserved GB at $8; break-even roughly 9–15 GB sold.

See fork-railway-rent-and-resell.md for full rent tables and isolation rules.

Layout

Instance/
  api/                 Go API
  web/                 Next.js (Vercel)
  deploy/local/        docker-compose for API
  scripts/dev.sh       start API + web
  fork-railway-rent-and-resell.md

License notes

When you later vendor Coolify / Railpack, keep their LICENSE / NOTICE files and never ship Railway trademarks.

About

Always-on compute — reserved RAM for bots, gateways, and workers

Resources

Stars

0 stars

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages