Mattermost Peer-to-Peer Forum

Error: "We received an unexpected status code from the server (413)"


#1

When you receive this message when uploading a file it may be that you’re running on an AWS docker instance where Ngnix is configured to reject requests over 1MB.


#2

I’m using matttermost with the gitlab-ce package on Debian.
I’ve set nginx[‘client_max_body_size’] = ‘500m’ and mattermost_nginx[‘client_max_body_size’] = “500m” in /etc/gitlab.rb, however after a reconfiguration I still get a 413 error. Any idea?


#3

You might confirm that Nginx has the proper setting (vs the gitlab configuration). You should see client_max_body_size 500M; in the config. The config usually can be found under /etc/nginx/sites-enabled.


#4

This worked for me. Thanks