Where should I set the '--insecure-registry' flag on Mac OS?

I was looking for a way to set --insecure-registry in Docker for Mac. Turned out to be simpler than what I first thought...

In the Docker Desktop application :

  1. click on the Settings icon
  2. select Docker Engine menu entry
  3. add your insecure registries

how to set docker --insecure-registry on mac os x

Don't forget to Apply & Restart and you're ready to go.


You have to set it to Docker Machine's / Boot2Docker profile file: docker-machine ssh <machine name>

/var/lib/boot2docker/profile

EXTRA_ARGS='
--label provider=virtualbox --insecure-registry myregistry:5000

'

And then restart Docker service.

sudo /etc/init.d/docker restart

Tags:

Docker