behnam2016

gitlab-ce_letsencrypt

Dec 10th, 2019
432
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. # gitlab.rb , 8230 port in host is mapped to 443 in gitlab-ce
  2.  
  3. external_url "http://gitlab.mydomain.tld:8230"
  4. registry_external_url "http://registry.mydomain.tld:8230"
  5. mattermost_external_url "http://mattermost.mydomain.tld:8230"
  6.  
  7. # gitlab.subdomain.conf
  8. server {
  9.     listen 443 ssl;
  10.  
  11.     server_name gitlab.*;
  12.  
  13.     include /config/nginx/ssl.conf;
  14.  
  15.     client_max_body_size 0;
  16.  
  17.     location / {
  18.         include /config/nginx/proxy.conf;
  19.  
  20.         proxy_max_temp_file_size 2048m;
  21.         set $upstream_gitlab gitlab;
  22.         proxy_pass http://$upstream_gitlab:8230;
  23.         proxy_redirect off;
  24.                 proxy_set_header Host $http_host;
  25.                 proxy_set_header X-Real-IP $remote_addr;
  26.                 proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
  27.                 proxy_set_header X-Forwarded-Proto $scheme;
  28.                 proxy_set_header X-Forwarded-Protocol $scheme;
  29.                    proxy_set_header X-Url-Scheme $scheme;
  30.     }
  31. }
  32.  
  33. # registry.subdomain.conf
  34.  
  35. server {
  36.     listen 443 ssl;
  37.  
  38.     server_name registry.*;
  39.  
  40.     include /config/nginx/ssl.conf;
  41.  
  42.     client_max_body_size 0;
  43.  
  44.     location / {
  45.         include /config/nginx/proxy.conf;
  46.  
  47.         proxy_max_temp_file_size 2048m;
  48.         set $upstream_registry registry;
  49.         proxy_pass http://$upstream_registry:8230;
  50.         proxy_redirect off;
  51.                 proxy_set_header Host $http_host;
  52.                 proxy_set_header X-Real-IP $remote_addr;
  53.                 proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
  54.                 proxy_set_header X-Forwarded-Proto $scheme;
  55.                 proxy_set_header X-Forwarded-Protocol $scheme;
  56.                    proxy_set_header X-Url-Scheme $scheme;
  57.     }
  58. }
RAW Paste Data

Adblocker detected! Please consider disabling it...

We've detected AdBlock Plus or some other adblocking software preventing Pastebin.com from fully loading.

We don't have any obnoxious sound, or popup ads, we actively block these annoying types of ads!

Please add Pastebin.com to your ad blocker whitelist or disable your adblocking software.

×