I'm running a jenkins server on my DC/OS, and also got a private registry in the same DC.
the private registry does not have any ssl certificate and to push images from my mac I used the following command
ocker-machine ssh default "echo $'EXTRA_ARGS=\"--insecure-registry \"' | sudo tee -a /var/lib/boot2docker/profile && sudo /etc/init.d/docker restart"
so it worked fine.
on jenkins I tried to set the DOCKER_OPTS see https://docs.docker.com/registry/insecure/
but then I figured that the build is actually running on an agent, so how do I configure the jenkins worker to trust my private registry?
If you installed the Jenkins from the Mesosphere Universe, then the default Jenkins agent container uses docker-in-docker.
See the DC/OS Jenkins service guide for how to configure docker run parameters to add environment variables: https://docs.mesosphere.com/1.8/usage/service-guides/jenkins/advanced-configuration/