MAVEN: Error assembling WAR: webxml attribute is required

环境:MyEclipse2015 CI+Maven3

使用Maven创建一个Web project(创建方法参考《如何用Maven创建web项目(具体步骤)》),执行maven
install时出现错误。

[INFO] ------------------------------------------------------------------------

[INFO] BUILD FAILURE

[INFO] ------------------------------------------------------------------------

[INFO] Total time: 3.152 s

[INFO] Finished at: 2015-05-19T16:41:50+08:00

[INFO] Final Memory: 9M/21M

[INFO] ------------------------------------------------------------------------

[ERROR] Failed to execute goal org.apache.maven.plugins:maven-war-plugin:2.4:war (default-war) on project TestWebApp: Error assembling WAR: webxml attribute is required (or pre-existing WEB-INF/web.xml if executing
in update mode) -> [Help 1]

[ERROR]

[ERROR] To see the full stack trace of the errors, re-run Maven with the -e switch.

[ERROR] Re-run Maven using the -X switch to enable full debug logging.

[ERROR]

[ERROR] For more information about the errors and possible solutions, please read the following articles:

[ERROR] [Help 1] http://cwiki.apache.org/confluence/display/MAVEN/MojoExecutionException

原因:目录/src/main/webapp/WEB-INF/下没有web.xml文件;

解决方案:在该目录下新建文件web.xml

效果:成功

时间: 2024-09-28 05:09:08

MAVEN: Error assembling WAR: webxml attribute is required的相关文章

Error assembling WAR: webxml attribute is required (or pre-existing WEB-INF/web.xml if executing in

执行Maven Install打包的时候,出现以下错误信息: [ERROR] Failed to execute goal org.apache.maven.plugins:maven-war-plugin:2.2:war (default-war) on project pro-test: Error assembling WAR: webxml attribute is required (or pre-existing WEB-INF/web.xml if executing in upd

SpringBoot发布WAR启动报错:Error assembling WAR: webxml attribute is required

Spring Boot发布war包流程: 1.修改web model的pom.xml <packaging>war</packaging> SpringBoot默认发布的都是jar,因此要修改默认的打包方式jar为war 2.修改web model的依赖(dependency) <dependency> <groupId>org.springframework.boot</groupId> <artifactId>spring-boo

008-SpringBoot发布WAR启动报错:Error assembling WAR: webxml attribute is required

一.Spring Boot发布war包流程: 1.修改web model的pom.xml <packaging>war</packaging> SpringBoot默认发布的都是jar,因此要修改默认的打包方式jar为war 2.修改web model的依赖(dependency) <dependency> <groupId>org.springframework.boot</groupId> <artifactId>spring-b

Failed to execute goal.....webxml attribute is required...

maven在打包项目的时候报错 Failed to execute goal org.apache.maven.plugins:maven-war-plugin:2.2:war (default-war) on project taotao-manager-web: Error assembling WAR: webxml attribute is required (or pre-existing WEB-INF/web.xml if executing in update mode) mav

[WARNING] Warning: selected war files include a WEB-INF/web.xml which will be ignored (webxml attribute is missing from war task, or ignoreWebxml attribute is specified as &#39;true&#39;)

WARNING] Warning: selected war files include a WEB-INF/web.xml which will be ignored (webxml attribute is missing from war task, or ignoreWebxml attribute is specified as 'true')   在使用Maven 编译项目的时候会出现  [WARNING] Warning: selected war files include a

maven 自动部署war(项目)到tomcat

1.软件版本 apache-tomcat-7.0.55 apache-maven-3.2.2 eclipse-standard-luna-R-win32-x86_64 2.修改文件 2.1 tomcat  tomcat-users.xml 增加如下用户 角色 manager-script manager-script - Access to the tools-friendly plain text interface that is described in this document, an

Maven自动部署war到Tomcat6

Maven自动部署war到Tomcat 软件版本:tomcat6.maven3 1.  在maven项目的pom里配置如下信息 <build> <finalName>spring_web</finalName> <plugins> <plugin> <groupId>org.codehaus.mojo</groupId> <artifactId>tomcat-maven-plugin</artifactI

maven错误:Error assembling JAR: A zip file cannot include itself

出错情景:maven项目clear后直接install 出错原因:maven执行install后先编译第一个module然后开始打包,编译第二个module继续打包(这个时候文件夹中已经包含了这个文件,所以出现这个错误) 解决方案:先clear complie install,在complie后会先形成所有的的配置文件和.class文件,在执行install的时候不会重新编译文件,而是会使用当前的文件进行打包 这错误找到解决方案用了半天,花了2小时才找到出错的原因,我也是醉了

Maven error in eclipse (pom.xml) : Failure to transfer org.apache.maven.plugins:maven-surefire-plugin:pom:2.12.4

i wanna make web project using the Maven to import automatically all libraries that i need, so i chose "maven-archetype-webpp" after that i got this error on pom.xml file : Description Resource Path Location Type Failure to transfer org.apache.m