Is there any work around connecting Gitlab-runner runing in docker-container behind Corporate network?

541 Views Asked by At

I spent weeks trying to connect GitLab-Runner running in the docker container behind the corporate network. I try docker run --add-host<IP> to add the host IP to /etc/hosts in my container, but I can't register my Runner. I am using Cntlm Authentication Proxy Configuration for the proxy

ERROR: Registering runner....failed  runner=xxxxxxxxxxxxxxx status=couldn't execute POST 
against https://git.scsops.dev/api/v4/runner: POST "https://git.scsops.dev/api/v4/runner": 
proxyconnect TCP: dial TCP 127.0.0.1:3128: connect: connection refused 
PANIC: Failed to register the runner

Please I need help, Thank you in advance.

1

There are 1 best solutions below

0
On

I would suggest following the steps in this link this will pass proxy information to containers automatically: https://docs.docker.com/network/proxy/