CGI-BIN on One-Click install Gitlab

Posted February 5, 2015 3.2k views

I am trying to set up a web interface for a backup system and I can’t figure out where to put my .cgi scripts. Any help would be great!

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.

Submit an Answer
1 answer

The GitLab One-Click image uses the “Omnibus” installer. It ships its own bundled version of Nginx, and is designed to be stand-alone. The there are ways to tweak it. You’ll want to take a look at the README for GitLab’s “Omnibus” installer especially this doc on Nginx settings for GitLab.

Your best bet is probably to add a custom Nginx “server block.” This will allow you to set up a separate Nginx config file for for In /etc/gitlab/gitlab.rb add:

external_url ""
nginx['custom_nginx_config'] = "include /etc/nginx/conf.d/*.conf;"

You can now create a server block for your main site in the /etc/nginx/conf.d/ directory. Then run gitlab-ctl reconfigure to pick up the changes.

Check out some of the tutorials under the Nginx tag for a better understanding of the way to set up the configuration. It will depend on what kind of scripts you are trying to run.

  • I just realised that I can use PHP to execute shell code. This is what I was tryinh to get to in the first place XD.

    Now, I just need to install php…