Closed ericzbeard closed 12 months ago
Repro
import docker
client = docker.from_env()
client.containers.run('alpine:2.7', 'echo hello world')
b'hello world\n'
client.containers.run('alpine:2.7', 'echo hello world', auto_remove=True)
<Trace removed>
HTTPError: 404
client.containers.run('alpine:2.7', 'echo hello world', remove=True)
b'hello world\n'
Some details related to the docker-py
package:
https://github.com/docker/docker-py/issues/2684
https://github.com/docker/docker-py/issues/2503
In
codegen.py
,auto_remove
is set toTrue
when running the pip install command. This results in the process exiting before stderr can be read, so for example you see something like this:If you change it to
auto_remove=False
, you get a useful error message:(The fix for this particular error is to run
docker image prune
)