On 26/03/2014 12:07 μμ, Arnaud Castaner wrote: > I'm setting up GitLab on an internal server at my company. I can't use a > SSL certificate, even self-signed, for various reasons. I believe I > changed the GitLab and Nginx configuration appropriately for this, but > for some reasons I'm still being redirected to https://10.7.2.245 when I > try to reach http://10.7.2.245. I'm not sure why. My gitlab.conf file > for Nginx looks like this: > > server { > listen *:80; > server_name 10.7.2.245; > server_tokens off; > root /home/git/gitlab/public; # this doesn't have to be a valid path > since we are redirecting, you don't have to change it. > #rewrite ^ https://$server_name$request_uri permanent; > # individual nginx logs for this gitlab vhost > access_log /var/log/nginx/gitlab_access.log; > error_log /var/log/nginx/gitlab_error.log; > > location / { > # serve static files from defined root folder;. > # @gitlab is a named location for the upstream fallback, see below > try_files $uri $uri/index.html $uri.html @gitlab; > } > > # if a file, which is not found in the root folder is requested, > # then the proxy pass the request to the upsteam (gitlab unicorn) > location @gitlab { > proxy_read_timeout 300; # > https://github.com/gitlabhq/gitlabhq/issues/694 > proxy_connect_timeout 300; # > https://github.com/gitlabhq/gitlabhq/issues/694 > proxy_redirect off; > > proxy_set_header Host $http_host; > proxy_set_header X-Real-IP $remote_addr; > proxy_set_header X-Forwarded-Ssl on; > proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for; > proxy_set_header X-Forwarded-Proto $scheme; > > proxy_pass http://gitlab; > } > } > > In config/gitlab.yml, SSL is not enabled: > > gitlab: > ## Web server settings (note: host is the FQDN, do not include http://) > host: 10.7.2.245 > port: 80 > https: false > > Is there another area I should check to make sure I'm not redirected to > a SSL URL?
You can check the official config file https://gitlab.com/gitlab-org/gitlab-ce/blob/master/lib/support/nginx/gitlab As far as I can see, proxy_set_header X-Forwarded-Ssl on; is not needed. There is also an ssl option in gitlab-shell/config.yml Finally, check if this is a browser cache problem ;) -- GPG : 0xABF99BE5 Blog: http://axilleas.me -- You received this message because you are subscribed to the Google Groups "GitLab" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. For more options, visit https://groups.google.com/d/optout.
