服务器上的registry
已经启动了
看了下文档要使用Insecure Registry
要添加DOCKER_OPTS="--insecure-registry myregistrydomain.com:5000"
但没有找到/etc/sysconfig/docker
这文件,所以就在docker.service
里添加了如下(centos7好像没/etc/sysconfig/docker
这文件了)
ExecStart=/usr/bin/docker daemon --registry-mirror=https://187wuopo.mirror.aliyuncs.com --insecure-registry 121.42.217.35:5000 -H fd://
sudo docker push 121.42.217.35:5000/php:7
报错:Get https://121.42.217.35:5000/v1/_ping: tls: oversized record received with length 20527
感觉是DOCKER_OPTS
放错地方了...
習慣沉默2017-04-24 16:02:03
may be /etc/default/docker
这个地址?修改/添加DOCKER_OPTS
as follows:
DOCKER_OPTS="--insecure-registry 121.42.217.35:5000"
漂亮男人2017-04-24 16:02:03
docker issue 14513: http://www.artificialworlds.n...
解法:
# create docker override config: "/etc/systemd/system/docker.service.d/override.conf"
# add the settings below
[Service]
ExecStart=
ExecStart=/usr/bin/docker daemon -H fd:// --insecure-registry=192.168.1.201:5000
# restart docker service
systemctl stop docker
systemctl start docker
# start to pull images from private docker registry
docker pull 192.168.1.201:5000/puya_mbk_centos67