10

I used the jboss web console http://xxxxx:9990/console/App.html#deployments to successfully deploy my web app. And I can visit the page in this app.

But I can not find my war file under jboss-eap-6.2/standalone/deployments. Where does jboss backend put the war file?

thanks.

shonky linux user
  • 6,131
  • 4
  • 46
  • 73
liam xu
  • 2,892
  • 10
  • 42
  • 65

1 Answers1

16

Under the base directory of your jboss instance will be /data and /tmp folders corresponding to ${jboss.server.data.dir} and ${jboss.server.tmp.dir}. These folders are created by jboss when it first starts.

The uploaded war is stored in a file called /data/content/ad/xxxxx/content where xxxxx is some temporary directory name.

When JBoss is running the exploded contents of your war will be in the /tmp/vfs/temp/tempxxxxxxx/content-yyyyyyy where xxxxxxx and yyyyyyy are random hex values.

These files are all internal to JBoss. When JBoss is stopped you can safely remove the /tmp folder and on the next startup JBoss will redeploy the war from the uploaded /data file contents - this is controlled by an entry in your configuration.xml file.

If you accidentally remove the /data folder then JBoss will not start. To fix this you need to either start your instance with the --admin-only switch and redeploy your war, or carefully edit your configuration.xml to remove the deployment, and then start JBoss and redeploy your war using the console.

shonky linux user
  • 6,131
  • 4
  • 46
  • 73
  • Is the jboss-eap-6.2/standalone/deployments still used? If so, what is the difference between the two? – user2312688 Feb 21 '18 at 14:47
  • The /standalone/deployments folder provides another way to deploy an application by physically placing the file(s) to be deployed in there. JBoss scans the folder and tries to deploy the application. The original question was about deploying using the web console and where JBoss places the uploaded file(s) in its internal structure. – shonky linux user Feb 22 '18 at 05:01
  • When I used the jboss as maven plugin, it deployed to /data/content... also and not standalone/deployment. If I copied a jar into standalone/deployment while the server was running , it did not deploy it but wildfly server did – user2312688 Feb 22 '18 at 07:22
  • 1
    Yes maven is yet another method of deploying an app. If you copy an app package to JBoss /standalone/deployments you also need to add a "flag" file with the name of the app suffixed with .dodeploy. It depends on the configured scan settings and is not related to the question to that the OP asked which was specifically about web console deployments. – shonky linux user Feb 22 '18 at 22:30