I have an alias "/temp" that works ok, but when I add another location block, the alias returns 404.
Working config: http://mysite.com/temp/blank.gif -> OK
server {
# ...
location /temp {
alias /var/www/temp;
}
# ...
}
Error config: http://mysite.com/temp/blank.gif -> 404
server {
# ...
location /temp {
alias /var/www/temp;
}
location ~ \.(?:jpg|png|gif)$ {
expires 30d;
}
# ...
}
Here is my full config: http://pastebin.com/yExq0nMY
How can I solve it?