Suresh Payankannur

Monday, August 10, 2015

Docker Tips

Detaching from a docker container without killing it

Use keys Control-Q Control-P to detach from the container
~docker-host> docker attach 
root@3727bb82884: ^Q^P

Copy a text file from host to container

cat my-test-file.txt | docker exec -i 3727bb82884 sh -c 'cat > /root/my-test-file.txt'


Post a Comment

Blog Archive

Scroll To Top