0

I'm using WSO2 API Manager. I have fronted API Manager(tomcat) with an Apache HTTP Server.

For the URL api.abc.xyz.lk a public IP has been assigned. For that public IP a local IP which is 192.168.6.162 has been assigned. I have added a virtual-host to redirect all the http://api.abc.xyz.lk to http://192.168.6.162:9763/store.

What I'm trying to do here is redirect all the http://api.abc.xyz.lk requests to http://192.168.6.162:9763/store.

Below is the virtual-host block I use.

<Virtualhost *:80>
        ServerName api.abc.xyz.lk
        ServerAlias api.abc.xyz.lk
        ProxyPreserveHost On
        ProxyRequests Off

        ProxyPass /  http://192.168.6.162:9763/store
        ProxyPassReverse /  http://192.168.6.162:9763/store

</Virtualhost>

The problem is

the URL that works is as below

http://api.abc.xyz.lk:9763/store

But actually what I want is

http://api.abc.xyz.lk

How can I fix this?

Techie
  • 44,706
  • 42
  • 157
  • 243

1 Answers1

-1

you need to modify this proxy pass

 ProxyPass /store  http://192.168.6.162:9763/store
 ProxyPassReverse /store  http://192.168.6.162:9763/store

this will do the trick..

make sure to enable the proxy ports in server, you can configure proxy ports by editing "catalina-server.xml" in $UES_HOME/repository/conf/tomcat/catalina-server.xml

Dakshika
  • 1,694
  • 1
  • 14
  • 18
  • If I so that http://api.abc.xyz.lk/store will be redirected to http://192.168.6.162:9763/store. But what I want is http://api.abc.xyz.lk to http://192.168.6.162:9763/store – Techie May 31 '14 at 13:12