Allow custom settings for embedded NGINX (e.g. to include existing server blocks)
This commit is contained in:
parent
b5bed5ba50
commit
5ba0485a48
|
@ -527,6 +527,10 @@ See [doc/settings/nginx.md](doc/settings/nginx.md).
|
|||
|
||||
See [doc/settings/nginx.md](doc/settings/nginx.md).
|
||||
|
||||
### Inserting custom settings into the NGINX config
|
||||
|
||||
See [doc/settings/nginx.md](doc/settings/nginx.md).
|
||||
|
||||
## Backups
|
||||
|
||||
### Creating an application backup
|
||||
|
|
|
@ -4,9 +4,9 @@
|
|||
|
||||
### Warning
|
||||
|
||||
The Nginix config will tell browsers and clients to only communicate with your
|
||||
GitLab instance over a secure connection for the next 24 months. By enabling
|
||||
HTTPS you'll need to provide a secure connection to your instance for at least
|
||||
The Nginix config will tell browsers and clients to only communicate with your
|
||||
GitLab instance over a secure connection for the next 24 months. By enabling
|
||||
HTTPS you'll need to provide a secure connection to your instance for at least
|
||||
the next 24 months.
|
||||
|
||||
By default, omnibus-gitlab does not use HTTPS. If you want to enable HTTPS for
|
||||
|
@ -150,6 +150,19 @@ ci_nginx['custom_gitlab_ci_server_config'] = "some settings"
|
|||
Run `gitlab-ctl reconfigure` to rewrite the NGINX configuration and restart
|
||||
NGINX.
|
||||
|
||||
## Inserting custom settings into the NGINX config
|
||||
|
||||
If you need to add custom settings into the NGINX config, for example to include
|
||||
existing server blocks, you can use the following setting.
|
||||
|
||||
```ruby
|
||||
# Example: include a directory to scan for additional config files
|
||||
nginx['custom_nginx_config'] = "include /etc/nginx/conf.d/*.conf;"
|
||||
```
|
||||
|
||||
Run `gitlab-ctl reconfigure` to rewrite the NGINX configuration and restart
|
||||
NGINX.
|
||||
|
||||
## Using an existing Passenger/Nginx installation
|
||||
|
||||
In some cases you may want to host GitLab using an existing Passenger/Nginx
|
||||
|
|
|
@ -304,6 +304,7 @@ default['gitlab']['nginx']['ssl_session_cache'] = "builtin:1000 shared:SSL:10m"
|
|||
default['gitlab']['nginx']['ssl_session_timeout'] = "5m" # default according to http://nginx.org/en/docs/http/ngx_http_ssl_module.html
|
||||
default['gitlab']['nginx']['listen_addresses'] = ['*']
|
||||
default['gitlab']['nginx']['custom_gitlab_server_config'] = nil
|
||||
default['gitlab']['nginx']['custom_nginx_config'] = nil
|
||||
|
||||
###
|
||||
# Logging
|
||||
|
|
|
@ -32,4 +32,6 @@ http {
|
|||
<% if @gitlab_ci_http_config %>
|
||||
include <%= @gitlab_ci_http_config %>;
|
||||
<% end %>
|
||||
|
||||
<%= @custom_nginx_config %>
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue