diff options
author | Bryan Newbold <bnewbold@archive.org> | 2021-02-02 11:42:43 -0800 |
---|---|---|
committer | Bryan Newbold <bnewbold@archive.org> | 2021-02-02 11:42:43 -0800 |
commit | b8991aed0f4c9f58daad1865a3873fc31bdc96bd (patch) | |
tree | 9b1a669f192fdddc419ac06a6632a46e690a5cc8 /rust/fatcat-openapi/examples/server/main.rs | |
parent | 119835ea0cf68f0003299cb3e285ae7d8d744af4 (diff) | |
download | fatcat-cli-b8991aed0f4c9f58daad1865a3873fc31bdc96bd.tar.gz fatcat-cli-b8991aed0f4c9f58daad1865a3873fc31bdc96bd.zip |
re-codegen openapi stuff
Diffstat (limited to 'rust/fatcat-openapi/examples/server/main.rs')
-rw-r--r-- | rust/fatcat-openapi/examples/server/main.rs | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/rust/fatcat-openapi/examples/server/main.rs b/rust/fatcat-openapi/examples/server/main.rs index af089c2..5488dc6 100644 --- a/rust/fatcat-openapi/examples/server/main.rs +++ b/rust/fatcat-openapi/examples/server/main.rs @@ -8,7 +8,8 @@ mod server; /// Create custom server, wire it to the autogenerated router, /// and pass it to the web server. -fn main() { +#[tokio::main] +async fn main() { env_logger::init(); let matches = App::new("server") @@ -21,5 +22,5 @@ fn main() { let addr = "127.0.0.1:8080"; - hyper::rt::run(server::create(addr, matches.is_present("https"))); + server::create(addr, matches.is_present("https")).await; } |