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 8300555
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 8, 20262026-06-08T16:36:05+00:00 2026-06-08T16:36:05+00:00

I want to deploy my src/main/webapp folder from Maven project as an application in

  • 0

I want to deploy my src/main/webapp folder from Maven project as an application in JBoss7. What I’m trying to do is to:

  • save and refresh xhtml, css, js etc.
  • do mvn prepare-package war:inplace for full deployment

This is of course for development only. I want to have similar workflow as with Maven Jetty plugin but for JEE6 app.

Deployment scanner is looking for *.war directories.

My current solutions:

  • use jboss-as-maven-plugin to deploy on package phase – with this I need to redeploy on each CSS, JS or XHTML change
  • add my target folder to deployment-scanner and do war:exploded to copy resources to war dir. Full redeployment needs creating .dodeploy file with antrun plugin and this is quite ugly. I still need to run maven after saving resources. I don’t want my resources to be copied anywhere.

There is nothing special in my pom.xml:

<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
<modelVersion>4.0.0</modelVersion>

<groupId>com.pg</groupId>
<artifactId>jeesample</artifactId>
<version>0.0.1-SNAPSHOT</version>
<packaging>war</packaging>

<name>jeesample</name>

<properties>
    <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
</properties>

<dependencies>
    <dependency>
        <groupId>javax</groupId>
        <artifactId>javaee-web-api</artifactId>
        <version>6.0</version>
        <scope>provided</scope>
    </dependency>

    <dependency>
        <groupId>org.primefaces</groupId>
        <artifactId>primefaces</artifactId>
        <version>3.3.1</version>
    </dependency>

    <dependency>
        <groupId>org.slf4j</groupId>
        <artifactId>slf4j-api</artifactId>
        <version>1.6.6</version>
    </dependency>


</dependencies>

<build>
    <finalName>jeesample.war</finalName>
    <plugins>
        <plugin>
            <groupId>org.apache.maven.plugins</groupId>
            <artifactId>maven-compiler-plugin</artifactId>
            <version>2.3.2</version>
            <configuration>
                <source>1.6</source>
                <target>1.6</target>
            </configuration>
        </plugin>
    </plugins>


</build>

<repositories>
    <repository>
        <id>prime-repo</id>
        <name>PrimeFaces Maven Repository</name>
        <url>http://repository.primefaces.org</url>
        <layout>default</layout>
    </repository>
</repositories>

  • 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-08T16:36:07+00:00Added an answer on June 8, 2026 at 4:36 pm

    Try to use the maven-war-plugin. Maven should add your depenendencies. Note, however, that JBoss 7 has a new module dependency system, so if you want to use some internal modules provided by jboss you have to state them in your MANIFEST.MF file as in the example and mark them as provided in the pom.xml. JBoss 7 reads the manifest and loads the modules upon deploy

    Here is an example that works for me:

        ...
        <plugin>
                <artifactId>maven-war-plugin</artifactId>
                <version>2.1.1</version>
                <configuration>
                    <failOnMissingWebXml>false</failOnMissingWebXml>
                    <archive>
                        <manifestEntries>
                            <Built-By>Dev Team</Built-By>
                            <Dependencies>javaee.api, javax.faces.api, javax.xml.rpc.api,
                                org.joda.time, org.hibernate, org.hibernate.validator,
                                org.dom4j, org.picketlink</Dependencies>
                        </manifestEntries>
                    </archive>
                </configuration>
            </plugin>
         ...
    

    With this config the correct war is created (mvn war:war). Also when I right click on the project in eclipse and choose > ‘Run on Server’ the war is deployed correctly. Resources such as xhtml, etc are automatically redeployed on save and the changes are visible upon refresh.
    I also have the m2eclipse plugin installed

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

Sidebar

Related Questions

I want to copy a resource file from src/main/resources to Cargo Tomcat in /target/tomcat6x/container/webapps
I want to deploy same web application to multiple sites with different domains and
I want to deploy the sencha touch application to native Android (apk) but when
I want to deploy my Jax-WS2.2 based application on CloudFoundry tomcat instance. In my
I want to deploy a firebird installation, and thus will launch it from my
I want to deploy the release version of my application done in C#. When
I want to deploy an application with a license attached. However, I want to
I want to deploy a installer package to my customers. My application is basically
If I want to deploy an ASP.NET application that hosts RIA Services endpoints for
I want to deploy my Symfony2 project into my server and capifony but I

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.