Hi All,
I have a server (Server A) which is CentOS 6 running nginx. This server is just acting as a proxy server.
Now there is a remote server (Server B) over at our supplier. This server is running apache and php.
Server B hosts: www.target.tld/subdirA (PHP site)
Server A is the proxy for this: www.mycompanysite.tld/subdirA (nginx php-fpm proxy_pass)
I want to show to content of Server B in subdirA in on Server A subdirA. This works fine until I request the php file itself.
withouth requesting the index.php it shows the site without any problems, but when I fill in a form and return to the index.php using a POST I get a "File not Found".
Its like nginx thinks the file (when posting data to itself) is hosted on server A (my own nginx proxy).
I cannot get this fixed.
---
Already tried the following:
location ~ ^/~([^/]+)/(.+\.php)$ {
fastcgi_pass 127.0.0.1:9000;
fastcgi_index index.php;
fastcgi_param SCRIPT_FILENAME /srv/website$fastcgi_script_name;
include /etc/nginx/fastcgi_params;
}
location ~ \.php$ {
fastcgi_pass 127.0.0.1:9000;
fastcgi_index index.php;
fastcgi_param SCRIPT_FILENAME /srv/website$fastcgi_script_name;
include /etc/nginx/fastcgi_params;
}
and
location /subdirA { proxy_pass http://serverB.tld/subdirA; }
Edited 1 time(s). Last edit at 01/15/2013 07:56AM by wtfawk.