docker ps
CONTAINER ID IMAGE COMMAND CREATED STATUS PORTS NAMES63686740b488 tomcat "catalina.sh run" 12 seconds ago Up 11 seconds 0.0.0.0:8080->8080/tcp peaceful_babbage
docker cp xxxx/download/jenkins.war 63686740b488:usr/local/tomcat/webapps/
abhishek@linuxhandbook:~$ sudo docker psCONTAINER ID IMAGE COMMAND CREATED STATUSPORTS NAMES8353c6f43fba 775349758637 "bash" 8 seconds ago Up 7seconds ubu_container
#Run the docker image in detached mode$docker run -it -d test:latest bash
$ docker psCONTAINER ID IMAGE COMMANDa6c1ff6348f4 test:latest "bash"
#Copy file from host to containersudo docker cp file.txt a6c1ff6348f4:/tmp
#Copy the file from container to hostdocker cp test:/tmp/file.txt /home
# mount the current [project] directory as read onlydocker run --name my_container -v $(pwd):/mnt/application:ro -itd my_image /bin/bash# copy the missing project files from the mounted directorydocker exec -it my_container /bin/bash -c 'cp -rnT /mnt/application $HOME/application'# interactively use the containerdocker attach my_container