Docs / Install

On this page · 4 sections
Contents

PLANNED

Docker imageAPI referenceMigrating from Supabase

Docs / GET STARTED / Install

Install

Clone the workspace, build the megabase binary, or build the pinned container image.

docs/install.md · Built from commit a1a6d87 · 2026-10-09 · Edit on GitHub ↗

Megabase is one Rust binary next to PostgreSQL. Unimplemented routes return HTTP 501 {"code":"MEGABASE_NOT_IMPLEMENTED",...}. Nothing here is production software.

Clone

SHELL
git clone --recurse-submodules https://github.com/Zouhairmaj/megabase.git
cd megabase

Vendor pins live in vendor/ (vendor.toml). Coverage and the judge need the submodules.

Build from source

MSRV is 1.89. From the repository root:

SHELL
cargo build --release --locked -p megabase
./target/release/megabase

The binary listens on 0.0.0.0:8000 (MEGABASE_HOST / MEGABASE_PORT). See Configuration. just lists every recipe that works today.

The public site generator is separate:

SHELL
cargo run --manifest-path site/Cargo.toml -- --repo-root . --out _site

Container image

The root Dockerfile builds the release image. Both FROM lines are pinned by digest so Scorecard Pinned-Dependencies does not flag a floating tag (alerts #6 and #7 on main):

StageImage
Builderrust:1.89-slim-bookworm@sha256:d7fc7de78bb8c1469933aeecbf801314d30d7d6e9f0578bba4cfa285bfa37fe6
Runtimedebian:bookworm-slim@sha256:7c7b2c966bc9ee8cedfeef67e0e279108992c77681fa595db4a9d65c06ccc587

The Cloud Agent image in .cursor/Dockerfile is pinned the same way: ubuntu:24.04@sha256:534baea6a22c03a63003dbc8dbe78fe34bc0d7e595d9a9dc9834884ff530eb55 (index digest for that tag, verified 2026-10-09).

Renovate's docker datasource has pinDigests: true, so a tag bump and its digest move in the same PR. Do not un-pin these images to a bare tag.

SHELL
docker build -t megabase .
docker run --rm -p 8000:8000 megabase

The image includes megabase-healthcheck, which probes /_megabase/health.

Requirements

ToolWhy
Rust 1.89+Workspace MSRV; CI also checks 1.89
PostgreSQL 15+External database (not required just to start the 501 gateway)
DockerRelease image; Compose for the judge

Wrong or unfinished? Open an issue or edit docs/install.md on GitHub.