Skip to content

Commit 6f33f86

Browse files
avahe-kellenbergersilverwindnoerwtechknowlogick
authored andcommitted
Added documentation about 413 errors with an nginx solution (go-gitea#15313)
* Added documentation about 413 errors with an nginx solution. Co-authored-by: silverwind <[email protected]> Co-authored-by: Norwin <[email protected]> Co-authored-by: techknowlogick <[email protected]>
1 parent 3bd8832 commit 6f33f86

File tree

2 files changed

+14
-0
lines changed

2 files changed

+14
-0
lines changed

docs/content/doc/help/faq.en-us.md

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -85,6 +85,12 @@ If certain clone options aren't showing up (HTTP/S or SSH), the following option
8585
`DISABLE_SSH`: if set to true, there will be no SSH link
8686
`SSH_EXPOSE_ANONYMOUS`: if set to false, SSH links will be hidden for anonymous users
8787

88+
## File upload fails with: 413 Request Entity Too Large
89+
90+
This error occurs when the reverse proxy limits the file upload size.
91+
92+
See the [reverse proxy guide]({{< relref "doc/usage/reverse-proxies.en-us.md" >}}) for a solution with nginx.
93+
8894
## Custom Templates not loading or working incorrectly
8995

9096
Gitea's custom templates must be added to the correct location or Gitea will not find and use them.

docs/content/doc/usage/reverse-proxies.en-us.md

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -120,6 +120,14 @@ server {
120120
}
121121
```
122122

123+
## Resolving Error: 413 Request Entity Too Large
124+
125+
This error indicates nginx is configured to restrict the file upload size.
126+
127+
In your nginx config file containing your Gitea proxy directive, find the `location { ... }` block for Gitea and add the line
128+
`client_max_body_size 16M;` to set this limit to 16 megabytes or any other number of choice.
129+
130+
123131
## Apache HTTPD
124132

125133
If you want Apache HTTPD to serve your Gitea instance, you can add the following to your Apache HTTPD configuration (usually located at `/etc/apache2/httpd.conf` in Ubuntu):

0 commit comments

Comments
 (0)