🩹 increase limits
This commit is contained in:
parent
71fa998861
commit
4a4e66c6ff
1 changed files with 12 additions and 0 deletions
12
src/main.rs
12
src/main.rs
|
@ -4,6 +4,7 @@ use based::get_pg;
|
||||||
use based::ui::components::prelude::Shell;
|
use based::ui::components::prelude::Shell;
|
||||||
use based::ui::prelude::*;
|
use based::ui::prelude::*;
|
||||||
use config::Config;
|
use config::Config;
|
||||||
|
use rocket::data::ToByteUnit;
|
||||||
use rocket::routes;
|
use rocket::routes;
|
||||||
|
|
||||||
pub mod config;
|
pub mod config;
|
||||||
|
@ -34,6 +35,17 @@ async fn launch() -> _ {
|
||||||
.use_ui();
|
.use_ui();
|
||||||
|
|
||||||
rocket::build()
|
rocket::build()
|
||||||
|
.configure(rocket::Config {
|
||||||
|
limits: rocket::data::Limits::new()
|
||||||
|
.limit("bytes", 8.kibibytes())
|
||||||
|
.limit("data-form", 10.gigabytes())
|
||||||
|
.limit("file", 10.gigabytes())
|
||||||
|
.limit("form", 32.kibibytes())
|
||||||
|
.limit("json", 1.mebibytes())
|
||||||
|
.limit("msgpack", 1.mebibytes())
|
||||||
|
.limit("string", 8.kibibytes()),
|
||||||
|
..Default::default()
|
||||||
|
})
|
||||||
.mount_assets()
|
.mount_assets()
|
||||||
.mount("/", routes![
|
.mount("/", routes![
|
||||||
routes::index_page,
|
routes::index_page,
|
||||||
|
|
Loading…
Add table
Reference in a new issue