diff options
author | zuisong <com.me@foxmail.com> | 2024-01-14 14:55:24 +0000 |
---|---|---|
committer | zuisong <com.me@foxmail.com> | 2024-01-16 13:02:29 +0000 |
commit | b5e2d58f5e0a32e773e6b6b94624c8e3863179b5 (patch) | |
tree | 491e9891bb31a49a2954de819b4620f03ce57740 /src/config.rs | |
parent | Compress response using `actix_web::middleware::compress` (diff) | |
download | miniserve-b5e2d58f5e0a32e773e6b6b94624c8e3863179b5.tar.gz miniserve-b5e2d58f5e0a32e773e6b6b94624c8e3863179b5.zip |
Add option for compress response
Diffstat (limited to 'src/config.rs')
-rw-r--r-- | src/config.rs | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/src/config.rs b/src/config.rs index bfe916b..6e4a1eb 100644 --- a/src/config.rs +++ b/src/config.rs @@ -119,6 +119,9 @@ pub struct MiniserveConfig { /// If false, creation of zip archives is disabled pub zip_enabled: bool, + /// Enable compress response + pub compress_response: bool, + /// If enabled, directories are listed first pub dirs_first: bool, @@ -309,6 +312,7 @@ impl MiniserveConfig { show_wget_footer: args.show_wget_footer, readme: args.readme, tls_rustls_config: tls_rustls_server_config, + compress_response: args.compress_response, }) } } |