Squid has a mechanism by which incoming URL's can be passed to an
external program to be rewritten and the reverse proxy subsequently
calls out to the rewritten URL
http://wiki.squid-cache.org/SquidFaq/SquidRedirectors
Is there a way to emulate this from within nginx
Thanks, Yusuf
Is it possible to configure error_log, such a way it only contains
application specific errors? Currently nginx also logs virtual server error
messages like "No such file or directory" and others.
IMHO these messages, as well as access logs, should be contained in a
separate file (per virtual server), and not in the common error_log.
Thanks,
Athan
Hey there nginxers-
Is there a way to use a geoip database with nginx instead of
explicitely listing out all the IP ranges in the nginx.conf?
Something like this:
http://www.maxmind.com/app/country
There is a modeul for apache and lighttpd for this type of stuff.
Any hints or help here? Or shoudl I just script something up to auto
generate the geoip config for nginx from one of these databases?
Thanks!
-- Ezra Zygmuntowicz
-- Founder & Ruby Hacker
-- ez(a)engineyard.com
-- Engine Yard, Serious Rails Hosting
-- (866) 518-YARD (9273)
I would like to use nginx as an open proxy, using regular expressions to
get to any URL.
For example, if I browse through nginx through a URL like:
http://proxy.mydomain.com/hotmail.com
then nginx will proxy to http://hotmail.com
I tried working with the rewrite rule, but the best I could get was
getting it to try and serve me the file
/usr/local/nginx/html/http://hotmail.com.
Can it be done? Can someone steer me in the right direction?
Thanks,
Tony
i installed Wordpress today on nginx and everything seems ok except one
"small" issue, i don't know how to convert the rewrite rules.
So if anybody has any experience or knows how to do it i'd be gratefull
cause they have only Apache examples :(
RewriteEngine On
RewriteBase /
# Rewrite www.domain.com to domain.com
RewriteCond %{HTTP_HOST} ^www\.(.*)
RewriteRule ^(.*) http://%1/$1 [R,L]
#uploaded files
RewriteRule ^(.*)?/?files/(.*) wp-content/blogs.php?file=$2 [L]
RewriteCond %{REQUEST_FILENAME} -f [OR]
RewriteCond %{REQUEST_FILENAME} -d
RewriteRule . - [L]
RewriteRule ^([_0-9a-zA-Z-]+/)?(wp-.*) $2 [L]
RewriteRule ^([_0-9a-zA-Z-]+/)?(.*\.php)$ $2 [L]
RewriteRule . index.php [L]
Thank you.
Hi all,
many many thx...
When I tried to
"./configure --with-cc-opt=-I/usr/include/pcre --with-http_perl_module --with-mail",
it's seem "make" and "make install" normally....
but install mailauth.pm (introduced from
http://wiki.codemongers.com/NginxImapAuthenticateWithEmbeddedPerlScript)
Actually, I've only one sendmail with openwebmail server. Due to the
physical harddisk sized full, so I need to add one more sendmail server.
I would divide half of 200 users to new-sendmail (with openwebmail) server,
and the remaining users are keeping in the old ones.
How can check the users names and passwords according to "/etc/shadow"
file...because I don't know our users passwords that are "shadow"-ed...
pls give me a help...(sorry...because I don't know how to write perl and
other programming....)
many many thx again...
regards,
winnie
Hi.
Doing some tests with mod_wsgi, I have found some "problems" with worker
processes usage.
I have worker_processes set to 2 (and I have a Dual Core CUP).
When a WSGI app "quickly" return a chunk of data (and write it at once),
nginx seems to use only one process, serializing all the requestes.
How can I optimize the code so that nginx can use all the worker processes?
I have found that if the WSGI app calls, as an example, sleep(0.01),
then nginx will use all of its worker processes (but this slow down the
response time: 159.52 req/sec vs 2848.19 req/sec)
Thanks Manlio Perillo
Hi,
I'm trying to enable basic authentication for a location like this:
location /admin {
auth_basic "Restricted";
auth_basic_user_file /tmp/.trypass;
index index.php5;
allow 192.168.1.1;
deny all;
}
When I try to connect to this location, if I use:
http://$servername/admin/ and I press Esc two times, nginx give me
out: 401 Authorization Required
If I try to connect to:
http://$servername/admin/index.php5 and I press Esc two times,
nginx allow me the access also if I don't have insert username and
password.
It's my mistake or it's a bug?
Thanks!