Skip to content

Add support for --no-verify-certs for gitlab-runner register command

Hello, I've got a Gitlab instance behind a corporate VPN that uses a self-signed SSL certificate. Corporate policy prevents us from opening it up to the 'Net even to temporarily get a free cert from companies like LetsEncrypt, so it's self-signed SSL or no SSL at all (or internal CA, but frankly that's a bit too much for our needs at this time). Running 'gitlab-runner register' and giving it our https:// gitlab endpoint fails because of the self-signed certificate. It would be super if there was a '--no-verify-certs' or a '--insecure-mode' or something similar that accepted (ideally PINNED) a self-signed SSL cert without complaint.

ideal end result:

me@somehost:~$ sudo gitlab-runner register
Running in system-mode.                            
                                                   
Please enter the gitlab-ci coordinator URL (e.g. https://gitlab.com/):
https://repo.myhost.lan/ci
Please enter the gitlab-ci token for this runner:
<some-token> 
Please enter the gitlab-ci description for this runner:
[repo]: nifty-repo
Please enter the gitlab-ci tags for this runner (comma separated):
nifty,repo,stuff,things
Registration succeded
me@somehost:~$
Edited by 🤖 GitLab Bot 🤖