sites-enables and sites-available. If you're familiar with Apache server, those hanges will be done in exactly the same manner.
mkdir -p /usr/local/etc/nginx/sites-{enabled,available}
cd /usr/local/etc/nginx/sites-enabled
ln -s ../sites-available/default.conf
ln -s ../sites-available/default-ssl.conf/usr/local/etc/nginx//usr/local/etc/nginx/sites-available/Library/LaunchDaemons/blog.loc.conf.brew) not creating sites-available nor sites-enabled directories.include methods. Those lines enabling sites-enabled directory to observe every single file into it. So now, you can just create symlink from sites-available in sites-enabled, then do quick reset of your Nginx server and job done.sites-enabled and reload Nginx. But the most important part you're not loosing real file with configuration, so that you can reuse it later.# Configuration for nginx.conf
user www-data staff;
worker_processes 1;
error_log /Library/Logs/nginx/error.log;
events {
worker_connections 1024;
}
http {
include mime.types;
default_type application/octet-stream;
log_format main '$remote_addr - $remote_user [$time_local] "$request" '
'$status $body_bytes_sent "$http_referer" '
'"$http_user_agent" "$http_x_forwarded_for"';
access_log /Library/Logs/nginx/access.log main;
sendfile on;
keepalive_timeout 65;
index index.html index.php;
upstream www-upstream-pool{
server unix:/tmp/php-fpm.sock;
}
include /etc/nginx/conf.d/*.conf;
include /usr/local/etc/nginx/sites-enabled/*.conf;
}cluster.example.com could be named cluster.example.com.conf)Default Nginx installation did not provide those directories, but in few quick steps we'll achieve this, that you can benefit from instantly. (Some example code snippet comes from this gist).
For log files you can use /usr/local/var/log/nginx directory.
Note: If you copy whole configuration below, you have to create log directory, if it doesn't exist yet. To do so, execute this: sudo mkdir -p /Library/Logs/nginx