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