I recently setup docker-machine on my windows development desktop and docker engine on our build repository machine in the task of integrating docker into our build process. I setup a private repository and have been struggling with connecting to it from the windows machine docker client. After much struggling I found the line I had glossed over in the documentation on insecure private registries:
- Repeat this configuration on every Engine host that wants to access your registry.
However, how to do this on the boot2docker default machine that was created was not clear and none of the documentation included the correct location of the files.
After parsing the service script I come up with the following steps for setting up an insecure private registry in docker machine default boot2docker instance:
Can these or any more canonical instructions be added to the Docker Machine documentation?
To accomplish this in docker-machine add --engine-insecure-registry hostname:port
to your docker-machine create
command.
My point was for a docker machine that already existed, not for when creating a new machine.
You can also change /etc/docker/daemon.json
on docker-machine
:
{"insecure-registries":["docker-machine:5000"]}
Don't forget to restart docker
service:
sudo /etc/init.d/docker restart
@jonl-percsolutions-com I totally agree. It has been most frustrating to hook up Docker with Windows using an existing registry. I'm still trying to connect my doctor registry on another VM with my local Docker.
well, if you're running your docker-machine from boot2docker (the default), you can follow these steps to add the "create extra agrs" on an existing machine
To make sure the changes in /etc/docker/daemon.json work you have to ensure:
Most helpful comment
You can also change
/etc/docker/daemon.json
ondocker-machine
:Don't forget to restart
docker
service: