Applications deployments location

Latest response


I'm using JBoss EAP 6.4 on RHEL, I have deployed War a EAR applications and I wish to find the location of these applications inside EAP_HOME.

I have tried the following commands without result:

find $EAP_HOME -type f -name "*.war"

find $EAP_HOME -type f -name "*.ear"

What is the location of deployed application inside EAP_HOME ?



Hi Carlos. "EAP_HOME" isn't an actual variable on the system - it's just a replaceable value that the JBoss EAP documentation uses as a placeholder. In places that it is shown, it is intended for you to replace "EAP_HOME" with the path to your JBoss EAP installation. See this section [1] in the Administration and Configuration Guide that explains it in more detail.

If you're on the file system looking to see what WAR or EAR files exist in your JBoss EAP installation, I would first navigate to the installation location. And then run a find command. For example:

$ cd /home/username/eap/jboss-eap-6.4
$ find . -name "*.war"
$ find . -name "*.ear"

Keep in mind that this will only list applications that have been deployed by dropping them into the standalone/deployments/ directory. It will not show applications that have been deployed using the management interfaces. Those are stored differently on the file system and do not have the .war or .ear extension. For this case, you would want to use the management console or management CLI to view applications that have been deployed to this JBoss EAP instance.


Hi Andrea,

Thanks for you response.

I was using EAP_HOME just as a placeholder to let you know where I am running the find command.

I forgot to mention that my installation is on domain mode and the applications have benn deployed using the management console.

Is there a way so get the applications deployed with .war or .ear extension ?

Regards Carlos

Okay, so what I mentioned about the files being stored differently when using the management interfaces applies here for domain mode too. Your files would be stored in the EAP_HOME/domain/data/ directory. For example:

[username@username 5ea8a746712344bfcafe517e3579c3a10bb589] $ pwd
[username@username 5ea8a746712344bfcafe517e3579c3a10bb589] $ ls -la
total 16
drwxrwxr-x. 2 username username 4096 Oct  3 16:13 .
drwxrwxr-x. 3 username username 4096 Oct  3 16:13 ..
-rw-rw-r--. 1 username username 6579 Oct  3 16:13 content

Each deployment is stored in a directory with a unique hash, and the deployment file in that directory is simply called "content". Since it doesn't have the .war or .ear extension, I don't see a way to find it when searching straight from the file system for files with a .war or .ear extension.

Instead, I would recommend connecting to the management CLI to find the deployments. You can use the "deploy" command with no arguments to list all deployments. You could even do this non-interactively if you need to script it. And you could add a grep command to return only .war/.ear if that's what you're looking for. Something like:

$ EAP_HOME/bin/ -c --command="deploy"
$ EAP_HOME/bin/ -c --command="deploy" | grep .war
$ EAP_HOME/bin/ -c --command="deploy" | grep .ear

Does this work for your case?

More and less because I need the war or ear files to copy them to another location for backup reasons.

I see. Yeah this does make it more difficult trying to grab them off of the file system then because they aren't saved under the same file name as when they were added. Though if you are backing up deployments for the purposes of dropping into another EAP installation, you could potentially just back up the entire domain/data/content/ directory. But you'd also need to save the server configuration that points to these files.

And just for future heads up, in JBoss EAP 7.1, you'll be able to save the contents of files/deployments [1] using the management CLI. But unfortunately this is not available for JBoss EAP 6.4.