blob: 2577148fdd488a032f2e67f0346f67a17563655b [file] [log] [blame]
ramverma08b595c2018-07-13 12:32:32 +01001<!--
2 ============LICENSE_START=======================================================
3 Copyright (C) 2018 Ericsson. All rights reserved.
liamfallon41712562019-11-01 11:47:21 +00004 Modifications Copyright (C) 2019 Nordix Foundation.
ramverma08b595c2018-07-13 12:32:32 +01005 ================================================================================
6 Licensed under the Apache License, Version 2.0 (the "License");
7 you may not use this file except in compliance with the License.
8 You may obtain a copy of the License at
9
10 http://www.apache.org/licenses/LICENSE-2.0
11
12 Unless required by applicable law or agreed to in writing, software
13 distributed under the License is distributed on an "AS IS" BASIS,
14 WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
15 See the License for the specific language governing permissions and
16 limitations under the License.
17
18 SPDX-License-Identifier: Apache-2.0
19 ============LICENSE_END=========================================================
20-->
ramvermaea736d02018-11-29 13:47:30 +000021<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
22 xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
ramverma08b595c2018-07-13 12:32:32 +010023 <modelVersion>4.0.0</modelVersion>
24 <parent>
25 <groupId>org.onap.policy.apex-pdp.client</groupId>
26 <artifactId>client</artifactId>
jrh3d7d9df62019-09-12 10:07:06 -040027 <version>2.3.0-SNAPSHOT</version>
ramverma08b595c2018-07-13 12:32:32 +010028 </parent>
29
30 <artifactId>client-editor</artifactId>
31 <name>${project.artifactId}</name>
32 <description>Web client for editing Apex policies</description>
33
34 <dependencies>
35 <dependency>
liamfallonefdaa0d2018-08-03 16:12:01 +010036 <groupId>org.onap.policy.common</groupId>
liamfallond7eda872019-11-04 18:07:20 +000037 <artifactId>policy-endpoints</artifactId>
38 </dependency>
39 <dependency>
40 <groupId>org.onap.policy.common</groupId>
liamfallonefdaa0d2018-08-03 16:12:01 +010041 <artifactId>utils</artifactId>
42 </dependency>
43 <dependency>
ramverma08b595c2018-07-13 12:32:32 +010044 <groupId>org.onap.policy.apex-pdp.model</groupId>
45 <artifactId>model-api</artifactId>
46 <version>${project.version}</version>
47 </dependency>
48 <dependency>
49 <groupId>org.onap.policy.apex-pdp.core</groupId>
50 <artifactId>core-infrastructure</artifactId>
51 <version>${project.version}</version>
52 </dependency>
53 <dependency>
ramverma08b595c2018-07-13 12:32:32 +010054 <groupId>org.glassfish.jersey.containers</groupId>
55 <artifactId>jersey-container-grizzly2-http</artifactId>
ramverma08b595c2018-07-13 12:32:32 +010056 </dependency>
57 <dependency>
58 <groupId>org.glassfish.jersey.media</groupId>
59 <artifactId>jersey-media-moxy</artifactId>
ramverma08b595c2018-07-13 12:32:32 +010060 </dependency>
61 <dependency>
liamfallond7eda872019-11-04 18:07:20 +000062 <groupId>org.glassfish.jersey.test-framework.providers</groupId>
63 <artifactId>jersey-test-framework-provider-grizzly2</artifactId>
64 <scope>test</scope>
ramverma08b595c2018-07-13 12:32:32 +010065 </dependency>
66 <dependency>
67 <groupId>commons-cli</groupId>
68 <artifactId>commons-cli</artifactId>
ramverma08b595c2018-07-13 12:32:32 +010069 </dependency>
70 <dependency>
71 <groupId>junit</groupId>
72 <artifactId>junit</artifactId>
73 <scope>test</scope>
74 </dependency>
75 <dependency>
ramvermaea736d02018-11-29 13:47:30 +000076 <groupId>org.onap.policy.apex-pdp.client</groupId>
77 <artifactId>client-common</artifactId>
78 <version>${project.version}</version>
79 <classifier>resources</classifier>
80 <type>zip</type>
81 <scope>provided</scope>
82 </dependency>
83
ramverma08b595c2018-07-13 12:32:32 +010084 </dependencies>
85
86 <build>
87 <defaultGoal>install</defaultGoal>
88 <outputDirectory>${project.build.directory}/classes</outputDirectory>
89 <plugins>
ramvermaea736d02018-11-29 13:47:30 +000090
91<!-- https://blog.sonatype.com/2008/04/how-to-share-resources-across-projects-in-maven/ -->
ramverma08b595c2018-07-13 12:32:32 +010092 <plugin>
93 <groupId>org.apache.maven.plugins</groupId>
94 <artifactId>maven-dependency-plugin</artifactId>
95 <executions>
96 <execution>
ramvermaea736d02018-11-29 13:47:30 +000097 <id>unpack-shared-resources</id>
liamfallon32497612018-11-10 00:39:12 +000098 <goals>
ramvermaea736d02018-11-29 13:47:30 +000099 <goal>unpack-dependencies</goal>
liamfallon32497612018-11-10 00:39:12 +0000100 </goals>
ramvermaea736d02018-11-29 13:47:30 +0000101 <phase>generate-resources</phase>
ramverma08b595c2018-07-13 12:32:32 +0100102 <configuration>
ramvermaea736d02018-11-29 13:47:30 +0000103 <outputDirectory>${project.build.directory}/classes/webapp</outputDirectory>
104 <!--use as much as needed to be specific...also scope,type,classifier etc-->
105 <includeArtifacIds>client-common</includeArtifacIds>
106 <includeGroupIds>org.onap.policy.apex-pdp.client</includeGroupIds>
107 <excludeTransitive>true</excludeTransitive>
108 <excludeTransitive>true</excludeTransitive>
109 <excludeTypes>jar</excludeTypes>
110 <includeTypes>zip</includeTypes>
ramverma08b595c2018-07-13 12:32:32 +0100111 </configuration>
112 </execution>
113 </executions>
114 </plugin>
ramvermaea736d02018-11-29 13:47:30 +0000115 <plugin>
116 <groupId>org.apache.maven.plugins</groupId>
117 <artifactId>maven-assembly-plugin</artifactId>
118 <executions>
119 <execution>
120 <id>make shared resources</id>
121 <goals>
122 <goal>single</goal>
123 </goals>
124 <phase>package</phase>
125 <configuration>
126 <descriptors>
127 <descriptor>src/main/assembly/resources.xml</descriptor>
128 </descriptors>
129 </configuration>
130 </execution>
131 </executions>
132 </plugin>
133
liamfallon32497612018-11-10 00:39:12 +0000134
liamfallona41c8772018-09-05 15:46:31 +0100135 <plugin>
136 <groupId>org.apache.maven.plugins</groupId>
ramverma08b595c2018-07-13 12:32:32 +0100137 <artifactId>maven-shade-plugin</artifactId>
138 <executions>
139 <execution>
140 <phase>package</phase>
141 <goals>
142 <goal>shade</goal>
143 </goals>
144 </execution>
145 </executions>
146 <configuration>
147 <finalName>${project.artifactId}-uber-${project.version}</finalName>
148 <shadedArtifactAttached>true</shadedArtifactAttached>
149 <shadedClassifierName>editor</shadedClassifierName>
150 <artifactSet>
151 <includes>
152 <include>*:*</include>
153 </includes>
154 </artifactSet>
155 <filters>
156 <filter>
157 <artifact>*:*</artifact>
158 <excludes>
159 <exclude>META-INF/*.SF</exclude>
160 <exclude>META-INF/*.DSA</exclude>
161 <exclude>META-INF/*.RSA</exclude>
162 </excludes>
163 </filter>
164 </filters>
165 <transformers>
ramvermaea736d02018-11-29 13:47:30 +0000166 <transformer
167 implementation="org.apache.maven.plugins.shade.resource.ServicesResourceTransformer" />
168 <transformer
169 implementation="org.apache.maven.plugins.shade.resource.AppendingTransformer">
ramverma08b595c2018-07-13 12:32:32 +0100170 <resource>reference.conf</resource>
171 </transformer>
ramvermaea736d02018-11-29 13:47:30 +0000172 <transformer
173 implementation="org.apache.maven.plugins.shade.resource.DontIncludeResourceTransformer">
ramverma08b595c2018-07-13 12:32:32 +0100174 <resource>log4j.properties</resource>
175 </transformer>
ramvermaea736d02018-11-29 13:47:30 +0000176 <transformer
177 implementation="org.apache.maven.plugins.shade.resource.ManifestResourceTransformer">
ramverma08b595c2018-07-13 12:32:32 +0100178 <mainClass>org.onap.policy.apex.client.editor.rest.ApexEditorMain</mainClass>
179 </transformer>
180 </transformers>
181 </configuration>
182 </plugin>
183 <plugin>
184 <groupId>org.apache.maven.plugins</groupId>
185 <artifactId>maven-war-plugin</artifactId>
186 <configuration>
187 <classifier>ui</classifier>
188 <warSourceDirectory>src/main/resources/webapp</warSourceDirectory>
189 <webXml>src/main/resources/webapp/WEB-INF/web.xml</webXml>
190 </configuration>
191 <executions>
192 <execution>
193 <phase>prepare-package</phase>
194 <goals>
195 <goal>war</goal>
196 </goals>
197 </execution>
198 </executions>
199 </plugin>
200 <plugin>
201 <groupId>org.codehaus.mojo</groupId>
202 <artifactId>build-helper-maven-plugin</artifactId>
203 <version>3.0.0</version>
204 <executions>
205 <execution>
206 <id>attach-artifacts</id>
207 <phase>package</phase>
208 <goals>
209 <goal>attach-artifact</goal>
210 </goals>
211 <configuration>
212 <artifacts>
213 <artifact>
214 <file>${project.build.directory}/${project.artifactId}-${project.version}-ui.war</file>
215 <type>war</type>
216 </artifact>
217 <artifact>
218 <file>${project.build.directory}/${project.artifactId}-uber-${project.version}.jar</file>
219 <type>uber.jar</type>
220 </artifact>
221 </artifacts>
222 </configuration>
223 </execution>
224 </executions>
225 </plugin>
226 </plugins>
227 </build>
Dinh Danh Leba229772018-08-22 18:02:01 +0100228
229 <profiles>
230 <profile>
231 <id>apexSite</id>
232 <activation>
233 <property>
234 <name>apexSite</name>
235 </property>
236 </activation>
237 <distributionManagement>
238 <site>
239 <id>${project.artifactId}-site</id>
240 <url>${apex.adsite.prefix}/modules/${project.parent.artifactId}/${project.artifactId}/</url>
241 </site>
242 </distributionManagement>
243 </profile>
244 </profiles>
liamfallon41712562019-11-01 11:47:21 +0000245</project>