Meaningless Drivel is fun!
The moose likes JBoss/WildFly and the fly likes Application folder outside JBoss Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Products » JBoss/WildFly
Bookmark "Application folder outside JBoss" Watch "Application folder outside JBoss" New topic

Application folder outside JBoss

Ganesh Sundaresan
Ranch Hand

Joined: Feb 09, 2006
Posts: 36

Can I place my application folder outside JBoss and give a context to it?
This can be done in Tomcat by setting up context path in server.xml

For Ex:

<Context path="" docBase="/export/home/user/test/" debug="0" ></Context>
while the server will be in /appl/tomcat/..

Can anyone help me how to do this in Jboss?
Should all application be deployed under /default/deploy only ?

Thanks in Advance

Thanks, Ganesh
SJCP (95%), SCWCD (75%), SCDJWS (Planning to take....)
Jaikiran Pai

Joined: Jul 20, 2005
Posts: 10441

Check out the file jboss-service.xml present in the %JBOSS_HOME%/server/default/conf directory. This file contains the following description:

<!-- URLs are comma separated and resolve relative to the server home URL
unless the given path is absolute. If the URL ends in "/" it is
considered a collection and scanned, otherwise it is simply deployed;
this follows RFC2518 convention and allows discrimination between
collections and directories that are simply unpacked archives.

URLs may be local (file or remote (http . Scanning is supported
for remote URLs but unpacked deployment units are not.

Example URLs:
scans ${jboss.server.url}/deploy/, which is local or remote
depending on the URL used to boot the server
scans ${jboss.server.home)/deploy, which is always local
deploy myapp.ear from a local location
scans the specified directory
deploys myapp.ear from a remote location
scans the specified WebDAV location
<attribute name="URLs">

This comment explains how to deploy a application which is outside the jboss directory. Try it out.
[ July 13, 2006: Message edited by: jaikiran pai ]

[My Blog] [JavaRanch Journal]
Ganesh Sundaresan
Ranch Hand

Joined: Feb 09, 2006
Posts: 36
Thanks buddy its working!!!
I agree. Here's the link:
subject: Application folder outside JBoss
It's not a secret anymore!