feat: setup a backend server with axum

This commit is contained in:
2024-09-23 18:02:07 +02:00
parent 2e057eee01
commit a50d951af7
5 changed files with 173 additions and 10 deletions

View File

@ -0,0 +1,10 @@
use backend::get_router;
#[tokio::main]
async fn main() {
let app = get_router();
let listener = tokio::net::TcpListener::bind("0.0.0.0:8080").await.unwrap();
println!("Listening on {}", listener.local_addr().unwrap());
axum::serve(listener, app).await.unwrap();
}