title: Gitlab: server certificate verification failed
body: <p>I've been granted access to a remote gitlab repo, but I systematically get this error when attempting to <code>fetch</code>, <code>pull</code> or anything else from it:</p>
  
  <pre><code>fatal: unable to access 'https://gitlab.domain.com/project/external/repo.git/': server certificate verification failed. CAfile: /etc/ssl/certs/ca-certificates.crt CRLfile: none
  </code></pre>
  
  <p>So far I have run the following (assembled from various pieces of answers I found online) in an attempt to fix this:</p>
  
  <pre><code>openssl genrsa -out gitlab.domain.com.key 2048
  openssl req -new -key gitlab.domain.com.key -out gitlab.domain.com.csr
  openssl x509 -req -days 365 -in gitlabdomain.com.csr -signkey gitlab.domain.com.key -out gitlab.domain.com.crt
  sudo cp gitlab.domain.com.key /etc/ssl/private/
  sudo cp gitlab.domain.com.key /etc/ssl/certs/
  sudo cp gitlab.domain.com.key /etc/gitlab/ssl/ # I had to manually create this directory
  sudo nano /etc/gitlab/gitlab.rb # created this file and added the lines "external_url 'https://gitlab.domain.com'" and "nginx['redirect_http_to_https'] = yes" to it
  sudo cp gitlab.domain.com.crt /usr/local/share/ca-certificates/
  sudo update-ca-certificates
  </code></pre>
  
  <p>This did not work. I have also synchronised my system clock with NTC.
  I'm running a Linux Mint 19 system, have Git installed and everything is up to date. <strong>I am running a client machine and do not have access to the server.</strong></p>
  
  <p>What other solutions are there? I can't bypass the security as the project is sensitive.</p>