help with my config

Alex Egg eggie5 at gmail.com
Wed Feb 13 21:21:54 MSK 2008


How does this look?

I updated the '^~' to my location, but I moved the expires to a
different section.

How's this config?

Alex

On Feb 13, 2008 1:32 AM, Igor Sysoev <is at rambler-co.ru> wrote:
>
> On Tue, Feb 12, 2008 at 10:48:52PM -0800, Alex Egg wrote:
>
> > As soon as I add the expires section (at the bottom) accel-redirect
> > for images stops working.
> >
> > Is it apparent why?
> >
> > My config:
> >
> > http://pastie.caboo.se/151398
>
> I have tired of this "if (-f $request_filename)" pattern.
> This became the same ugly pattern as Apache's Auth directives usage in
> .htaccess only and lot of RewriteRule's to compencate inability
> of PHP programmers to work with URIs different from /index.php.
>
> You should use ^~ in "location ^~ /accounts":
>
>     location ^~ /accounts {
>         internal;
>         root /u/apps/asdf/shared;
>     }
>
> And remove the useless "if (-f $request_filename)" in static location:
>
>     location ~* \.(js|css|jpg|jpeg|gif|png|swf)$ {
>         expires      1M;
>     }
>
>
> --
> Igor Sysoev
> http://sysoev.ru/en/
>
>





More information about the nginx mailing list