Pasir

PHP application server in Rust that embeds PHP behind its own HTTP server

Runs PHP 8.1+ applications inside a Rust HTTP server on Hyper and Tokio through a custom SAPI built with ext-php-rs, replacing a PHP-FPM setup with one process that speaks HTTP/1.1 and HTTP/2, serves static files with gzip, and routes requests with regex patterns from a small TOML file.

Trade-offs

  • Each request runs non-persistently, the same way PHP-FPM does, so existing applications work unchanged, while giving up the speed of keeping a booted application in memory between requests.
  • Release binaries link PHP statically, so they cannot load dynamic extensions, and building against another PHP needs a ZTS build compiled with embed support and Zend signals turned off.

Q&A1

Not yet: it works, but is still marked experimental for production use while development continues.

Reviews

Loading reviews

    More in Tokio

    See all 5 →
    • km003c-rsOpen tools for the POWER-Z KM003C USB-C analyzer: CLI, GUIs and USB PD capture
    • OxiMuxDesktop cockpit for running several CLI coding agents in parallel worktrees
    • clipboardwireClipboard sync for text, images and files over a LAN, in one small Rust binary
    • ZionRust TLS reverse proxy with a built-in WAF and RAM cache
    • MatchmakerConfigurable fuzzy finder for the terminal, in the spirit of fzf

    More in PHP

    See all 7 →
    • FamilyWellA shared home for a family's lists, calendar, spending and car
    • EverShelfSelf-hosted pantry manager with barcode scanning, expiry alerts and AI recipes
    • NightOwl AgentSelf-hosted Laravel monitoring that drains Nightwatch telemetry into Postgres
    • OpenKOSSelf-hosted property management for boarding houses, apartments and rentals
    • CortenDeskSelf-hosted RustDesk server and admin console in one container
    • JellydashSelf-hosted Jellyfin dashboard for live streams, history, stats and alerts

    More in Performance

    See all 47 →
    • FeOxDBEmbedded key-value store in Rust with write-behind durability
    • blitcpFile copier that reads in disk order, dedupes and streams over raw SSH
    • EntrolyLocal context layer that picks what coding agents send to the model
    • BigMoeOnEdgeEngine that streams MoE experts from flash to run models larger than memory
    • AntirionAI gateway in one Rust binary, with the admin console built in
    • PXALLM server tuned for Tesla P100, V100 and GTX 10-series GPUs