use brotli compression #40, update and reduce dependencies
All checks were successful
ci/woodpecker/push/publish Pipeline was successful
All checks were successful
ci/woodpecker/push/publish Pipeline was successful
This commit is contained in:
parent
c79041e7c8
commit
13e7c5197d
3 changed files with 432 additions and 540 deletions
962
Cargo.lock
generated
962
Cargo.lock
generated
File diff suppressed because it is too large
Load diff
|
@ -10,7 +10,7 @@ publish = false
|
|||
license = "AGPL-3.0-or-later"
|
||||
|
||||
[dependencies]
|
||||
actix-web = "4.4"
|
||||
actix-web = { version = "4.4", default-features = false, features = ["macros", "compress-brotli"] }
|
||||
actix-files = "0.6"
|
||||
cached = { version = "0.46", features = ["async"] }
|
||||
ramhorns = "0.14"
|
||||
|
@ -22,6 +22,6 @@ minify-js = "0.5"
|
|||
glob = "0.3"
|
||||
comrak = "0.19"
|
||||
reqwest = { version = "0.11", features = ["json"] }
|
||||
chrono = "0.4.30"
|
||||
chrono = { version = "0.4.30", default-features = false, features = ["clock"]}
|
||||
chrono-tz = "0.8"
|
||||
rss = { version = "2.0", features = ["atom"] }
|
||||
|
|
|
@ -1,5 +1,8 @@
|
|||
use actix_files::Files;
|
||||
use actix_web::{middleware::DefaultHeaders, web, App, HttpServer};
|
||||
use actix_web::{
|
||||
middleware::{Compress, DefaultHeaders},
|
||||
web, App, HttpServer,
|
||||
};
|
||||
use std::io::Result;
|
||||
|
||||
use crate::routes::{
|
||||
|
@ -29,6 +32,7 @@ async fn main() -> Result<()> {
|
|||
HttpServer::new(move || {
|
||||
App::new()
|
||||
.app_data(web::Data::new(config.to_owned()))
|
||||
.wrap(Compress::default())
|
||||
.wrap(
|
||||
DefaultHeaders::new()
|
||||
.add((
|
||||
|
|
Loading…
Reference in a new issue