Welcome! Log In Create A New Profile

Advanced

0.6.38 proxy_redirect не срабатывает

Anonymous User
September 17, 2009 09:10AM
Не совсем понятно почему, но вроде не срабатывает proxy_redirect
Судя по конфигу должно же вроде переписать.

nginx version: nginx/0.6.38
built by gcc 4.1.2 20080704 (Red Hat 4.1.2-44)
configure arguments: --user=nginx --group=nginx --prefix=/usr/share/nginx --sbin-path=/usr/sbin/nginx --conf-path=/etc/nginx/nginx.conf --error-log-path=/var/log/nginx/error.log --http-log-path=/var/log/nginx/access.log --http-client-body-temp-path=/var/lib/nginx/tmp/client_body --http-proxy-temp-path=/var/lib/nginx/tmp/proxy --http-fastcgi-temp-path=/var/lib/nginx/tmp/fastcgi --pid-path=/var/run/nginx.pid --lock-path=/var/lock/subsys/nginx --with-http_ssl_module --with-http_realip_module --with-http_addition_module --with-http_sub_module --with-http_dav_module --with-http_flv_module --with-http_gzip_static_module --with-http_stub_status_module --with-http_perl_module --with-mail --with-mail_ssl_module --with-cc-opt='-O2 -g -pipe -Wall -Wp,-D_FORTIFY_SOURCE=2 -fexceptions -fstack-protector --param=ssp-buffer-size=4 -m64 -mtune=generic' --add-module=/builddir/build/BUILD/nginx-0.6.38/nginx-upstream-fair

server {
listen somehost:80;
#access_log off;
location / {
proxy_set_header Host $host;
proxy_set_header X-Real-IP $remote_addr;
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
proxy_redirect http://somehost:18000/ http://$host/;
proxy_pass http://somehost:18000/;
}
error_page 500 502 503 504 /50x.html;
location = /50x.html {
root html;
}
include conf.d/nginx-status.conf;
}

--17:01:09-- http://somename/forum
Resolving somename... somehost
Connecting to somename|somehost|:80... connected.
HTTP request sent, awaiting response...
HTTP/1.1 301 Moved Permanently
Server: nginx/0.6.38
Date: Thu, 17 Sep 2009 13:01:09 GMT
Content-Type: text/html; charset=iso-8859-1
Connection: close
Location: http://somename:18000/forum/
Location: http://somename:18000/forum/ [following]
--17:01:09-- http://somename:18000/forum/
Connecting to somename|somehost|:18000... connected.
HTTP request sent, awaiting response...
HTTP/1.1 200 OK
Date: Thu, 17 Sep 2009 13:01:09 GMT
Server: Apache
Cache-Control: private, pre-check=0, post-check=0, max-age=0
Expires: 0
Pragma: no-cache
X-Powered-By: PHP/5.2.9
Set-Cookie: phpbb2mysql_data=a%3A2%3A%7Bs%3A11%3A%22autologinid%22%3Bs%3A0%3A%22%22%3Bs%3A6%3A%22userid%22%3Bi%3A-1%3B%7D; expires=Fri, 17-Sep-2010 13:01:09 GMT; path=/
Set-Cookie: phpbb2mysql_sid=f19fb7c530519378f52dffd5eeeac24a; path=/
Keep-Alive: timeout=15, max=100
Connection: Keep-Alive
Content-Type: text/html
Length: unspecified [text/html]
200 OK
Subject Author Posted

0.6.38 proxy_redirect не срабатывает

Anonymous User September 17, 2009 09:10AM

Re: 0.6.38 proxy_redirect не срабатывает

Ivan Kovalenko September 18, 2009 03:52AM

Re: 0.6.38 proxy_redirect не срабатывает

Ivan Kovalenko September 18, 2009 11:24AM

Re: 0.6.38 proxy_redirect не срабатывает

col February 16, 2011 07:51PM



Sorry, only registered users may post in this forum.

Click here to login

Online Users

Guests: 203
Record Number of Users: 8 on April 13, 2023
Record Number of Guests: 421 on December 02, 2018
Powered by nginx      Powered by FreeBSD      PHP Powered      Powered by MariaDB      ipv6 ready