View Apache Run status
Ps-eaf|grep httpd
View Apache Installation Environment
Httpd-v
View Apache network status, including ports, etc.
Netstat-anp|grep httpd
Open httpd.conf
Verify that the proxy module loading is not commented out
LoadModule proxy_module modules/mod_proxy.soloadmodule proxy_http_module modules/mod_proxy_http.so
Add proxy configuration path at end of file
Proxypass/console http://localhost:8080/consoleProxyPass/images Http://localhost:8080/imagesProxyPassreverse/ http://localhost:8080/
Note the last line, for the root path proxy, be sure to add a slash at the end of the port
You can also configure multiple service paths
Proxypass/pbs Http://172.16.64.141:7080/PBSProxyPassreverse/PBS Http://172.16.64.141:7080/PBSProxyPass/geoserver Http://localhost:8080/geoserverProxyPassreverse/geoserver http://localhost:8080/geoserverProxyPass/http:// localhost:9080/proxypassreverse/http://localhost:9080/
The service Proxypass and proxypassreverse for different ports and addresses are best paired, otherwise there will be errors with redirection failures, such as redirection to localhost.
Note: If a service with a different address is called in a Web project, the path is best written as a relative path. The availability of relative path resources can be ensured by proxy completion.
Reference: Apache Reverse proxy configuration
Linux Apache reverse Proxy