Skip to content
LantharosPublic

About

Code hosting, review, and self-hosted CI.

Resources

Stars

0 stars

Watchers

0 watching

Forks

Repository files navigation

Marl

Marl is a focused code-hosting platform for repositories, issues, pulls, and self-hosted CI.

The product contract lives in docs/product.md, and the implementation boundaries live in docs/architecture.md. Plans and their economics are proposed in docs/launch-plans.md.

Runner registration, repository workflows, service installation, labels, logs, and artifacts are documented in docs/runners.md. The repository acknowledgement and recovery contract is documented in docs/operations/repository-reliability.md. SSH key authentication and the production TCP topology are documented in docs/operations/ssh.md. Production resources, routes, secrets, and deployment order are documented in docs/operations/deployment.md.

Development

Install JavaScript dependencies once:

bun install

Copy apps/api/.dev.vars.example to apps/api/.dev.vars and replace AUTH_SECRET and SECRET_ENCRYPTION_KEY before creating an account. Marl supports password and passkey sign-in. Reports are reviewed in Pult; set PULT_KEY to the dev environment key of the marl project to send them there while developing.

Generate the 32-byte encryption key with bun -e "console.log(Buffer.from(crypto.getRandomValues(new Uint8Array(32))).toString('base64'))".

Production authentication email is sent directly through Cloudflare Email Service. Onboard marl.sh for Email Sending and keep the EMAIL binding restricted to noreply@marl.sh.

Start the web application, API, and local Git gateway together:

bun dev

Marl uses a dedicated local port range so it can run alongside other projects:

  • web: http://127.0.0.1:42617
  • API: http://127.0.0.1:42618
  • Git: http://127.0.0.1:42619
  • Worker inspector: 42620
  • SSH Git: ssh://git@127.0.0.1:42621

The development supervisor owns every service process tree. Pressing Ctrl+C stops Vite, Wrangler, the Rust Git gateway, and their descendants together. If one service fails, the others are stopped as well so a partial Marl stack is not left running.

Or run a smaller surface:

bun dev:web
bun dev:api
bun dev:git

bun dev:api also starts and waits for the Git gateway because repository API routes depend on it.

To explore the interface with realistic data, start bun dev on a fresh database and run bun run seed in another terminal. It creates a small team, an organization with a TypeScript repository, issues, pulls in every state, check runs, and releases. Sign in as demo with the password in scripts/seed/accounts.ts. bun run db:reset (with bun dev stopped) clears all local data before reseeding.

Production Git hosting is packaged by apps/git-edge and Dockerfile.git as a Cloudflare Worker backed by immutable Git packs in R2, repository and organization Durable Objects, and short-lived Containers for Git compatibility, validation, indexing, and compaction. The local Rust gateway replaces those Containers during development, including on Windows. To exercise the complete Cloudflare Worker and Container topology, run bun run --cwd apps/git-edge dev:cloudflare from WSL or Linux; Wrangler does not support local Container development directly on Windows.

The normal workspace build validates the Worker bundle without requiring Docker. Before a Git deployment, run bun run --cwd apps/git-edge build:container with Docker Engine running to build and validate the container image as well.

Before considering a milestone complete:

bun run format:check
bun check
bun run build
bun run test
cargo clippy --workspace --all-targets -- -D warnings

bun run format applies the shared Prettier style, including Tailwind class ordering.

Run the isolated dogfood qualification after Docker Engine is available:

bun qualify

Qualification uses random loopback ports and temporary D1, R2, runner, and repository directories. It pushes Marl's real Git history, verifies workflow supersession and Docker execution, exercises every pull-request merge method and idempotent retry, restarts the local services, and checks a fresh clone with git fsck --strict. Its services, containers, networks, and temporary storage are removed whether the run succeeds or fails. The command validates the local compatibility topology; the Worker, R2, Durable Object, and Container release gate remains a separate Linux or WSL staging requirement.

Product boundary

Marl has six primary product surfaces:

  • Home: a compact view of your inbox, recent runs, and repositories.
  • Inbox: mentions, assignments, and relevant updates.
  • Code: repositories, files, branches, and history.
  • Issues: repository work, discussion, assignment, and triage.
  • Pulls: review, checks, and merging.
  • Runs: self-hosted CI jobs, live logs, and artifacts.

Features outside that loop are intentionally deferred.

About

Code hosting, review, and self-hosted CI.

Resources

Stars

0 stars

Watchers

0 watching

Forks

Contributors

Languages