12

I want to configure Apache web server to use a proxy server, so that all the outbound requests go through this proxy server. Could you please help me how to do this? I tried with Proxifier, but it didn't help me much.

5
  • you want it so that if a client requests a page (not from the proxy) the response goes through the proxy? or if an application / script on the server makes and outbound request for data it goes through the proxy? Commented Jan 24, 2013 at 3:45
  • Yes the second one - when the HTTP Server makes an outbound request, it should go through the proxy Commented Jan 24, 2013 at 3:50
  • what is making the outbound request from apache? A script or are you using mod_proxy? Commented Jan 24, 2013 at 3:58
  • Yes I'm using a mod_proxy. There is a proxy pass rule created which forwards some url patterns to a different domain Commented Jan 24, 2013 at 4:01
  • 1
    Stack Overflow is a site for programming and development questions. This question appears to be off-topic because it is not about programming or development. See What topics can I ask about here in the Help Center. Perhaps Web Applications Stack Exchange, Webmaster Stack Exchange or Unix & Linux Stack Exchange would be a better place to ask. Commented Dec 21, 2017 at 5:25

2 Answers 2

9

If you need to proxy outbound requests, you can use ProxyRemote from mod_proxy http://httpd.apache.org/docs/2.2/mod/mod_proxy.html#proxyremote

ProxyRemote * http://ip.of.proxY.host:port

Sign up to request clarification or add additional context in comments.

Comments

1

If you're using Apache the simpler way is to define a global variable http_proxy. On RedHat like edit /etc/sysconfig/httpd and adjust these two lines to your environment:

export http_proxy="http://proxy:8080/" 
export https_proxy="http://proxy:8080/"

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.