[jboss-user] [Beginner's Corner] - Re: How to get JBoss and Apache to work together

rbrtfreund do-not-reply at jboss.com
Fri Dec 11 19:34:08 EST 2009


In short.. yes... your files go in the cfusion.war

Generally, you place your files in the directory (.war) you are creating. When you place a .war in jboss/server/default/ it will be registered as an application and accessible at the location unless you specify otherwise in the jboss-web.xml file. Every application has WEB-INF which is a standard java web application deployment descriptor folder where inside you'll have your web.xml. So your application context (in your case folder) would be http://localhost/cfusion. Now that gets us to the file. Your individual pages exist inside the .war which is your application on the server. So you would have a setup like:
>cfusion.war
>>WEB-INF
>>CFIDE
>>META-INF
>>helloworld.cfm

Any file you want to read should be in the application context. You generally don't need to and shouldn't point your apache docRoot at this folder. By forwarding to jboss, jboss-web is more then capable of handling the request. The DocRoot in the case of any app deployed in Jboss just won't be used - instead the application your working with will be targeted which is probably the desired behavior.


So in your case here's how your setup should work.

Apache with the proxy_mods installed. The directoryRoot of apache is irrelevant because you are not using it. Instead you are forwarding these requests onto your application. Your j2EE Web application is the cfusion.war. This gets targeted and picked up by requests to http://localhost because in your jboss-web.xml you told it to act on the root with : <context-root>/</context-root>.

At this point your coldfusion server application is live at http://localhost. Now.. the actual Website Applications you intend to build will live inside this main cfusion.war directory... which is providing you coldfusion inside a standard J2EE application server. Place all your coldfusion files in the cfusion.war directory or subdirectory's. 

Hope that helps!



View the original post : http://www.jboss.org/index.html?module=bb&op=viewtopic&p=4270315#4270315

Reply to the post : http://www.jboss.org/index.html?module=bb&op=posting&mode=reply&p=4270315



More information about the jboss-user mailing list