docker cp myapp:/var/log/app.log ./app.log

Category: Docker

docker cp myapp:/var/log/app.log ./app.log

Copy a log file out of a running or stopped container

Copies a log file out of a container to the host for inspection.
Looking for more? Search all 7,657 commands — works offline, in English or Spanish, and fixes typos.