Hi all,
I’m trying something that I though should be quite simple but turns out
it isn’t…
I have a rails app and want all static assets with a timestamp query
string to be sent with a custom response header called “User-Expires”,
instead of the regular “expires” directive.
I’m coming from apache, and I’m not sure if proxy_set_header is what I’m
looking for or not.
In any case, I’m using the following code:
And I’m getting the following error:
28514#0: “proxy_set_header” directive is not allowed here
I tried moving it to the top (right under all my other proxy_set_headers
and it didn’t return an error but also did not seem to set the header.
I’m totally confused here - why is it called proxy_set_header when I’m
not even using a proxy - i’m just returning the static asset without
proxying anything to mongrel. Am I totally missing something here?
Thanks
On Wed, Jun 03, 2009 at 05:36:50AM -0400, ehudros2 wrote:
break;
}
And I’m getting the following error:
28514#0: “proxy_set_header” directive is not allowed here
I tried moving it to the top (right under all my other proxy_set_headers and it didn’t return an error but also did not seem to set the header.
I’m totally confused here - why is it called proxy_set_header when I’m not even using a proxy - i’m just returning the static asset without proxying anything to mongrel. Am I totally missing something here?
I do not know why do use proxy_set_header if you are not even using a
proxy.
OMG, add_header…
That’s what’s i’ve been looking for the entire morning. I’ve tried so
many different searches on how to add custom headers - they’ve all lead
me to the proxy_pass_header.
Looks awesome, but seems like I dont have the perl module installed?
I get a "unknown directive “perl_var” error…
I’ve tried searching for the perl module but it seems like the docs are
in russian. Is there a way I can compile it into ngnix?
Then the distros could support a stripped down basic version with
optional modules, and then just have a “module foo;” line or something
in the nginx.conf. I don’t think it would take too much overhead as
it’s only run during startup…
On Sun, Jun 07, 2009 at 03:26:58AM -0700, Michael S. wrote:
I think 0.8.x should introduce pluggable modules.
Then the distros could support a stripped down basic version with
optional modules, and then just have a “module foo;” line or something
in the nginx.conf. I don’t think it would take too much overhead as
it’s only run during startup…
I thought about dynamic loadable modules (and it’s really very
intresting
to me from technical point of view ), however, if I will ever
implement
this, the loading will be allowed only on start, but not on
reconfiguration,
since unloading with removing dependences is complex thing.
Anyway it’s not 0.8.x thing.
Definately. It would be a lot better than having to compile nginx
custom for each module you want. Just a simple .so file or something
that takes effect on a start or restart only still works better.
Somehow doing it via graceful reload would be even better
This way modules can be written and deployed any time.
On Sun, Jun 07, 2009 at 07:58:49AM -0400, ehudros2 wrote:
Thanks for the help guys…
Here’s my configure line:
./configure --sbin-path=/usr/sbin --with-http_ssl_module --conf-path=/etc/nginx --error-log-path=/var/log/nginx/error.log --http-log-path=/var/log/nginx/access.log --with-http_perl_module --prefix=/etc/nginx
I get a ton of “undefined reference” errors when it tries to compile the perl module (like “undefined reference to perl_free' objs/src/http/modules/perl/ngx_http_perl_module.o: In functionngx_http_perl_xs_init’”)
although I do have perl 5.8.8 installed. Do I need perl build headers? How do i install them?
This is a much more difficult task than I originally thought it’d be
Thanks for the help guys…
Here’s my configure line:
./configure --sbin-path=/usr/sbin --with-http_ssl_module
–conf-path=/etc/nginx --error-log-path=/var/log/nginx/error.log
–http-log-path=/var/log/nginx/access.log --with-http_perl_module
–prefix=/etc/nginx
I get a ton of “undefined reference” errors when it tries to compile the
perl module (like “undefined reference to perl_free' objs/src/http/modules/perl/ngx_http_perl_module.o: In function ngx_http_perl_xs_init’”)
although I do have perl 5.8.8 installed. Do I need perl build headers?
How do i install them?
This is a much more difficult task than I originally thought it’d be
Hi guys,
seems like ./configure does not check for perl (I dont see that line and
./configure | grep perl also comes back empty).
So does “grep lperl objs/Makefile”.
Any idea why that is?
I’m really thankful for all your help
Guys, I really feel bad about bumping a second time in 2 days, but I’m
being hammered here for not getting this done
Can someone please throw in his thoughts on why I can’t get the perl
module installed?
On Mon, Jun 08, 2009 at 03:04:47AM -0400, ehudros2 wrote:
Hi guys,
seems like ./configure does not check for perl (I dont see that line and ./configure | grep perl also comes back empty).
So does “grep lperl objs/Makefile”.
Any idea why that is?
I’m really thankful for all your help
Could you show full configure output, including command line ?