当我尝试在私有注册表中推送和签名图像时,我收到此错误。重现的步骤:
部署注册表:
$ docker run -d -p 5000:5000 --restart=always --name registry registry:2
标记图片:
$ docker tag hello-world localhost:5000/hello-world:latest
启用内容信任:
$ export DOCKER_CONTENT_TRUST=1
推送注册表:
$ docker push localhost:5000/hello-world:latest
=> The push refers to a repository [localhost:5000/hello-world]
a02596fdd012: Pushed
latest: digest: sha256:a18ed77532f6d6781500db650194e0f9396ba5f05f8b50d4046b294ae5f83aa4 size: 524
Signing and pushing trust metadata
tls: oversized record received with length 20527
答案 0 :(得分:2)
您的注册表不接受https连接,因为它位于http上。忘记 xlWorkSheet.Range["$A$1"].Select();
Range range = xlWorkSheet.get_Range("G2,G50");
Validation v = range.Validation;
// you might want to delete validation first
// v.Delete();
v.Add(XlDVType.xlValidateList, XlDVAlertStyle.xlValidAlertStop, XlFormatConditionOperator.xlBetween, "=$AM2:$AM50", System.Reflection.Missing.Value);
// some other useful stuff for you
// v.ErrorMessage = "You need to fill in a value from the validation list.";
// v.InCellDropdown = true;
并使用docker守护程序配置中的DOCKER_CONTENT_TRUST
守护程序选项将注册表添加为不安全的注册表,然后重新启动docker
答案 1 :(得分:0)
我只有在设置内容信任服务器以指向运行公证服务器时才解决此问题。
导出DOCKER_CONTENT_TRUST_SERVER = https://localhost:4443
答案 2 :(得分:0)
如果您正在使用代理服务器下拉图像,请查看代理服务器配置。特别是,请确保https代理URL不包含“ https”字符串,例如:
Environment="HTTPS_PROXY=https://proxy.url:8080/" => Environment="HTTPS_PROXY=http://proxy.url:8080/"
有关更完整的说明,请参见here