How to forward request to another server in PHP?

  • Thread starter Thread starter neldorluothe
  • Start date Start date
N

neldorluothe

Guest
I have two servers, A and B. A is accessible from the internet and can reach B. The internet cannot reach B. B runs mongrel and A runs Apache with php. I want to deploy a rails application but I don't have root privilege of A so that none of the usual route, id est fastcgi, modrails or mongrel on A, is open to me. So I deploy the rails application on B and want A to act as a controller.

When a request is made to A, A is to resend the request to B and intercept the response from B and forward it to the user.

Can this be done in php?
Also, A runs php in safe mode so file_get_contents() fails.
 
Back
Top