Im currently using Apache behind an Nginx Proxy which really works fine with one exception:
Apache waits on Port 8888 and only accepts connections from 127.0.0.1 Nginx listens on Port 80 to the real world - servers static content, does load balancing and handles proxy requests to Apache listening on 8888.
The Problem is:
PHP Scripts executed by Apache experience that the server Port is 8888. Scripts like phpmyadmin or nusoap provide redirecting and use this port as part of the redirect url. The Problem is Port 8888 is not visible from the outside thus no connection can be established.
Do you know where the configuration went wrong or how i can force php to think it is working on a port 80 Apache server?
As I cannot pin down the problem I have no clue whether posting my configuration files would help. Maybe its just an option I forgot or stuff.
If you need I can - of coure 开发者_StackOverflow中文版- provide additional config lines.
Thank you very much
Just that everyone knows - here is the answer to the question:
Some douchebag (me) created a virtual host with the servername including the port
ServerName some.server.com:8888
Removing the :8888 removed the errors.
Ty all
I guess you just need to rewrite the Location
header the proxied server sets.
Take a look at http://wiki.nginx.org/HttpProxyModule#proxy_redirect
精彩评论