http { include /etc/nginx/conf.d/.conf; include /etc/nginx/sites-enabled/; }
sudo nginx -c /etc/nginx/nginx.conf sudo nginx -c /etc/nginx/conf.d/myconf.conf
sudo ln -s /etc/nginx/conf.d/myconf.conf /etc/nginx/sites-enabled/myconf.conf
这样,在sites-enabled目录下的myconf.conf实际上是指向conf.d目录下的myconf.conf的符号链接。修改或删除源文件时,在链接目录下同步即可。