I have tried to copy a json file from a Docker container to a local drive path on Windows machine as shown below:
docker cp <my-container-name>:/var/lib/docker/containers/123abc-json.log C:\log
docker cp <my-container-name>:/var/lib/docker/containers/123abc-json.log C:\log123abc-json.log
I also tried these commands using container_id:
docker cp <my-container-ID>:/var/lib/docker/containers/123abc-json.log C:\log
docker cp <my-container-ID>:/var/lib/docker/containers/123abc-json.log C:\log123abc-json.log
But I get "Error: No such container:path: :/var/lib/docker/containers/123abc/123abc-json.log" error. So, what is the problem?
question from:
https://stackoverflow.com/questions/66055244/docker-error-no-such-containerpath-while-trying-to-copy-to-local-drive 与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…