问题:启动如下,当修改/data/nginx/conf/nginx.conf文件内容,执行docker exec 容器id nginx -s reload,登录容器里面查看是无法生效的,必须要重启容器才行
docker run -d -p 13700:13700 \ -v /data/www:/usr/local/nginx/html \ -v /data/nginx/conf/nginx.conf:/usr/local/nginx/conf/nginx.conf \ -v /data/nginx/conf/conf.d:/usr/local/nginx/conf/vhost \ -v /data/nginx_logs:/usr/local/nginx/logs \ --name www.6vgame.com \ nginx-1.20:v1
如果是修改/data/nginx/conf/conf.d下面的文件,执行docker exec 容器id nginx -s reload是没有问题。注意别踩坑~
标签:容器,映射,local,nginx,usr,conf,data From: https://www.cnblogs.com/lucktomato/p/18193577