Welcome! Log In Create A New Profile

Advanced

Re: What is the difference between alias and root

September 13, 2010 02:44PM
James Matthews Wrote:
-------------------------------------------------------
> I was wondering what the difference was between
> alias and root in the server
> block on nginx was?

There's a subtle difference.

[code]
# This will result in files being searched for in /foo/bar/bar as the full URI is appended.
location /bar {
root /foo/bar;
}

# This will result in files being searched for in /foo/bar as only the URI part after /bar is appended.
location /bar {
alias /foo/bar;
}
[/code]
SubjectAuthorPosted

What is the difference between alias and root

James MatthewsSeptember 12, 2010 12:40AM

Re: What is the difference between alias and root

Igor SysoevSeptember 12, 2010 05:20AM

Re: What is the difference between alias and root

EnsiferousSeptember 13, 2010 02:44PM



Sorry, only registered users may post in this forum.

Click here to login

Online Users

Guests: 88
Record Number of Users: 7 on March 06, 2014
Record Number of Guests: 229 on August 01, 2014
Powered by nginx    Powered by FreeBSD    PHP Powered    Powered by Percona     ipv6 ready