- pom.xml add the below lines
<?xml version="1.0" encoding="UTF-8"?> <plugin> <groupId>org.apache.maven.plugins</groupId> <artifactId>maven-assembly-plugin</artifactId> <executions> <execution> <id>make-bundles</id> <goals> <goal>single</goal> </goals> <phase>package</phase> <configuration> <descriptors> <descriptor>all-jar.xml</descriptor> </descriptors> <finalName>ct-mobile-service</finalName> <appendAssemblyId>false</appendAssemblyId> </configuration> </execution> </executions> </plugin>
<?
xml
version
=
"1.0"
encoding
=
"UTF-8"
?>
<
modelVersion
>4.0.0</
modelVersion
>
<
parent
>
<
groupId
>com.blujaysolutions.ct</
groupId
>
<
artifactId
>soa-ct-main</
artifactId
>
<
version
>1.0.0</
version
>
<
relativePath
>../soa-ct-main/pom.xml</
relativePath
>
</
parent
>
<
artifactId
>dist</
artifactId
>
<
packaging
>pom</
packaging
>
<
name
>Packaging Test : Distribution</
name
>
<
properties
>
<
wildfly-home
>D:\KCT\server\wildfly-17.0.0.Final</
wildfly-home
>
<
wildfly-hostname
>127.0.0.1</
wildfly-hostname
>
<
wildfly-port
>9990</
wildfly-port
>
<
wildfly-username
>Blujay</
wildfly-username
>
<
wildfly-password
>Bluj@y@123</
wildfly-password
>
</
properties
>
<
dependencies
>
<
dependency
>
<
groupId
>com.blujaysolutions.ct</
groupId
>
<
artifactId
>soa-ct-common</
artifactId
>
<
version
>${project.version}</
version
>
</
dependency
>
<
dependency
>
<
groupId
>com.blujaysolutions.ct</
groupId
>
<
artifactId
>soa-ct-dynamic-screen</
artifactId
>
<
version
>${project.version}</
version
>
</
dependency
>
<
dependency
>
<
groupId
>com.blujaysolutions.ct</
groupId
>
<
artifactId
>soa-ct-master-services</
artifactId
>
<
version
>${project.version}</
version
>
</
dependency
>
<
dependency
>
<
groupId
>com.blujaysolutions.ct</
groupId
>
<
artifactId
>soa-ct-mobile-service</
artifactId
>
<
version
>${project.version}</
version
>
</
dependency
>
<
dependency
>
<
groupId
>com.blujaysolutions.ct</
groupId
>
<
artifactId
>soa-ct-workflow-services</
artifactId
>
<
version
>${project.version}</
version
>
</
dependency
>
<
dependency
>
<
groupId
>com.blujaysolutions.ct</
groupId
>
<
artifactId
>soa-ct-swagger</
artifactId
>
<
version
>${project.version}</
version
>
</
dependency
>
</
dependencies
>
<
build
>
<
plugins
>
<
plugin
>
<
groupId
>org.apache.maven.plugins</
groupId
>
<
artifactId
>maven-assembly-plugin</
artifactId
>
<
executions
>
<
execution
>
<
id
>make-bundles</
id
>
<
goals
>
<
goal
>single</
goal
>
</
goals
>
<
phase
>package</
phase
>
<
configuration
>
<
descriptors
>
<
descriptor
>all-jar.xml</
descriptor
>
</
descriptors
>
<
finalName
>ct-mobile-service</
finalName
>
<
appendAssemblyId
>false</
appendAssemblyId
>
</
configuration
>
</
execution
>
<
execution
>
<
id
>make-bundles2</
id
>
<
goals
>
<
goal
>single</
goal
>
</
goals
>
<
phase
>package</
phase
>
<
configuration
>
<
descriptors
>
<
descriptor
>all-war.xml</
descriptor
>
</
descriptors
>
<
finalName
>ct-mobile-service</
finalName
>
<
appendAssemblyId
>false</
appendAssemblyId
>
</
configuration
>
</
execution
>
</
executions
>
</
plugin
>
</
plugins
>
</
build
>
</
project
>
- create the all-jar.xml to describe how to assemble the artifacts
xsi:schemaLocation = "http://maven.apache.org/ASSEMBLY/2.0.0 http://maven.apache.org/xsd/assembly-2.0.0.xsd" > < id >bin</ id > < formats > < format >jar</ format > </ formats > < includeBaseDirectory >false</ includeBaseDirectory > < dependencySets > < dependencySet > < includes > < include >${project.groupId}:*</ include > </ includes > < excludes > < exclude >io.springfox:*</ exclude > < exclude >${project.groupId}:soa-ct-swagger:*</ exclude > </ excludes > < unpack >true</ unpack > < outputDirectory >.</ outputDirectory > <!-- <outputFileNameMapping>jolokia.war</outputFileNameMapping> --> </ dependencySet > <!-- <dependencySet> <outputDirectory>./dependencies</outputDirectory> <excludes> <exclude>${project.groupId}:*:jar:*</exclude> <exclude>io.springfox:*:jar:*</exclude> </excludes> </dependencySet> --> </ dependencySets > </ assembly > |
3. now run the mvn clean package.
No comments:
Post a Comment