Use insecure-registry in gitlab-runner


I was able to use a local insecure registry in our internal ip-based gitlab. But it seems that the docker daemon used by dind in the runner does not have the insecure-registry flag set. Also, where do I store the the self-signed tls cert?

Edit: Add build test screen

Edit2: sample .gitlab.yml

image: docker:latest
  - docker:dind
  - build
  - docker login -u gitlab-ci-token -p $CI_BUILD_TOKEN
  stage: build
    - docker build --pull -t $CONTAINER_TEST_IMAGE .
    - docker push $CONTAINER_TEST_IMAGE
1 Like

I’ve opened an Issue on a similar problem (
We are using our internal gitlab registry with a self signed certificat and it don’t work.
Manually running the docker image and mounting the /etc/docker/certs.d directory from the host where I’ve put the public certificate it will work. I’ve configured the volumes to mount the directory to the image but it only mount it on the docker image not on the docker:dind (that is just a service).
It would be nice to being able to pass some options or mount a volume inside the service image too (I’m not really good at docker, just started to use it so it’s possible I’m missing something on the configuration side).