Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Bug]: Local addons-server Throws 502 On Larger Files #15029

Open
1 task done
chrstinalin opened this issue Sep 18, 2024 · 3 comments
Open
1 task done

[Bug]: Local addons-server Throws 502 On Larger Files #15029

chrstinalin opened this issue Sep 18, 2024 · 3 comments

Comments

@chrstinalin
Copy link

chrstinalin commented Sep 18, 2024

What happened?

In a local environment, uploading any file >5mb will cause a nginx 502 and only fixed with a make down/up. This doesn’t happen on dev — add-ons up to 200mb can be uploaded successfully and anything larger errors as expected.

There's a temporary workaround by modifying addons.conf, mentioned in mozilla/addons-server#22670 --

- client_max_body_size 50m;
+ client_max_body_size 200m;
     location / {
-        try_files $uri @frontendamo;
+        try_files $uri @olympia;
     }

What did you expect to happen?

Files up to the expected limit (when >5mb) are uploaded successfully and without error.

Is there an existing issue for this?

  • I have searched the existing issues

┆Issue is synchronized with this Jira Task

@diox
Copy link
Member

diox commented Sep 20, 2024

Note that there are 2 issues here:

  • client_max_body_size should be set to 200m or so (letting us upload files that are 199.9 MB, if we account for the rest of the request body)
  • the weird proxy thing we do where requests go through addons-frontend should either be fixed or removed completely (while keeping addons-frontend pages working locally)

@diox diox removed the needs:info label Sep 24, 2024
@diox
Copy link
Member

diox commented Sep 24, 2024

We could also try to fix the proxy in addons-frontend - the error seems to be coming from there. But if it's not an easy fix we should probably stop doing that entirely like suggested above.

@chrstinalin
Copy link
Author

chrstinalin commented Sep 26, 2024

Expanding on #15029 (comment)

  • client_max_body_size being too low causes a 413
  • Proxy causes a 502

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants