Nginx-ru mailing list archive (nginx-ru@sysoev.ru)
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Редирект на https. Глюки или я глючу?
- To: nginx-ru@xxxxxxxxx
- Subject: Редирект на https. Глюки или я глючу?
- From: "sergeyt" <nginx-forum@xxxxxxxx>
- Date: Mon, 02 May 2011 15:16:56 -0400
- Dkim-signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=mickey.jlkhosting.com; s=x; h=Date:Sender:From:Message-ID:Content-Transfer-Encoding:Content-Type:Subject:To; bh=9NIsJTIDbFDs8O9zRRUZ6lTX/n5yDjSxPKmrlTLg3II=; b=iymtnRPh1rWObRCweF7DKQghuBiHgnEcD5LCMX0WCJYBULLoL8+kcQ05SHfLM+LpONsEv+CqXrPjtBu1+SNdcAMQbQRyONCO19dMhh8/1Z7uyio1jtdTyOf/d4uRCAho;
Хотел организовать редирект всех
запросов с http://mydomain.ru:9111 на
https://mydomain.ru:9111 , в FireFox'e все супер..
редиректы работают, но в IE (8-ой версии)
существуют какие-то глюки, например,
при пост запросе ссылка перекидывается
на http://mydomain.ru:9111 и после 1-2 нажатий
обновить страницу (f5) преобразуется в
нормальный вид - https://mydomain:9111 ... может
дело в конфиге:
-----------------------------------------------------------------------------------------
server {
listen 9111;
keepalive_timeout 70;
#->
keepalive_requests 150;
#<-
server_name bitrix;
ssl on;
ssl_certificate /etc/nginx/ssl/cert.pem;
ssl_certificate_key /etc/nginx/ssl/cert.key;
ssl_session_cache shared:SSL:10m;
ssl_session_timeout 10m;
error_page 497 https://mydomain.ru:9111$uri;
server_name_in_redirect off;
access_log /var/log/nginx/access.log main;
index index.php;
error_page 500 502 503 504 /500.html;
error_page 404 = /404.php;
proxy_set_header X-Real-IP $remote_addr;
proxy_set_header X-Forwarded-For
$proxy_add_x_forwarded_for;
proxy_set_header Host $host:9111;
client_max_body_size 1024M;
client_body_buffer_size 4M;
proxy_set_header HTTPS YES;
root /home/bitrix/www;
location / { expires 3d;
if ($request_method = OPTIONS ) {
proxy_pass
http://127.0.0.1:8888;
}
if ($request_method = PROPFIND ) {
proxy_pass
http://127.0.0.1:8888;
}
if ($request_method = PROPPATCH ) {
proxy_pass
http://127.0.0.1:8888;
}
if ($request_method = MKCOL ) {
proxy_pass
http://127.0.0.1:8888;
}
if ($request_method = COPY ) {
proxy_pass
http://127.0.0.1:8888;
}
if ($request_method = MOVE ) {
proxy_pass
http://127.0.0.1:8888;
}
if ($request_method = LOCK ) {
proxy_pass
http://127.0.0.1:8888;
}
if ($request_method = UNLOCK ) {
proxy_pass
http://127.0.0.1:8888;
}
if ($request_method = PUT ) {
proxy_pass
http://127.0.0.1:8888;
}
}
location ~
^(/extranet/docs|/docs|/workgroups|/company/profile|/bitrix/tools|/company/personal/user).*/$
{
proxy_pass http://127.0.0.1:8888;
}
location ~
^(/extranet/docs|/docs|/workgroups|/company/profile|/bitrix/tools|/company/personal/user)
{
if (-d $request_filename) {
rewrite ^(.*)(/*)$ $1/ last;
}
proxy_pass http://127.0.0.1:8888;
}
location ~ ^(/bitrix/html_pages)
{
root /home/bitrix/www;
index index@.html;
if (!-f $request_filename)
{
rewrite
^/bitrix/html_pages(.*)@(.*)\.html$ $1.php?$2 break;
rewrite ^/bitrix/html_pages(.*)\.html$
$1\.php break;
proxy_pass http://127.0.0.1:8888;
}
}
location ~ \.php$ {
root /home/bitrix/www;
if ($request_method = POST ) {
break;
proxy_pass
http://127.0.0.1:8888;
}
if ($http_cookie !~ "PHPSESSID=" ) {
rewrite ^(.*)\.php$
/bitrix/html_pages$1@$args.html? last;
}
proxy_pass http://127.0.0.1:8888;
}
location ~ /$ {
root /home/bitrix/www;
if ($request_method = POST ) {
break;
proxy_pass
http://127.0.0.1:8888;
}
if ($http_cookie !~ "PHPSESSID=" ) {
rewrite ^(.*)/$
/bitrix/html_pages$1/index@$args.html? last;
}
proxy_pass http://127.0.0.1:8888;
}
location ~ (/|\.php|\.asmx)$ {
proxy_pass http://127.0.0.1:8888;
}
location ~ /\.ht {
deny all;
}
location ~ /favicon.ico {
proxy_pass http://127.0.0.1:8888;
}
location ~ ^(/bitrixsetup\.php)$ {
proxy_pass http://127.0.0.1:8888;
proxy_buffering off;
}
}
}
-----------------------------------------------------------------------------------------
Posted at Nginx Forum:
http://forum.nginx.org/read.php?21,195034,195034#msg-195034
_______________________________________________
nginx-ru mailing list
nginx-ru@xxxxxxxxx
http://nginx.org/mailman/listinfo/nginx-ru
|