1

I was trying to install gitlab on my linux server following this guide and got stucked in the second setp that says

curl: (60) SSL certificate problem: self signed certificate
More details here: http://curl.haxx.se/docs/sslcerts.html

curl performs SSL certificate verification by default, using a "bundle"
 of Certificate Authority (CA) public keys (CA certs). If the default
 bundle file isn't adequate, you can specify an alternate file
 using the --cacert option.
If this HTTPS server uses a certificate signed by a CA represented in
 the bundle, the certificate verification probably failed due to a
 problem with the certificate (it might be expired, or the name might
 not match the domain name in the URL).
If you'd like to turn off curl's verification of the certificate, use
 the -k (or --insecure) option.

any idea on how can I solve this?

ANSWER be sure to have http_proxy and https_proxy variables correctly set.

---- UPDATE ---- After setting the variables I got the following answer from curl

Detected operating system as Ubuntu/trusty.
Checking for curl...
Detected curl...
Running apt-get update... done.
Installing apt-transport-https... done.
Installing /etc/apt/sources.list.d/gitlab_gitlab-ce.list...curl: (60) SSL certificate problem: self signed certificate
More details here: http://curl.haxx.se/docs/sslcerts.html

curl performs SSL certificate verification by default, using a "bundle"
 of Certificate Authority (CA) public keys (CA certs). If the default
 bundle file isn't adequate, you can specify an alternate file
 using the --cacert option.
If this HTTPS server uses a certificate signed by a CA represented in
 the bundle, the certificate verification probably failed due to a
 problem with the certificate (it might be expired, or the name might
 not match the domain name in the URL).
If you'd like to turn off curl's verification of the certificate, use
 the -k (or --insecure) option.

Unable to run:
    curl https://packages.gitlab.com/install/repositories/gitlab/gitlab-ce/config_file.list?os=Ubuntu&dist=trusty&source=script

Double check your curl installation and try again.
BRabbit27
  • 6,333
  • 17
  • 90
  • 161

1 Answers1

3

Tell curl to ignore SSL warnings with -k/--insecure. Documented in man curl.

Edit: also check your proxy settings, as the host you're trying to curl to does, in fact, have a valid SSL certificate. See the --proxy option of curl.

user2926055
  • 1,963
  • 11
  • 10
  • `curl: (52) Empty reply from server` – BRabbit27 Apr 14 '16 at 16:47
  • 1
    Hmmm, I get an HTTP 200 with valid data. Are you running on some strange restricted network, maybe....? – user2926055 Apr 14 '16 at 16:53
  • 1
    Actually yeah your network is attempting to redirect your SSL traffic, that gitlab url provides a valid NON-self signed certificate. You need to re-evaluate your network. – user2926055 Apr 14 '16 at 16:54
  • I was missing the proxy, added it to the bash_profile file and it passed that point, however, there is still a problem, see question update. – BRabbit27 Apr 14 '16 at 17:14
  • Nevermind, found the answer here (maybe worth updating the answer?) http://stackoverflow.com/questions/7559103/how-to-setup-curl-to-permanently-use-a-proxy – BRabbit27 Apr 14 '16 at 17:43
  • Actually, I had to download the script (from the guide) and add the ```-k``` option in the 150 line – X3MBoy Feb 18 '19 at 21:22