How do I Copy files from host to a Docker container?

How can I copy files from the host to the container?

I am trying to build a backup and restore solution for the Docker containers. I have Docker base image that I have created, ubuntu:base, and do not want have to rebuild it each time with a Docker file to add files to it. I want to create a script that runs from the host machine and creates a new container using the ubuntu:base Docker image and then copies files into that container.

Docker
Answer Share
Hosting Companies insights
1411 Web Hosting Reviews A trusted source of genuine reviews. Learn Reviews
2634 Web Hosting Companies Ever-growing pool of web hosting providers. Browse Providers
2216 Web Hosting Coupons Exciting web hosting deals available here Browse Coupons