mkdir /mydata cd /mydata docker run -p 80:80 –name nginx -d nginx:1.10 docker container cp nginx:/etc/nginx . docker stop nginx docker rm nginx mv nginx conf mkdir nginx mv conf/ nginx/ docker run -p 80:80 –name nginx -v /mydata/nginx/html:/usr/share/nginx/html -v /mydata/nginx/logs:/var/log/nginx -v /mydata/nginx/conf/:/etc/nginx -d nginx:1.10