Lucas

Project — my-cloud

A Mini Cloud Provider Built From Scratch in Rust

Reverse proxy, container orchestrator, object storage, metrics and VPN, with no framework.

Image 1
Image 2
Image 3
Image 4
Image 5
1 / 5
01

In plain English

Services like AWS or Google Cloud let you run programs and store files on someone else's servers. I wanted to understand what really happens behind the scenes, so I built a tiny version of one myself. From a web dashboard you can create and launch isolated programs (containers), upload and download files, and watch the machine's CPU and memory in real time. Every piece is small enough to be read in one sitting, which makes it a good way to learn how a real cloud works.

02

For the curious

The project is a Cargo workspace of independent Rust binaries that talk plain HTTP/1.1 over TCP. There is no web framework and no async runtime: the HTTP parser, the routing and the thread-per-connection model are hand-written. A reverse proxy acts as the single entry point, checks a bearer token on write requests and forwards traffic by URL prefix. The orchestrator stores containers in a JSON file, launches processes inside an OverlayFS (copy-on-write, like Docker image layers) with cgroups limits, and runs a reconciliation loop that restarts crashed containers every 5 seconds. The storage service is an S3-style key/value store protected against path traversal, the observability service reads host and per-process metrics from /proc, and a point-to-point VPN tunnels a TUN interface over UDP with ChaCha20-Poly1305 encryption. A Next.js 16 / React 19 / Tailwind 4 dashboard sits on top and polls the API.

A little summary :

My Cloud is an educational deep dive into the building blocks of cloud computing. Rewriting an HTTP server, a container runtime, an object store and an encrypted tunnel without any framework taught me a lot about Linux internals (OverlayFS, cgroups, /proc, TUN devices), concurrency in Rust and network protocols, the same things that big cloud providers hide behind their APIs.