1
0
mirror of https://github.com/matrix-org/matrix-authentication-service.git synced 2025-08-07 17:03:01 +03:00

Serve static files live from disk in dev mode

This commit is contained in:
Quentin Gliech
2022-04-28 16:08:28 +02:00
parent 8044d0a41b
commit 8a256596d7
17 changed files with 258 additions and 193 deletions

View File

@@ -194,6 +194,8 @@ impl Options {
let url_builder = UrlBuilder::new(config.http.public_base.clone());
let static_files = mas_static_files::service(&config.http.web_root);
// Explicitely the config to properly zeroize secret keys
drop(config);
@@ -217,6 +219,7 @@ impl Options {
&mailer,
&url_builder,
)
.fallback(static_files)
.layer(ServerLayer::default());
info!("Listening on http://{}", listener.local_addr().unwrap());