Skip to content

Commit

Permalink
Actually fix IGC upload limit
Browse files Browse the repository at this point in the history
  • Loading branch information
dbrgn committed May 14, 2024
1 parent 57b6fa6 commit 18aa58b
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 1 deletion.
5 changes: 4 additions & 1 deletion Rocket.toml
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,10 @@
# profile.

[global.limits]
form = "12 MiB"
# See https://api.rocket.rs/master/rocket/data/struct.Limits#built-in-limits
form = "1 MiB"
data-form = "10 MiB"
json = "10 MiB"

[debug]
secret_key = "eXqSA0wz+qLlg8umREPesnkBzNlhwaNcp34BttIWLes="
Expand Down
2 changes: 2 additions & 0 deletions src/main.rs
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,8 @@ use rocket::{catch, catchers, get, request::Request, routes};
use serde::Deserialize;

// Limits
//
// Note: Other limits are configured in Rocket.toml!
pub const MAX_IGC_UPLOAD_BYTES: u64 = 50 * 1024 * 1024;
pub const MAX_CSV_UPLOAD_BYTES: u64 = 10 * 1024 * 1024;

Expand Down

0 comments on commit 18aa58b

Please sign in to comment.