3d8973b21fccb4c3dd65b4d42e0daf2aee7c9aaf
[ccsdk/apps.git] / ms / neng / pom.xml
1 <?xml version="1.0" encoding="UTF-8"?>
2 <!--
3  * ============LICENSE_START=======================================================
4  * ONAP : CCSDK.apps
5  * ================================================================================
6  * Copyright (C) 2018 AT&T Intellectual Property. All rights reserved.
7  * ================================================================================
8  * Licensed under the Apache License, Version 2.0 (the "License");
9  * you may not use this file except in compliance with the License.
10  * You may obtain a copy of the License at
11  *
12  *      http://www.apache.org/licenses/LICENSE-2.0
13  *
14  * Unless required by applicable law or agreed to in writing, software
15  * distributed under the License is distributed on an "AS IS" BASIS,
16  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
17  * See the License for the specific language governing permissions and
18  * limitations under the License.
19  * ============LICENSE_END=========================================================
20   -->
21 <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">
22     <modelVersion>4.0.0</modelVersion>
23
24     <groupId>org.onap.ccsdk.apps</groupId>
25     <artifactId>ccsdk-apps-ms-neng</artifactId>
26     <version>0.7.0-SNAPSHOT</version>
27     <name>Naming Generation</name>
28
29     <properties>
30         <swagger.directory>${basedir}/target/classes/META-INF/resources/swagger</swagger.directory>
31         <icd.file>service.json</icd.file>
32         <icd.package>org.onap.ccsdk.apps.ms.neng.service.rs</icd.package>
33         <java.version>1.8</java.version>
34         <spring.version>4.3.17.RELEASE</spring.version>
35         <springboot.version>1.5.16.RELEASE</springboot.version>
36         <docker.registry>nexus3.onap.org:10001</docker.registry>
37         <build.number>local</build.number>
38         <kube.namespace>TBD</kube.namespace>
39         <service.account>TBD</service.account>
40         <namespace>org.onap.ccsdk.apps.ms.neng</namespace>
41         <maven.compiler.source>1.8</maven.compiler.source>
42         <maven.compiler.target>1.8</maven.compiler.target>
43         <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
44         <sdk.java.rest>6.2.0.11</sdk.java.rest>
45         <serviceArtifactName>ms-networkelementnamegen</serviceArtifactName>
46         <ccsdk.distribution.version>0.2.4</ccsdk.distribution.version>
47         <docker.buildArg.https_proxy>${https_proxy}</docker.buildArg.https_proxy>
48         <docker.push.phase>deploy</docker.push.phase>
49         <docker.verbose>true</docker.verbose>
50         <ccsdk.project.version>${project.version}</ccsdk.project.version>
51         <image.name>onap/ccsdk-apps-ms-neng</image.name>
52         <timestamp>${maven.build.timestamp}</timestamp>
53         <maven.build.timestamp.format>yyyyMMddHHmmss</maven.build.timestamp.format>    
54                 <ccsdk.project.version>${project.version}</ccsdk.project.version>
55                 <ccsdk.build.timestamp>${maven.build.timestamp}</ccsdk.build.timestamp>
56     </properties>
57
58     <profiles>
59         <profile>
60             <id>all-tests</id>
61             <properties>
62                 <build.profile.id>all-tests</build.profile.id>
63                 <skip.integration.tests>false</skip.integration.tests>
64                 <skip.unit.tests>false</skip.unit.tests>
65             </properties>
66         </profile>
67         <profile>
68             <id>dev</id>
69         </profile>
70         <profile>
71             <id>integration-test</id>
72             <properties>
73                 <build.profile.id>integration-test</build.profile.id>
74                 <skip.integration.tests>false</skip.integration.tests>
75                 <skip.unit.tests>true</skip.unit.tests>
76             </properties>
77         </profile>
78
79         <profile>
80             <id>blackduck</id>
81             <activation>
82                 <property>
83                     <name>blackduck-scan</name>
84                 </property>
85             </activation>
86             <build>
87                 <plugins>
88                     <plugin>
89                         <groupId>com.blackducksoftware.integration</groupId>
90                         <artifactId>hub-maven-plugin</artifactId>
91                         <version>1.4.0</version>
92                         <inherited>false</inherited>
93                         <configuration>
94                             <hubProjectName>${project.name}</hubProjectName>
95                             <outputDirectory>${project.basedir}</outputDirectory>
96                         </configuration>
97                         <executions>
98                             <execution>
99                                 <id>create-bdio-file</id>
100                                 <phase>package</phase>
101                                 <goals>
102                                     <goal>createHubOutput</goal>
103                                 </goals>
104                             </execution>
105                         </executions>
106                     </plugin>
107                 </plugins>
108             </build>
109         </profile>
110
111         <profile>
112             <id>docker</id>
113             <build>
114                 <plugins>
115                     <plugin>
116                         <artifactId>maven-resources-plugin</artifactId>
117                         <version>2.6</version>
118                         <executions>
119                             <execution>
120                                 <id>copy-dockerfile</id>
121                                 <goals>
122                                     <goal>copy-resources</goal>
123                                 </goals>
124                                 <phase>validate</phase>
125                                 <configuration>
126                                     <outputDirectory>${basedir}/target/docker-stage</outputDirectory>
127                                     <resources>
128                                         <resource>
129                                             <directory>src/main/docker</directory>
130                                             <includes>
131                                                 <include>startService.sh</include>
132                                                 <include>Dockerfile</include>
133                                             </includes>
134                                             <filtering>true</filtering>
135                                         </resource>
136                                     </resources>
137                                 </configuration>
138                             </execution>
139                             <execution>
140                                 <id>copy-app-jar</id>
141                                 <goals>
142                                     <goal>copy-resources</goal>
143                                 </goals>
144                                 <phase>package</phase>
145                                 <configuration>
146                                     <outputDirectory>${basedir}/target/docker-stage</outputDirectory>
147                                     <resources>
148                                         <resource>
149                                             <directory>${basedir}/target/</directory>
150                                             <includes>
151                                                 <include>NetworkElementNameGen.jar</include>
152                                             </includes>
153                                             <filtering>false</filtering>
154                                         </resource>
155                                     </resources>
156                                 </configuration>
157                             </execution>
158                             <execution>
159                                 <id>copy-config</id>
160                                 <goals>
161                                     <goal>copy-resources</goal>
162                                 </goals>
163                                 <phase>validate</phase>
164                                 <configuration>
165                                     <outputDirectory>${basedir}/target/docker-stage/opt/etc/config</outputDirectory>
166                                     <resources>
167                                         <resource>
168                                             <directory>${basedir}/opt/etc/config</directory>
169                                             <includes>
170                                                 <include>*</include>
171                                             </includes>
172                                             <filtering>true</filtering>
173                                         </resource>
174                                     </resources>
175                                 </configuration>
176                             </execution>
177                         </executions>
178                     </plugin>
179
180
181                     <plugin>
182                         <groupId>io.fabric8</groupId>
183                         <artifactId>docker-maven-plugin</artifactId>
184                         <version>0.16.5</version>
185                         <inherited>false</inherited>
186                         <configuration>
187                             <images>
188                                 <image>
189                                     <name>${image.name}</name>
190                                     <build>
191                                         <cleanup>try</cleanup>
192                                         <dockerFileDir>${basedir}/target/docker-stage</dockerFileDir>
193                                         <tags>
194                                                                                         <tag>${project.docker.latestminortag.version}</tag>
195                                                                                         <tag>${project.docker.latestfulltag.version}</tag>
196                                                                                         <tag>${project.docker.latesttagtimestamp.version}</tag>
197                                         </tags>
198                                     </build>
199                                 </image>
200                             </images>
201                             <verbose>true</verbose>
202                         </configuration>
203                         <executions>
204                             <execution>
205                                 <id>generate-images</id>
206                                 <phase>package</phase>
207                                 <goals>
208                                     <goal>build</goal>
209                                 </goals>
210                             </execution>
211                             <execution>
212                                 <id>push-images</id>
213                                 <phase>${docker.push.phase}</phase>
214                                 <goals>
215                                     <goal>build</goal>
216                                     <goal>push</goal>
217                                 </goals>
218                             </execution>
219                         </executions>
220                     </plugin>
221                 </plugins>
222             </build>
223         </profile>
224
225     </profiles>
226
227     <developers>
228         <developer>
229             <id>${userId}</id>
230         </developer>
231     </developers>
232
233
234     <parent>
235         <groupId>org.onap.ccsdk.parent</groupId>
236         <artifactId>spring-boot-1-starter-parent</artifactId>
237         <version>1.5.1-SNAPSHOT</version>
238         <relativePath/>
239     </parent>
240
241
242
243     <dependencies>
244         <dependency>
245             <groupId>io.swagger</groupId>
246             <artifactId>swagger-core</artifactId>
247         </dependency>
248         <dependency>
249             <groupId>org.springframework.boot</groupId>
250             <artifactId>spring-boot-starter-web</artifactId>
251         </dependency>
252         <dependency>
253             <groupId>org.springframework.boot</groupId>
254             <artifactId>spring-boot-starter-jersey</artifactId>
255         </dependency>
256         <dependency>
257             <groupId>org.springframework.boot</groupId>
258             <artifactId>spring-boot-starter-actuator</artifactId>
259         </dependency>
260         <dependency>
261             <groupId>org.springframework.boot</groupId>
262             <artifactId>spring-boot-loader-tools</artifactId>
263         </dependency>
264         <dependency>
265             <groupId>org.springframework.boot</groupId>
266             <artifactId>spring-boot-starter-test</artifactId>
267             <scope>test</scope>
268         </dependency>
269         <dependency>
270             <groupId>org.springframework.boot</groupId>
271             <artifactId>spring-boot-starter-tomcat</artifactId>
272             <scope>compile</scope>
273         </dependency>
274         <dependency>
275             <groupId>org.springframework.boot</groupId>
276             <artifactId>spring-boot-starter-data-jpa</artifactId>
277             <scope>compile</scope>
278         </dependency>
279         <dependency>
280             <groupId>org.apache.httpcomponents</groupId>
281             <artifactId>httpclient</artifactId>
282         </dependency>
283         <dependency>
284             <groupId>javax.ws.rs</groupId>
285             <artifactId>javax.ws.rs-api</artifactId>
286         </dependency>
287         <dependency>
288             <groupId>commons-lang</groupId>
289             <artifactId>commons-lang</artifactId>
290         </dependency>
291         <dependency>
292             <groupId>org.liquibase</groupId>
293             <artifactId>liquibase-core</artifactId>
294         </dependency>
295         <dependency>
296             <groupId>org.mariadb.jdbc</groupId>
297             <artifactId>mariadb-java-client</artifactId>
298         </dependency>
299         <dependency>
300             <groupId>com.h2database</groupId>
301             <artifactId>h2</artifactId>
302         </dependency>
303         <dependency>
304             <groupId>org.springframework.boot</groupId>
305             <artifactId>spring-boot-configuration-processor</artifactId>
306             <optional>true</optional>
307         </dependency>
308         <dependency>
309             <groupId>org.springframework</groupId>
310             <artifactId>spring-test</artifactId>
311             <scope>test</scope>
312         </dependency>
313         <dependency>
314             <groupId>org.springframework</groupId>
315             <artifactId>spring-aop</artifactId>
316         </dependency>
317         <dependency>
318             <groupId>org.springframework</groupId>
319             <artifactId>spring-beans</artifactId>
320         </dependency>
321         <dependency>
322             <groupId>org.springframework</groupId>
323             <artifactId>spring-beans</artifactId>
324         </dependency>
325         <dependency>
326             <groupId>org.springframework</groupId>
327             <artifactId>spring-context</artifactId>
328         </dependency>
329         <dependency>
330             <groupId>org.springframework</groupId>
331             <artifactId>spring-core</artifactId>
332         </dependency>
333         <dependency>
334             <groupId>org.springframework</groupId>
335             <artifactId>spring-expression</artifactId>
336         </dependency>
337         <dependency>
338             <groupId>org.springframework</groupId>
339             <artifactId>spring-web</artifactId>
340         </dependency>
341     </dependencies>
342
343     <build>
344         <finalName>NetworkElementNameGen</finalName>
345         <plugins>
346
347             <plugin>
348                 <groupId>org.codehaus.groovy.maven</groupId>
349                 <artifactId>gmaven-plugin</artifactId>
350                 <version>1.0</version>
351                 <executions>
352                     <execution>
353                         <phase>validate</phase>
354                         <goals>
355                             <goal>execute</goal>
356                         </goals>
357                         <configuration>
358                             <source>${basedir}/../../TagVersion.groovy</source>
359                         </configuration>
360                     </execution>
361                 </executions>
362             </plugin>
363             <plugin>
364                 <groupId>org.apache.maven.plugins</groupId>
365                 <artifactId>maven-surefire-plugin</artifactId>
366                 <configuration>
367                     <argLine>${surefireArgLine}</argLine>
368                     <skipTests>${skip.unit.tests}</skipTests>
369                     <excludes>
370                         <exclude>**/IT*.java</exclude>
371                     </excludes>
372                 </configuration>
373             </plugin>
374             <plugin>
375                 <groupId>org.apache.maven.plugins</groupId>
376                 <artifactId>maven-failsafe-plugin</artifactId>
377                 <executions>
378                     <execution>
379                         <id>integration-tests</id>
380                         <goals>
381                             <goal>integration-test</goal>
382                             <goal>verify</goal>
383                         </goals>
384                         <configuration>
385                             <argLine>${failsafeArgLine}</argLine>
386                             <skipTests>${skip.integration.tests}</skipTests>
387                         </configuration>
388                     </execution>
389                 </executions>
390             </plugin>
391             <plugin>
392                 <artifactId>maven-dependency-plugin</artifactId>
393             </plugin>
394             <plugin>
395                 <groupId>com.github.kongchen</groupId>
396                 <artifactId>swagger-maven-plugin</artifactId>
397                 <version>3.1.3</version>
398                 <configuration>
399                     <apiSources>
400                         <apiSource>
401                             <locations>org.onap.ccsdk.apps.ms.neng.service.rs</locations>
402                             <basePath>/web</basePath>
403                             <info>
404                                 <title>${project.artifactId} Service</title>
405                                 <version>${project.version}</version>
406                             </info>
407                             <swaggerDirectory>${swagger.directory}</swaggerDirectory>
408                         </apiSource>
409                     </apiSources>
410                 </configuration>
411                 <executions>
412                     <execution>
413                         <phase>package</phase>
414                         <goals>
415                             <goal>generate</goal>
416                         </goals>
417                     </execution>
418                 </executions>
419             </plugin>
420
421             <plugin>
422                 <artifactId>exec-maven-plugin</artifactId>
423                 <groupId>org.codehaus.mojo</groupId>
424             </plugin>
425
426             <plugin>
427                 <groupId>org.springframework.boot</groupId>
428                 <artifactId>spring-boot-maven-plugin</artifactId>
429                 <executions>
430                     <execution>
431                         <goals>
432                             <goal>repackage</goal>
433                         </goals>
434                     </execution>
435                 </executions>
436             </plugin>
437         </plugins>
438
439         <resources>
440             <resource>
441                 <directory>src/main/resources</directory>
442                 <filtering>true</filtering>
443                 <includes>
444                     <include>**/*</include>
445                 </includes>
446             </resource>
447             <resource>
448                 <directory>opt/aai/keystore</directory>
449                 <targetPath>../opt/aai/keystore</targetPath>
450                 <filtering>false</filtering>
451                 <includes>
452                     <include>**/*</include>
453                 </includes>
454             </resource>
455
456             <resource>
457                 <directory>opt/etc/config</directory>
458                 <targetPath>../opt/etc/config</targetPath>
459                 <filtering>true</filtering>
460                 <includes>
461                     <include>**/*</include>
462                 </includes>
463             </resource>
464             <resource>
465                 <directory>opt/etc/keystore</directory>
466                 <targetPath>../opt/etc/keystore</targetPath>
467                 <filtering>false</filtering>
468                 <includes>
469                     <include>**/*</include>
470                 </includes>
471             </resource>
472             <resource>
473                 <directory>opt/etc/truststore</directory>
474                 <targetPath>../opt/etc/truststore</targetPath>
475                 <filtering>false</filtering>
476                 <includes>
477                     <include>**/*</include>
478                 </includes>
479             </resource>
480         </resources>
481         <pluginManagement>
482             <plugins>
483                 <!--This plugin's configuration is used to store Eclipse m2e settings only. It has no influence on the Maven build itself.-->
484                 <plugin>
485                     <groupId>org.eclipse.m2e</groupId>
486                     <artifactId>lifecycle-mapping</artifactId>
487                     <version>1.0.0</version>
488                     <configuration>
489                         <lifecycleMappingMetadata>
490                             <pluginExecutions>
491                                 <pluginExecution>
492                                     <pluginExecutionFilter>
493                                         <groupId>
494                                             org.apache.maven.plugins
495                                         </groupId>
496                                         <artifactId>
497                                             maven-checkstyle-plugin
498                                         </artifactId>
499                                         <versionRange>
500                                             [2.17,)
501                                         </versionRange>
502                                         <goals>
503                                             <goal>check</goal>
504                                         </goals>
505                                     </pluginExecutionFilter>
506                                     <action>
507                                         <ignore/>
508                                     </action>
509                                 </pluginExecution>
510                                 <pluginExecution>
511                                     <pluginExecutionFilter>
512                                         <groupId>
513                                             org.codehaus.mojo
514                                         </groupId>
515                                         <artifactId>
516                                             properties-maven-plugin
517                                         </artifactId>
518                                         <versionRange>
519                                             [1.0.0,)
520                                         </versionRange>
521                                         <goals>
522                                             <goal>
523                                                 set-system-properties
524                                             </goal>
525                                         </goals>
526                                     </pluginExecutionFilter>
527                                     <action>
528                                         <ignore/>
529                                     </action>
530                                 </pluginExecution>
531                             </pluginExecutions>
532                         </lifecycleMappingMetadata>
533                     </configuration>
534                 </plugin>
535             </plugins>
536         </pluginManagement>
537     </build>
538 </project>