root not recognized

Sean Allen sean at monkeysnatchbanana.com
Thu Jan 1 01:56:33 MSK 2009


ok, well better put on root is recognized, a second isnt.

have this setup ( lots of snipping here... )

root /some/path;
....

location /
{
   if ( -f /tmp/.maintenance )
   {
     set $site_maintenance 1;
   }

   if ( $site_maintenance )
   {
     root /maintenance/path;
     rewrite (.*) /maintenance/index.html;
   }
}

problem is... the rewrite works just fine but its trying to serve

/some/path/maintenance/index.html
instead of
/maintenance/path/maintenance/index.html

any idea why?







More information about the nginx mailing list