But drone-runner is running on one worker and I’ve tested connectivity on this host as you can see in the next test. (running netcat inside a docker image on the same host)
docker@worker3:~$ docker ps
CONTAINER ID IMAGE COMMAND CREATED STATUS PORTS NAMES
00e263f034e9 drone/drone-runner-docker:latest "/bin/drone-runner-d…" About an hour ago Up About an hour 3000/tcp web-cicd_drone-runner.1.z1cxihkgpgisoy4ybp1rxt7lj
967ef99bd06f portainer/agent:latest "./agent" 2 hours ago Up 2 hours web-base_agent.wr7akdyft1cwj55mtcnasqwmc.tkmmzfi3c1wz78qi6s8zwbkyd
docker@worker3:~$ docker run -t --rm --network=net-public subfuzion/netcat -vz nexus 8082
Connection to nexus 8082 port [tcp/*] succeeded!
First it looks like your registry is using http (not https) which means you need to configure your Docker daemon to allow insecure registry connections.
Second I can see you are using custom dns to connect to the registry, which usually requires special configuration (attaching containers to the same network, etc). Have you confirmed you can connect to the nexus hostname from inside the Runner container?
Lastly see the Troubleshooting section of How to pull private images with 1.0, which enumerates a list of information we need in order to help triage. All information in this list should be provided; it makes our job way easier and saves us time
I’ve reviewed the host VM’s /etc/resolv.conf and they had a search otherdomain.org which has an existing service nexus.otherdomain.org in the IP 10.71.208.193, after removed the “search” entry the resolution is being done ok.
After this fix and with correct credentials now I’m able to use my private registry images.
I realized that drone-runner creates containers which are resolving names with my external laptop /etc/hosts ( I added to browse through traefik) , and not by its internal IP as I expect
If I ping inside other container attached to the same network it resolves with the internal
docker@manager1:~$ docker run --rm -it --network=net-public alpine ping -c 2 nexus
PING nexus (10.0.0.207): 56 data bytes
64 bytes from 10.0.0.207: seq=0 ttl=64 time=0.187 ms
64 bytes from 10.0.0.207: seq=1 ttl=64 time=0.192 ms
--- nexus ping statistics ---
2 packets transmitted, 2 packets received, 0% packet loss
round-trip min/avg/max = 0.187/0.189/0.192 ms
docker@manager1:~$ docker run --rm -it --network=net-public alpine ping -c 2 minio
PING minio (10.0.0.151): 56 data bytes
64 bytes from 10.0.0.151: seq=0 ttl=64 time=0.070 ms
64 bytes from 10.0.0.151: seq=1 ttl=64 time=0.188 ms
--- minio ping statistics ---
2 packets transmitted, 2 packets received, 0% packet loss
round-trip min/avg/max = 0.070/0.129/0.188 ms
It seems like drone-runner creates containers but is not attaching containers to the same network that it is (net-public) as you can see in the service definition.