首页 > 其他分享 >docker pull拉 x509: certificate has expired or is not yet valid:

docker pull拉 x509: certificate has expired or is not yet valid:

时间:2023-07-11 15:01:50浏览次数:41  
标签:pull certificate x509 0.0 docker yet

[root@LIN-2F8AC9DC590 macro1.3]# docker pull XXXcode-analysis:centos7.3-1.0

Error response from daemon: Get "XXXX": x509: certificate has expired or is not yet valid: current time 2023-07-11T14:27:37+08:00 is after 2018-08-22T11:54:50Z

 

x509: certificate has expired or is not yet valid:  

参考公司内论坛

先备份这个

/etc/docker/daemon.json

末尾增加一个配置项:

"insecure-registries":["0.0.0.0/0"]

 

[root@vmax26 ~]# cat /etc/docker/daemon.json

{

"storage-driver":"overlay2",

"storage-opts":["overlay2.override_kernel_check=true"],

"insecure-registries":["0.0.0.0/0"]

}

 

这样做的目的是:

在安装好Docker以后,想从公司搭建的私服Harbor上docker pull的时候碰上了x509问题,这个问题的原因是docker会验证网站的证书,私服没有相应的证书所以docker拒绝访问,但是我们也可以自己允许docker连接“不安全”的网站,在此记录一下解决方案:

--insecure-registry 127.0.0.1" (把127.0.0.1换成你需要允许的网址,如果有端口号需要加上端口号如127.0.0.1:8080





标签:pull,certificate,x509,0.0,docker,yet
From: https://www.cnblogs.com/cnchengv/p/17544648.html

相关文章

  • AWS Certificate SAA - Course 2.2 IAM & AWS CLI
    AWSAccessKeys,CLIandSDKHowcanusersaccessAWS?ToaccessAWS,youhavethe3optioins:AWSManagementConsole(password+MFA)AWSCommandLineInterface(CLI):protectedbyaccesskeysAWSSoftwareDeveloperKit(SDK)-forcode:protectedbyacce......
  • AWS Certificate SAA - Course 2 IAM & AWS CLI
    IAM:Users&GroupsIAM=IdentityandAccessManagement,GlobalserviceRootaccountcreatedbydefault,shouldn'tbeusedorsharedUsersarepeoplewithinyourorganization,andcanbegroupedIAM:PermisionsUsersareGroupscanbeassigne......
  • AWS Certificate SAA - Course 1 Getting started with AWS
    AWSCoulduseCasesAWSenablesyoutobuildsophisticated,scalableapplicationsApplicabletoadiversesetofindustriesUsecasesincludeEnterpriseIT,Backup&Storage,BigDataanalyticsWebsitehosting,Mobile&SocialAppsGamingAWS......
  • git clone和fetch以及pull区别-9
    gitclone和fetch以及pull区别一.gitcloneGitclone适用于已有远程仓库,本机没有相关的本地仓库。使用方法:1.桌面/任意目录,右键单击,点击gitbash。2.输入:gitcloneurl(远程仓库地址)二.gitfetchGitfetch适用于,本机已有相关联的远程仓库。远程仓库中做了修改,本地也做了修改,需要拉......
  • 【Debian】更换阿里源出现的Certificate问题解决方法
    系统版本Debian11源配置debhttps://mirrors.aliyun.com/debian/bullseyemainnon-freecontribdeb-srchttps://mirrors.aliyun.com/debian/bullseyemainnon-freecontribdebhttps://mirrors.aliyun.com/debian-security/bullseye-securitymaindeb-src......
  • x509: certificate signed by unknown authority harbor 架构图
    默认时,client与Registry的交互是通过https通信的。在installRegistry时,若未配置任何tls相关的key和crt文件,https访问必然失败。使用 "--insecure-registry<harborIP>"可以指定client与Registry以http的方式进行通信。 [root@c7-QHost~]#grep'insecure-r......
  • php webhook excute that can pull code
      <?phpexec('whoami2>&1',$res);var_dump($res);exec('cd'.dirname(__FILE__).'/../&&sudogitpulloriginmaster2>&1',$res,$rc);var_dump($rc);if($rc==0){echo'部署成功<br&g......
  • git pull无法拉取最新代码
    原因:本地代码与仓库中代码不一致,有过修改解决方法:1、下载代码到本地,不进行合并操作:gitfetch--all2、gitreset--hardorigin/master#(origin/master是你所需要更新的分支,把HEAD指向最新下载的版本)gitreset--hardorigin/master3、重新拉取gitpull......
  • 安装oh-my-zsh报错fatal: gnutls_handshake() failed: Error in the pull function的
    今天在安装oh-my-zsh时碰到一个安装问题,报错内容如下:root@ubuntu18:~/ohmyzsh/tools#./install.shCloningOhMyZsh...InitializedemptyGitrepositoryin/root/.oh-my-zsh/.git/fatal:unabletoaccess'https://github.com/ohmyzsh/ohmyzsh.git/':gnutls_handshake()......
  • git pull https Received HTTP code 504 from proxy after CONNECT
    我们在服务器上面gitpullcodehub代码的时候会遇到ReceivedHTTPcode504fromproxyafterCONNECT,这个报错多数是因为代理配置的问题。 从以下两个方向进行排查: 1.确认服务器/虚拟机是否配置了全局代理。 检查/etc/profile中是否配置了代理:http_proxy和https_proxy......