fix: change project naming, create dummy sesame-vitale project
This commit is contained in:
14
crates/app/src/main.rs
Normal file
14
crates/app/src/main.rs
Normal file
@ -0,0 +1,14 @@
|
||||
use ::app::get_router;
|
||||
use std::path::Path;
|
||||
use std::env;
|
||||
|
||||
#[tokio::main]
|
||||
async fn main() {
|
||||
let manifest_dir = env::var("CARGO_MANIFEST_DIR").unwrap();
|
||||
let assets_path = Path::new(&manifest_dir).join("assets");
|
||||
let router = get_router(assets_path.as_path());
|
||||
|
||||
// TODO: select port based on available port (or ask in CLI)
|
||||
let listener = tokio::net::TcpListener::bind("0.0.0.0:3000").await.unwrap();
|
||||
axum::serve(listener, router).await.unwrap();
|
||||
}
|
Reference in New Issue
Block a user