diff options
-rw-r--r-- | doc/install/installation.md | 3 | ||||
-rw-r--r-- | lib/support/nginx/gitlab | 4 | ||||
-rw-r--r-- | lib/support/nginx/gitlab-ssl | 4 |
3 files changed, 11 insertions, 0 deletions
diff --git a/doc/install/installation.md b/doc/install/installation.md index ff0361c5e52..8b918cba133 100644 --- a/doc/install/installation.md +++ b/doc/install/installation.md @@ -368,6 +368,9 @@ Make sure to edit the config file to match your setup: # Change YOUR_SERVER_FQDN to the fully-qualified # domain name of your host serving GitLab. + # If using Ubuntu default nginx install: + # either remove the default_server from the listen line + # or else rm -f /etc/sites-enabled/default sudo editor /etc/nginx/sites-available/gitlab **Note:** If you want to use HTTPS, replace the `gitlab` Nginx config with `gitlab-ssl`. See [Using HTTPS](#using-https) for HTTPS configuration details. diff --git a/lib/support/nginx/gitlab b/lib/support/nginx/gitlab index 4688a527eba..edb987875df 100644 --- a/lib/support/nginx/gitlab +++ b/lib/support/nginx/gitlab @@ -40,6 +40,10 @@ upstream gitlab { ## Normal HTTP host server { + ## Either remove "default_server" from the listen line below, + ## or delete the /etc/nginx/sites-enabled/default file. This will cause gitlab + ## to be served if you visit any address that your server responds to, eg. + ## the ip address of the server (http://x.x.x.x/)n 0.0.0.0:80 default_server; listen 0.0.0.0:80 default_server; listen [::]:80 default_server; server_name YOUR_SERVER_FQDN; ## Replace this with something like gitlab.example.com diff --git a/lib/support/nginx/gitlab-ssl b/lib/support/nginx/gitlab-ssl index 5c94ec63432..766559b49f6 100644 --- a/lib/support/nginx/gitlab-ssl +++ b/lib/support/nginx/gitlab-ssl @@ -44,6 +44,10 @@ upstream gitlab { ## Redirects all HTTP traffic to the HTTPS host server { + ## Either remove "default_server" from the listen line below, + ## or delete the /etc/nginx/sites-enabled/default file. This will cause gitlab + ## to be served if you visit any address that your server responds to, eg. + ## the ip address of the server (http://x.x.x.x/) listen 0.0.0.0:80; listen [::]:80 ipv6only=on default_server; server_name YOUR_SERVER_FQDN; ## Replace this with something like gitlab.example.com |