Apache Maven
Maven EAR 플러그인
수색…
소개
다음은 .war 및 .jar 파일을 패키징하기위한 기본 Maven 이어 플러그인의 예제 구성입니다.
기본 EAR 구성
<dependencies>
<dependency>
<groupId>{ejbModuleGroupId}</groupId>
<artifactId>{ejbModuleArtifactId}</artifactId>
<version>{ejbModuleVersion}</version>
<type>ejb</type>
</dependency>
<dependency>
<groupId>{webModuleGroupId}</groupId>
<artifactId>{webModuleArtifactId}</artifactId>
<version>{webModuleVersion}</version>
<type>war</type>
</dependency>
</depencencies>
<build>
<plugins>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-ear-plugin</artifactId>
<version>2.9.1</version>
<configuration>
<version>1.4</version><!-- application.xml verion -->
<modules>
<ejbModule>
<groupId>{ejbModuleGroupId}</groupId>
<artifactId>{ejbModuleArtifactId}</artifactId>
</ejbModule>
<webModule>
<groupId>{webModuleGroupId}</groupId>
<artifactId>{webModuleArtifactId}</artifactId>
<contextRoot>/custom-context-root</contextRoot>
</webModule>
</modules>
</configuration>
</plugin>
</plugins>
</build>
mvn clean install 컴파일하면 ejb (.jar) 및 웹 모듈이 모두 포함 된 대상 디렉토리에 application.xml JEE 설명 파일과 함께 .ear 아티팩트가 생성됩니다.
Modified text is an extract of the original Stack Overflow Documentation
아래 라이선스 CC BY-SA 3.0
와 제휴하지 않음 Stack Overflow