在Centos7上安装Gitlab+Jenkins+Ansible番外篇-解决https SSL自签名证书无效问题在这里插入图片描述

橙三吉。 提交于 2020-01-19 00:25:06

番外篇-解决https SSL自签名证书无效问题

在这里插入图片描述
在这里插入图片描述

在这里插入图片描述
在这里插入图片描述
在这里插入图片描述

# 本机git窗口操作:将导出的证书from_gitlab.cer证书复制到/usr/local/jdk1.8.0_45/jre/lib/security目录下
scp C:/Users/helenlv/Desktop/DEVOPS/from_gitlab.cer root@10.20.217.17:/usr/local/jdk1.8.0_45/jre/lib/security
[root@gitlab ~]# cd /usr/local/jdk1.8.0_45/jre/lib/security/
[root@gitlab security]# keytool -import -alias from_gitlab -keystore cacerts -file from_gitlab.cer
Enter keystore password:
keytool error: java.io.IOException: Keystore was tampered with, or password was incorrect
[root@gitlab security]# keytool -import -alias from_gitlab -keystore cacerts -file from_gitlab.cer
Enter keystore password:
- 此处省略n行输出,上面密码的changeit
Trust this certificate? [no]:  Y
Certificate was added to keystore
[root@gitlab security]# keytool -list -keystore cacerts -alias from_gitlab
Enter keystore password: 此处密码的changeit

将自签名证书加入【受信任的根证书颁发机构】

在这里插入图片描述

在这里插入图片描述

在这里插入图片描述


标签
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!