Laravel Rust, first real test: what was good, what was rough

I’m rebuilding my customer portal for WPMelon. Right now I run two separate systems, a license manager and a helpdesk, and customers and licenses live in both and need syncing. The new portal merges them into one open-source Laravel app.

Then Laravel Rust came out in beta. And I decided to build the portal on it, instead of PHP Laravel which I know very well.

Yes, it’s a bit risky. So before starting Phase 1, I wanted to see how it behaves on something real but small. I picked a helpdesk, because I know exactly how one should work.

So I asked Opus 5.5 (Opus from now on) to build it. As always, Opus writes the code, and I plan, review and test. It took one session, about 1 hour. I’m on the Max subscription, so there was no separate cost for this test.

The setup

  • laravel-rust 0.1.4 (beta), Laravel CLI 0.3.0, Rust 1.100.1
  • Inertia + React + TypeScript + Tailwind
  • SQLite

What got built

  • Login, registration and logout, with throttled login attempts
  • Customer and agent roles. Customers see only their own tickets
  • Tickets with status, priority and agent assignment
  • Threaded replies, agent-only internal notes, automatic status changes
  • Rich text editor (Tiptap) with server-side HTML sanitization
  • File attachments with authorized downloads and an in-app viewer for images, PDFs and text
  • Agent-only search across subjects, descriptions, replies and requesters
  • 43 feature tests

There’s no repo for this one. It was only a test.

Helpdesk ticket #1 seen by an agent, with replies, attachments and an internal note
The agent view of a ticket. Seeded demo data, plus a few replies left over from testing the attachments.

What I liked

The docs come with the app. Every new app ships with AGENTS.md, CLAUDE.md, agent skills in .agents/skills/, and the full docs for the exact installed version. For Opus this was huge. Not one documented API turned out to be wrong. Nearly every feature compiled on the first or second attempt.

AGENTS.md, CLAUDE.md, 7 agent skills and 68 bundled doc files in a new Laravel Rust app
What a new Laravel Rust app gives an AI agent: AGENTS.md, CLAUDE.md, 7 skills and the docs for the installed version.

It really feels like Laravel. Resource routes, policies, validated input structs (their version of form requests), factories, seeders, Inertia props, flash messages. All work the way I expect as a Laravel developer.

The compiler catches real mistakes. Compare a column to the wrong type and the build fails. Policy methods are passed by reference (TicketPolicy::update), so a typo doesn’t compile. create! refuses to compile when a required column is missing. And password hashes and remember tokens can’t be serialized at all, so they can’t leak into a page or JSON by accident. I like that one a lot.

Secure defaults. Fill structs prevent mass assignment. Access::deny_as_not_found() makes "you can’t see this" look the same as "this doesn’t exist". The auth docs have a ready recipe for login throttling. File responses send nosniff and a sandbox CSP by default. Very little security had to be added by hand.

Testing is great. Each test gets its own app and database and they run in parallel. The whole 43-test suite takes about 1.2 seconds of test time (cargo reports it per test file, plus about half a second for the build check). And when a test fails, the output shows the actual validation errors or Inertia props, so the problem is obvious right away.

cargo test result lines for 6 test files, 43 tests passed, 0 failed
The real cargo test run: 6 test files, 43 passed, 0 failed.

The CLI just works. laravel dev runs the server, the queue worker and Vite together, with rebuild on change. route:list, make:migration, migrate:fresh --seed. No surprises.

What was rough

Setup friction. It needs Rust 1.99+, newer than what I had installed. The new laravel CLI clashes with the old Composer-based Laravel installer, which has the same name. laravel new . fails with a confusing "application names must start with a letter" error, and it refuses an existing directory, even an empty one. So the app had to be generated somewhere else and moved in. New apps default to PostgreSQL, and switching to SQLite means editing a Cargo feature and .env by hand.

The starter kit. The default welcome page has a WebGPU terrain animation. Looks nice. But one of its dependencies pulled in a package with a high-severity npm audit finding. Removing it was one of the first tasks.

Some docs gaps. The guides are very good, but exact method signatures are not always there. For UploadedFile and FileResponse, Opus had to read the crate source. A hosted API reference would help.

Smaller surprises.

  • Input transforms only support lowercase and uppercase. HTML sanitization had to go into model hooks plus a custom validation rule.
  • No obvious computed fields on serialized models. So the rule for which attachments can be previewed lives in two places, server and frontend.
  • contains/like is case-insensitive on SQLite (ASCII only) but case-sensitive on PostgreSQL. Easy to miss when you switch databases.
  • Validation errors for a list of uploaded files come under attachments, not attachments.0. Not wrong, just not documented.

The Rust tax. Builds are slower than PHP’s instant reload, and changing Rust code restarts the dev server. Running tests while the dev server rebuilds means waiting on Cargo’s lock. And when something goes wrong, someone has to read Rust compiler errors. In this project they were rare, specific and fixable, even the ones from macros.

So, is it production ready?

My honest verdict:

Use caseVerdict
Internal tools, prototypes, side projectsUsable now. Pin versions and budget time for upgrades
Customer-facing or business-critical appsWait for 1.0, real production case studies, a security track record and a bigger ecosystem (admin panels, billing, monitoring)

It’s 0.1.x, and the docs themselves warn about breaking changes before 1.0.

So why am I still building the portal on it?

Fair question. My portal will handle licenses and support for my real customers. That’s business-critical, no doubt.

But the portal doesn’t replace anything tomorrow. My current license manager and helpdesk keep running while I build. The first two weeks of Phase 1 are a spike, and at the end of week 3 I decide go or no-go. If Laravel Rust doesn’t hold up, I fall back to PHP Laravel and nothing breaks for my customers.

Also, being early on a brand new framework is simply more interesting to build in public. You’ll see the problems as I hit them.

What I didn’t test

  • Real deployment
  • Queues under load, durable workflows, scheduling
  • WebSockets and live props
  • PostgreSQL or MySQL
  • The published performance claims (18x throughput, 8x lower memory). Those are the framework’s numbers, not mine. I can’t confirm or refute them from this project.

Can it run next to my PHP sites on HestiaCP?

I have a Hetzner VPS with PHP sites on HestiaCP, so this was my next question. I haven’t deployed it yet. This is only a plan, based on the framework’s deployment guide.

The short version: a Laravel Rust app compiles to a single binary with migrations built in. It listens on a local port and serves its own assets. HestiaCP’s nginx can sit in front as a reverse proxy and handle the domain and Let’s Encrypt, the same way it already proxies to Apache or PHP-FPM. Nothing about the PHP sites needs to change. A systemd service keeps the app running.

One gotcha from the research: behind nginx, every request comes from 127.0.0.1. Unless you tell the app to trust that proxy, login throttling counts all visitors as one IP (a few failed logins lock out everyone), and generated URLs use http instead of https. The fix is one line: middleware.trust_proxies(["127.0.0.1"]).

The binary must be built for the server’s CPU and OS. Hetzner CAX servers are ARM, so Docker on an Apple Silicon Mac builds for them natively. CX/CPX servers are x86, and there GitHub Actions is the better route.

Maybe I’ll try the deploy for real. Then I can write about the actual memory use, not estimates.

One thought on AI

This framework seems built for exactly how I work now. Bundled docs that match the code, plus fast compiler and test feedback. That’s exactly what Opus needed to get things right on the first or second try.

A human team would get the same Laravel-style productivity, I think. But someone on the team should be comfortable with Rust for the moments when the compiler pushes back.

Next step: Phase 1 and the real portal.

Leave a Comment

Your email address will not be published. Required fields are marked *

Scroll to Top