Apache redirect and proxy for APEX
Ome BApr 28 2009 — edited May 5 2009Hi,
I tried doing it with IIS, but with no success. I want to point a domainname (lets's say apex1.com) to my internal running apex instance, using a plsql embedded,
I did the following in the httpd.conf file of the seperate apache server: Apache standard listenes to port 8080. (The Apex server to port 7979) Had the router map the incomming 80 port to 8080.
<VirtualHost *>
# ProxyRequests Off
# ServerAdmin xxxxxx@xxxx.com
ServerName apex1.com
ServerAlias www.apex1.com *.apex1.com
RewriteEngine On
RewriteRule ^/$ /apex/f?p=100:1 [R=301]
ProxyPreserveHost On
ProxyPass /apex http://xxx.xxx.x.xxx:7979/apex
ProxyPassReverse /apex http://xxx.xxx.x.xxx:7979/apex
ProxyPass / http://xxx.xxx.x.xxx:7979/i
ProxyPassReverse /i http://xxx.xxx.x.xxx:7979/i
</VirtualHost>
Is this the right way to go? I probably did something wrong here, because I get the same error everytime.
Restarted the Apache service, but got a '500 Internal Server' error. Now, I checked if I went to http://myip:8080 in my own network I got the same 500 error message, and the url was rewriten to http://myip:8080/apex/f?p=100:1
So, the big thing is now:
1: the rewrite works, but a little bit too well ;)
Even other requests than the onces from apex1.com get rewritten.
2: the proxy part doesn't work. At least, I think the 500 error comes from the non-existence of the /apex directory. Else I would have seen the apex page.
Any thoughts over here?
Would really like to figure this out!
Thanks in advance!
Douwe Pieter