One: dockerfile, put Dockerfile and myfolder in one directory:
FROM httpd:2.4 COPY ./myfolder/ /usr/local/apache2/htdocs/ WORKDIR /usr/local/apache2/ RUN chown -R daemon:daemon htdocs &&\ chmod -R 755 htdocs
Two: Generate an image:
docker build -t imageName . (note the dot at the end)
Three: httpd opens port 80. Execute the container:
docker run -p 9009 : 80 imageName
Four: You can view the contents of the mirror :
docker ps | grep "9009" find the container ID is XXXID
docker exec -it XXXID sh
Then you can see what's inside.