Question

Gitlab - Configuring Nginx file

When I try to push an existing repo to a new repo: error: RPC failed; result=22, HTTP code = 413

I did some research and it seems like I need to edit the nginx.conf to increase the client_max_body_size.

Where is the nginx.conf file for Gitlab though? I cannot seem to find it.


Submit an answer

This textbox defaults to using Markdown to format your answer.

You can type !ref in this text area to quickly search our full set of tutorials, documentation & marketplace offerings and insert the link!

Sign In or Sign Up to Answer

These answers are provided by our Community. If you find them useful, show some love by clicking the heart. If you run into issues leave a comment, or add your own answer to help others.

Want to learn more? Join the DigitalOcean Community!

Join our DigitalOcean community of over a million developers for free! Get help and share knowledge in Q&A, subscribe to topics of interest, and get courses and tools that will help you grow as a developer and scale your project or business.

The GitLab One-Click app uses the “omnibus” version of GitLab. The full-stack required to run is GitLab managed together rather than installed as separate pieces. The configuration file is located in /etc/gitlab/gitlab.rb

In order to add a custom Nginx setting, you’ll need to add something like the following to your configuration.

nginx['custom_gitlab_server_config'] = "client_max_body_size 200M;"

Then run sudo gitlab-ctl reconfigure for the change to take effect.

See the GitLab documentation for more information on configuring Nginx: