# Ryla — a batteries-included web framework for Go

> A batteries-included web framework for Go. Routing, ORM, migrations, auth, queues, mail, cache and a scheduler already wired together, and a CLI that writes the boilerplate as real Go files you can read and delete.

## Install

    curl -fsSL https://ryla.io/install.sh | sh

The script installs a Go toolchain if the machine has none, installs `ry`, and adds both to your shell's PATH, on macOS and Linux. On Windows, or with Go already present:

    go install github.com/Dshonored/ryla/cmd/ry@latest

Current version: v0.12.0. Module path: github.com/Dshonored/ryla. Licence: MIT.

## One command

`ry new` asks four questions — a database, a web mode, a frontend language and a stylesheet — and wires the answers together. Every combination compiles: twenty-four of them are scaffolded and built on every CI run, on Linux, macOS and Windows.

- **Database** — sqlite, postgres, mysql, mongo
- **Web mode** — mvc, api, react, svelte
- **Frontend** — TypeScript or JavaScript
- **Styling** — Tailwind or plain CSS

## Batteries

Not a list of packages you assemble. One framework where the session store, the queue driver and the mailer already know about each other.

- **Auth (`ry make:auth`)** — Registration, sign-in, email verification and password reset. Non-enumerable by wording and by timing.
- **Two-factor (`ry make:2fa`)** — TOTP enrolment with a QR code, a challenge that holds the session, and single-use recovery codes.
- **Queue (`ry queue:work`)** — Jobs with retries and backoff. Claims exclusively over SQL, Redis or Mongo — whichever the project uses.
- **Migrations (`ry migrate`)** — Versioned Go files that carry their own schema snapshot, so history keeps doing what it did.
- **Cache (`cache.Remember`)** — One Store interface over memory, the database, Redis or Mongo. Swap the driver with an env var.
- **Mail (`mail.Send`)** — SMTP and a log driver, templ-rendered mail views, and queued sends that survive a restart.
- **Scheduler (`ry schedule:run`)** — A cron registry with overlap prevention, so a slow task never runs twice at once.
- **Validation (`ry make:request`)** — Bind and validate into a typed struct. The error bag reaches the view keyed by field name.
- **Testing (`ry make:test`)** — Drives the real router with its own cookie jar and CSRF token. Failures print the response body.

## No container, no facades

`App` is a plain struct. Controllers hold a pointer to it and reach for what they need, so every dependency is visible and the compiler checks all of it — nothing resolves at runtime.

Generators never edit your files. `ry make:controller` writes a new file and prints the route lines to add, so `routes/web.go` stays a table of contents you can trust. Views are compiled: templ turns components into Go, so a typo or a wrong argument is a build error rather than a blank space in production.

## Deploy

`ry build` compiles the views, the frontend bundle and the static assets into a single static binary that carries its own commands. The machine that runs it needs no Go toolchain, no Node and no `ry`.

Artifact: 1 binary. Typical size: 21.8 MB. Runtime deps: 0 on the server. Verified builds: 24 per CI run.

## Status

Ryla is pre-1.0, and specific about it: features are sorted by how well each one is actually tested rather than by whether it is finished.

- **Covered end to end** — Every database × web-mode × language combination is scaffolded, built, vetted and tested on Linux, macOS and Windows.
- **Live-tested** — MongoDB and its cache, session and queue stores run against a real mongo:7 container in CI.
- **Less proven** — Postgres and MySQL compile and vet everywhere, but CI runs no migrations against a live server yet.
- **Not built** — OAuth and social sign-in. Personal access tokens exist but have no generator wiring them up.

## Elsewhere on this site

- [About](https://ryla.io/about) — the project, its scope and who maintains it
- [Contact](https://ryla.io/contact) — how to reach the maintainer
- [Privacy](https://ryla.io/privacy) — what this site stores, and what it does not
- [llms.txt](https://ryla.io/llms.txt) — the facts, and when an agent should reach for Ryla
- [Agent instructions](https://ryla.io/agents.md) — how an agent should use this site and the CLI
- [Sitemap](https://ryla.io/sitemap.xml) — every indexable page
- [Source](https://github.com/Dshonored/ryla) — the code, the issues and the releases

Canonical URL: https://ryla.io/
