how to edit the nginx in one-clikc apps? i have followed this and set the gitlab done

  • Posted on October 14, 2014
  • tvvocoldAsked by tvvocold

i have followed this and set the gitlab done now i need set another app (in port 9700) in the server and how could i edit the nginx?(i try lsof -i :80 and find it was nginx that gitlab use) but i couldn’t find nginx setting file so i try (sudo apt-get install nginx) and it works (i find the setting file in /etc/nginx and i edit it and restart nginx but nothing worked), this is confused, does this ubuntu already has a nginx?

Show comments

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 one-click image uses GitLab’s “omnibus” installer. It is designed to be single purpose, but of course you are free to hack on it. GitLab installs its own bundled copy of Nginx to /opt/gitlab/embedded/ This is managed by Chef scripts, and it’s configuration files should not be edited directly as your changes will be overwritten.

You’d be best off installing the default nginx package along side of the bundled one. Of course, as you’ve noticed it will initially fail to start. This is because GitLab is already bound to port 80. You’ll need to edit the default Nginx configuration to listen on the new port first. Open /etc/nginx/sites-enabled/default and change:

server {
        listen 80 default_server;
        listen [::]:80 default_server ipv6only=on;


server {
        listen 9700 default_server;
        listen [::]:9700 default_server ipv6only=on;

and start Nginx:

sudo service nginx start

You should now be able to view the Nginx default page at http://your.ip.address:9700