setting document root in nginx

From WebHostingNeeds.com
Jump to: navigation, search

vi /usr/local/nginx/conf/nginx.conf

Find

location / {
    root   html;
    index  index.html index.htm;
}

Replace with

location / {
    root  /home/static.bizhat.com/public_html/;
    index  index.html index.htm;
}

Replace /home/static.bizhat.com/public_html/ with path to your web site document root.