drone-docker
drone-docker copied to clipboard
NO_PROXY not being heeded
When configuring HTTP_PROXY and HTTPS_PROXY while also configuring NO_PROXY, drone-docker fails to authenticate against the docker registry. I've reproduced this against both DTR in my local environment and Docker Hub on the internet (index.docker.com)
To reproduce, use the following .drone.yml and replace the variables with your own credentials and repo.
pipeline:
publish:
image: plugins/docker
environment:
- HTTP_PROXY=example.com
- HTTPS_PROXY=example.com
- NO_PROXY=index.docker.com
username: $your_username
password: $your_password
repo: $your_repo
I'd expect this to not use the proxy for index.docker.com. However, authentication fails as follows which indicates that it is attempting to use the proxy setting:
+ /usr/local/bin/dockerd -g /var/lib/docker0s
2time="2018-06-22T02:37:41Z" level=fatal msg="Error authenticating: exit status 1"
This was discussed first on reddit but nobody had a solution so I'm creating a ticket for investigation. If I find a solution (workaround or patch) before this gets looked at I'll be sure to update this issue 😸
Primary this indicates to me that it fails to authenticate.
You would think so, but if you remove the environment section, then the authentication succeeds.
It seems this is happening to us as well. I'll dig into this in the next days and let you know when I get any new information.
/edit: I ended up working around the issue so I can not definitly verify it :-(