Documentation
Getting started
Install FlashLin on Linux, or build it from source, and serve your first site.
FlashLin is a single-binary web server built on Tokio and Hyper. This page covers the fastest way to get v2.0 running. See the other guides in this section for HTTP/3, QUERY/WebSocket proxying, automatic HTTPS and performance tuning.
Option 1 — One-line Linux install
Supports Debian, Ubuntu, Kali, Mint, Pop!_OS, Raspberry Pi OS, CentOS, RHEL, Rocky, AlmaLinux, Fedora, Oracle Linux, Arch, Manjaro, openSUSE, Alpine and Gentoo, on x86_64 and arm64:
curl -fsSL https://flashlin.com/install_linux.sh | bash
The installer creates /etc/flashlin/server.toml, deploys a default site to
/var/www/public, opens TCP 80/443 and UDP 443 (for optional HTTP/3) in the
detected firewall, and registers a systemd (or OpenRC) service.
sudo systemctl status flashlin
sudo nano /etc/flashlin/server.toml
sudo systemctl restart flashlin
Once installed, flashlin itself doubles as a control command for that
service — run flashlin --help for the full list:
sudo flashlin start | stop | restart # wraps systemctl <action> flashlin
flashlin status # wraps systemctl status flashlin (no sudo to view)
flashlin purge cache [config] # clears the running server's in-memory response cache
sudo flashlin remove # stops the service, removes the binary + systemd unit
purge cache is the one that isn't just a systemctl shortcut: FlashLin's
response cache lives in the memory of the already-running server process, so
nothing filesystem- or service-level can reach it. It sends a loopback-only
HTTP request to that process instead — the same access model as the built-in
/metrics endpoint. remove stops and disables the service and removes the
binary and unit; your config, web root and any TLS/ACME data are left in
place.
Option 2 — Build from source
Tested with Rust 1.95; use a current stable toolchain.
rustup update stable
# HTTP/1.1 + HTTP/2, no TLS
cargo build --release --locked
# + HTTPS (rustls, no OpenSSL required)
cargo build --release --locked --features tls
# + HTTP/3 over QUIC, manual certificates
cargo build --release --locked --features http3
# + automatic HTTPS via ACME/Let's Encrypt
cargo build --release --locked --features acme,http3
The binary is at target/release/flashlin. The http3 and acme features are
optional and additive — the default build stays free of the QUIC and ACME
dependencies.
Minimal configuration
[server]
host = "0.0.0.0"
port = 80
server_name = "FlashLin"
root = "/var/www/public"
index = ["index.html"]
max_connections = 1000
[security]
hide_server_header = true
block_dotfiles = true
block_sensitive_files = true
security_headers = true
[compression]
gzip = true
brotli = true
[[routes]]
path = "/"
root = "/var/www/public"
Validate before starting, and reload without dropping connections once you're running:
flashlin --check /etc/flashlin/server.toml
flashlin --watch /etc/flashlin/server.toml
Next steps
- Installing by distribution — package manager, firewall and other per-distro notes for everything the installer supports.
- Domain configuration and HTTPS — adding virtual hosts, routing, and Let's Encrypt certificates.
- HTTP/1.1, HTTP/2 and HTTP/3 — enabling the optional QUIC listener.
- QUERY and WebSockets — reverse-proxying to an application backend.
- Automatic HTTPS and hot reload — the full technical reference for ACME and
--watch. - Performance and limits — caching, compression, streaming and honest benchmark status.
