Revert RP changes

master
andryyy 2017-04-25 10:49:38 +02:00
parent 28e0ca022f
commit e4310cafb3
1 changed files with 11 additions and 42 deletions

View File

@ -1,31 +1,4 @@
proxy_cache_path /tmp levels=1:2 keys_zone=sogo:10m inactive=24h max_size=1g;
# use the non-standard X-Forwarded-* headers for WebObjects
map $http_x_forwarded_proto $maybe_real_scheme {
default $http_x_forwarded_proto;
'' $scheme;
}
map $http_x_forwarded_port $maybe_real_port {
default $http_x_forwarded_port;
'' $server_port;
}
map $http_x_forwarded_host $maybe_real_host {
default $http_x_forwarded_host;
'' $host:$real_port;
}
map $realip_remote_addr $real_scheme {
default $scheme;
172.22.1.1 $maybe_real_scheme;
}
map $realip_remote_addr $real_port {
default $server_port;
172.22.1.1 $maybe_real_port;
}
map $realip_remote_addr $real_host {
default $scheme;
172.22.1.1 $maybe_real_host;
}
server {
include /etc/nginx/conf.d/listen_ssl.active;
include /etc/nginx/mime.types;
@ -61,7 +34,7 @@ server {
real_ip_recursive on;
location = /principals/ {
rewrite ^ $real_scheme://$real_host/SOGo/dav;
rewrite ^ $scheme://$host:$server_port/SOGo/dav;
allow all;
}
@ -91,10 +64,6 @@ server {
add_header X-XSS-Protection "1; mode=block";
}
location ^~ /inc/init.sql {
deny all;
}
location ~ /(?:a|A)utodiscover/(?:a|A)utodiscover.xml {
fastcgi_split_path_info ^(.+\.php)(/.+)$;
fastcgi_pass phpfpm:9000;
@ -127,8 +96,8 @@ server {
proxy_set_header x-webobjects-server-protocol HTTP/1.0;
proxy_set_header x-webobjects-remote-host $remote_addr;
proxy_set_header x-webobjects-server-name $server_name;
proxy_set_header x-webobjects-server-url $real_scheme://$real_host;
proxy_set_header x-webobjects-server-port $real_port;
proxy_set_header x-webobjects-server-url $scheme://$host:$server_port;
proxy_set_header x-webobjects-server-port $server_port;
client_body_buffer_size 128k;
client_max_body_size 100m;
}
@ -141,8 +110,8 @@ server {
proxy_set_header x-webobjects-server-protocol HTTP/1.0;
proxy_set_header x-webobjects-remote-host $remote_addr;
proxy_set_header x-webobjects-server-name $server_name;
proxy_set_header x-webobjects-server-url $real_scheme://$real_host;
proxy_set_header x-webobjects-server-port $real_port;
proxy_set_header x-webobjects-server-url $scheme://$host:$server_port;
proxy_set_header x-webobjects-server-port $server_port;
client_body_buffer_size 128k;
client_max_body_size 100m;
break;
@ -214,7 +183,7 @@ server {
real_ip_recursive on;
location = /principals/ {
rewrite ^ $real_scheme://$real_host/SOGo/dav;
rewrite ^ $scheme://$host:$server_port/SOGo/dav;
allow all;
}
@ -280,8 +249,8 @@ server {
proxy_set_header x-webobjects-server-protocol HTTP/1.0;
proxy_set_header x-webobjects-remote-host $remote_addr;
proxy_set_header x-webobjects-server-name $server_name;
proxy_set_header x-webobjects-server-url $real_scheme://$real_host;
proxy_set_header x-webobjects-server-port $real_port;
proxy_set_header x-webobjects-server-url $scheme://$host:$server_port;
proxy_set_header x-webobjects-server-port $server_port;
client_body_buffer_size 128k;
client_max_body_size 100m;
}
@ -294,8 +263,8 @@ server {
proxy_set_header x-webobjects-server-protocol HTTP/1.0;
proxy_set_header x-webobjects-remote-host $remote_addr;
proxy_set_header x-webobjects-server-name $server_name;
proxy_set_header x-webobjects-server-url $real_scheme://$real_host;
proxy_set_header x-webobjects-server-port $real_port;
proxy_set_header x-webobjects-server-url $scheme://$host:$server_port;
proxy_set_header x-webobjects-server-port $server_port;
client_body_buffer_size 128k;
client_max_body_size 100m;
break;
@ -340,4 +309,4 @@ server {
#alias /usr/lib/GNUstep/SOGo/$1.SOGo/Resources/$2;
}
}
}