Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8381877
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 9, 20262026-06-09T16:47:39+00:00 2026-06-09T16:47:39+00:00

What is/are the ant commands in build.xml to deploy a .war file as a

  • 0

What is/are the ant commands in build.xml to deploy a .war file as a folder on a JBoss AS 5.1 web server?

When I run JBoss AS from JBoss Developer studio, it deploys a .war folder into the /deploy folder of JBoss AS for my web service, and everything deploys nicely – which is exactly what I want to do, but with a build.xml file using ant instead. However when I use ant and a build.xml file with the commands below to deploy, it merely adds a .war file instead of a folder, which in turn fails the deployment:

  <target name="deploy">
      <war destfile="build/MyWebService.war" webxml="WebContent/WEB-INF/web.xml">
         <classes dir="build/classes"/>
      </war>
      <copy file="build/MyWebService.war" todir="${jboss.home}/deploy"/>
  </target>

Surely there is a nice easy bit of code that I can put into my build.xml that mimics the deployment of the .war folder in JBoss AS when it is started? Does anyone know?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-09T16:47:40+00:00Added an answer on June 9, 2026 at 4:47 pm

    Not sure I understand the problem, but you could just tell ant to unzip the war file. (http://ant.apache.org/manual/Tasks/unzip.html)

    I’ve never used JBoss, but I would have expected it to automatically pick up the war file and unpack it itself.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

$ ant deploy Buildfile: /Users/simpatico/SOLR_HOME/build.xml deploy: BUILD FAILED /Users/simpatico/SOLR_HOME/build.xml:531: java.io.IOException: Server returned HTTP response
I have a ant build.xml (below). I am able to run phpunit fine from
i need to write an ant (build.xml) file to do the following: - run
I exported a build.xml file from an Eclipse/Android project (under Windows). Then I use
My project runs perfectly fine with following commands: C:\project\<project_name>\ant -lib ant\lib -buildfile applications/<sub-project-path>/ant/build.xml deploy
My pom.xml is running an Ant task to deploy a file using FTP. However,
The ways I know about so far are Create an ant build.xml file, make
I have an android eclipse project and have generated the corresponding build.xml ant file
Use 'ant clean test' with the newest android sdk got error: build.xml:622: The following
The Ant war task does just that - creates WEB-INF along with META-INF, depending

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.