Docker-compose pull returns exit code 0 and gives no feedback when it fails
Hi,
I was trying to pull some images from a private repository with a problem in .dockercfg and besides it was failing pull command always returns 0 and gives no feedback.
Normal output:
Pulling someservice (company/someservice:latest)...
Output using --verbose
Pulling someservice (company/someservice:latest)...
docker pull <- (u'company/someservice:latest', insecure_registry=False)
docker pull -> u'{"status":"Pulling repository company/someservice"}\r\n{"errorDetail":{"message":"Error: image company/someservice:latest not found"},"error":"Error: image company/someservice:latest not found"}\r\n'
#dibs
It's not clear to me what your issue is. Is docker-compose failing to pull a private image? Or is docker-compose failing to produce proper reasonable output when the image doesn't exist?
Can you post exactly what steps I could take to reproduce the error?
If you don't want to post your private repo, maybe you can use samalba/docker-registry. I found it here http://www.activestate.com/blog/2014/01/deploying-your-own-private-docker-registry
Docker-compose is failing to pull a private image from docker registry because credentials were not configured correctly (normal behaviour). The problem is the output of docker-compose pull. I would have to run it with --verbose and check the output to know if there has been an error.
This was fixed a while ago. Pull errors are now correctly reported and have a non-zero exit status.
Problem still occurs if parallel argument is used. If any of the pulls fail the $lastexitcode and $? report 0 and True respectively.
docker-compose version 1.14.0, build c7bdf9e3
I am somehow getting the same with: docker-compose version 1.15.0, build e12f3b9
I can pull private images correctly, but when I try to pull a non-existent image, I get "No such service", but exit code is 0.