我无法成功运行 autodevops 管道。我已经阅读了多个教程、指南、问题、修复、解决方法,但现在我需要您的支持。
我有一个家庭 kubernetes 集群(两个虚拟机)和一个使用 HTTPS 的 GitLab 服务器。我已经设置了集群并在 GitLab 组级别中定义了它(安装了 helm、ingress、runner)。我必须做一些调整才能使运行程序在 gitlab 中注册(它最初不接受证书)。
现在,当我运行 autodevops 管道时,我在日志中收到如下错误:
Running with gitlab-runner 11.9.0 (692ae235) on runner-gitlab-runner-5976795575-8495m cwr6YWh8 Using Kubernetes namespace: gitlab-managed-apps Using Kubernetes executor with image registry.gitlab.com/gitlab-org/cluster-integration/auto-build-image/master:stable ... Waiting for pod gitlab-managed-apps/runner-cwr6ywh8-project-33-concurrent-0q7bdk to be running, status is Pending Running on runner-cwr6ywh8-project-33-concurrent-0q7bdk via runner-gitlab-runner-5976795575-8495m... Initialized empty Git repository in /testing/helloworld/.git/ Fetching changes... Created fresh repository. fatal: unable to access 'https://gitlab-ci-token:[MASKED]@gitlab.mydomain.com/testing/helloworld.git/': SSL certificate problem: unable to get issuer certificate
我尝试了很多解决方法,例如在 /home/gitlab-runner/.gitlab-runner/certs/gitlab.mydomain.com.crt
下添加我的域的 CA 证书,但仍然没有结果。
最佳答案
当无法验证自签名证书时,会发生错误。
除了添加 CA 证书之外的另一个解决方法是强制 git 不使用全局选项执行证书验证:
$ git config --global http.sslVerify false
关于kubernetes - 致命: unable to access 'https://gitlab-ci-token:[MASKED]@gitlab.mydomain.com/xxx.git/' : SSL certificate problem: unable to get issuer certificate,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/56411421/