Skip to main content

JMaki with Apache Reverse Proxy

2 replies [Last post]
factoradix
Offline
Joined: 2007-06-29
Points: 0

Hi,

I am using Apache web server as a front to Glassfish.

My Jmaki web app is running on Glassfish. When I attempt to use Apache's reverse proxy (to remove the port numbers out of the url), Jmaki defaults to webroot [http://localhost:8080/] instead of [http://www.domain.com/foo/bar] -

where the mod_proxy is configured:

Order deny,allow
Allow from all

ProxyPass /foo http://www.domain.com:8080
ProxyPassReverse /foo http://www.domain.com:8080

As a result, Jmaki does not find the framework core (glue.js, component.js, etc).
How do I prevent this?

Thanks in advance and congratulations on an amazing framework!

factoradix.

Reply viewing options

Select your preferred way to display the comments and click "Save settings" to activate your changes.
gmurray71
Offline
Joined: 2003-07-31
Points: 0

Hi,

Thank you for your interest in jMaki. We have other deployments that do this and we use the jmaki-webroot property to set the base for where all the resources are loaded.

What you can do is set a context parameter to specify the web root.

jmaki-webroot http://www.domain.com/foo/bar Set the web root to a different URL

As we get similar questions like this I will provide a link here to our global configuration file that has many similar properties you can tweak. Find it here:

https://ajax.dev.java.net/source/browse/ajax/ws/jmaki/shared/src/java/jm...

Please let us know if this doesn't work for you.

-Greg

factoradix
Offline
Joined: 2007-06-29
Points: 0

Thank you, Greg. It works!