blob: 83ce00a394e89f4d7c543818c05cdc6ed73a9a8b (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
|
use conduit::{header, Body, RequestExt, Response};
use fastcgi_conduit::Server;
fn main() {
Server::start(handler);
}
fn handler(_req: &mut dyn RequestExt) -> std::io::Result<Response<Body>> {
Ok(
Response::builder()
.header(header::CONTENT_TYPE, "text/html")
.body(Body::from_static(b"<h1>Hello</h1>"))
.unwrap()
)
}
|