2015-12-18 10:18:57 -05:00
|
|
|
## GitLab
|
|
|
|
##
|
|
|
|
|
2015-11-03 15:28:07 -05:00
|
|
|
## Pages serving host
|
|
|
|
server {
|
|
|
|
listen 0.0.0.0:80;
|
|
|
|
listen [::]:80 ipv6only=on;
|
|
|
|
|
|
|
|
## Replace this with something like pages.gitlab.com
|
2015-12-18 06:18:11 -05:00
|
|
|
server_name ~^(?<group>.*)\.YOUR_GITLAB_PAGES\.DOMAIN$;
|
2015-11-03 15:28:07 -05:00
|
|
|
|
|
|
|
## Individual nginx logs for GitLab pages
|
|
|
|
access_log /var/log/nginx/gitlab_pages_access.log;
|
|
|
|
error_log /var/log/nginx/gitlab_pages_error.log;
|
|
|
|
|
2016-02-20 16:32:46 -05:00
|
|
|
location / {
|
|
|
|
proxy_set_header Host $http_host;
|
|
|
|
proxy_set_header X-Real-IP $remote_addr;
|
|
|
|
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
|
|
|
|
proxy_set_header X-Forwarded-Proto $scheme;
|
|
|
|
# The same address as passed to GitLab Pages: `-listen-proxy`
|
|
|
|
proxy_pass http://localhost:8282/;
|
2015-11-03 15:28:07 -05:00
|
|
|
}
|
|
|
|
|
|
|
|
# Define custom error pages
|
|
|
|
error_page 403 /403.html;
|
|
|
|
error_page 404 /404.html;
|
|
|
|
}
|