This tutorial shows how to copy a file from the host to a Docker container.
docker cp file CONTAINER:/PATH
Here an example showing copying a file called test to the tmp directory named apache running in docker.
The script first list the files in the host, copy the file to the containerthe. Then it connects to the container
root@ubuntu:/tmp# ls test root@ubuntu:/tmp# docker cp test apache:/tmp root@ubuntu:/tmp# docker exec -it apache bash [root@574a0820f181 /]# cd /tmp/ [root@574a0820f181 tmp]# ls test