Skip to main content

run_http_server

Function run_http_server 

Source
pub async fn run_http_server(
    config: Config,
    workspace: PathBuf,
    options: RuntimeApiOptions,
) -> Result<()>
Expand description

Start the runtime API server.

options.port == 0 is now accepted and means “let the OS pick an ephemeral port”. The actually bound port is reported back to the supervisor via the DS_PICK_READY line (port: <bound>) and through the local_addr().port() log line below; Zagens desktop consumes it via tokio::sync::watch::<u16> (see crates/desktop/src/sidecar.rs D2 work). The guard that previously rejected port 0 was removed in this commit (D2 follow-up).