Ready to implement login page
This commit is contained in:
@ -1,8 +1,10 @@
|
||||
use actix_web::{App, HttpServer, web, get};
|
||||
use actix_web::{App, get, HttpServer, web};
|
||||
use actix_web::middleware::Logger;
|
||||
use clap::Parser;
|
||||
|
||||
use basic_oidc::constants::{DEFAULT_ADMIN_PASSWORD, DEFAULT_ADMIN_USERNAME};
|
||||
use basic_oidc::controllers::assets_controller::assets_route;
|
||||
use basic_oidc::controllers::login_controller::login_route;
|
||||
use basic_oidc::data::app_config::AppConfig;
|
||||
use basic_oidc::data::entity_manager::EntityManager;
|
||||
use basic_oidc::data::user::{hash_password, User};
|
||||
@ -50,8 +52,10 @@ async fn main() -> std::io::Result<()> {
|
||||
|
||||
HttpServer::new(|| {
|
||||
App::new()
|
||||
.wrap(Logger::default())
|
||||
.service(health)
|
||||
.route("/assets/{path:.*}", web::get().to(assets_route))
|
||||
.route("/login", web::get().to(login_route))
|
||||
})
|
||||
.bind(config.listen_address)?
|
||||
.run()
|
||||
|
Reference in New Issue
Block a user