Equivalent of Apache's SetEnv Variable

Grzegorz Nosek grzegorz.nosek at gmail.com
Thu Aug 5 12:10:19 MSD 2010


On Thu, Aug 05, 2010 at 12:35:13AM -0700, Michael Shadle wrote:
> I think this would be more appropriate, personally:
> 
> type application/x-httpd-php {
>    fastcgi_pass ...; # etc.
> }
> 
> it's not really a location, and needing to use the "@" for prefixing a
> named location... all that seems like a hack bolted on to the existing
> framework.

Sure it is, it was the simplest thing that could possibly work. An
upstream submission would have to be much cleaner, of course.

> it'd be nice to see
> 
> type text/plain {
>    expires max;
> }
> 
> type text/css {
>    expires max;
> }
> 
> ... etc ...
> 
> currently the same thing is a location block with
> js|css|ico|gif|jpg|jpeg etc... one single line to max the headers
> would be interesting to fill in. and not have it be conflicting with
> existing locations.

I like your proposed syntax much better, actually.

Best regards,
 Grzegorz Nosek



More information about the nginx mailing list