blob: 393d3bc4464eb1aa6871b0cb8e614f5a3e48908e [file] [log] [blame]
Pawel Kasperkiewicz50f42bd2020-02-04 14:21:29 +01001<?xml version="1.0" encoding="UTF-8"?>
2<!--
3 ================================================================================
4 Copyright (c) 2020 Nokia. All rights reserved.
5 ================================================================================
6 Licensed under the Apache License, Version 2.0 (the "License"); you may not
7 use this file except in compliance with the License. You may obtain a copy
8 of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required
9 by applicable law or agreed to in writing, software distributed under the
10 License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS
11 OF ANY KIND, either express or implied. See the License for the specific
12 language governing permissions and limitations under the License.
13 ============LICENSE_END=========================================================
14-->
15<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
16 xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 https://maven.apache.org/xsd/maven-4.0.0.xsd">
17 <modelVersion>4.0.0</modelVersion>
18 <parent>
Bartosz Gardziejewskibeecacb2020-02-13 07:31:47 +010019 <groupId>org.onap.aaf.certservice</groupId>
Bartosz Gardziejewski5d71eb72020-02-13 08:17:55 +010020 <artifactId>aaf-certservice</artifactId>
Bartosz Gardziejewskidd700fc2020-02-13 08:44:03 +010021 <version>1.0.0-SNAPSHOT</version>
Pawel Kasperkiewicz50f42bd2020-02-04 14:21:29 +010022 </parent>
Bartosz Gardziejewski5d71eb72020-02-13 08:17:55 +010023 <artifactId>aaf-certservice-api</artifactId>
Bartosz Gardziejewskidd700fc2020-02-13 08:44:03 +010024 <version>1.0.0-SNAPSHOT</version>
Bartosz Gardziejewski5d71eb72020-02-13 08:17:55 +010025 <name>aaf-certservice-api</name>
26 <description>AAF Certification Service Api</description>
Pawel Kasperkiewicz50f42bd2020-02-04 14:21:29 +010027 <packaging>jar</packaging>
28
29 <properties>
30 <java.version>11</java.version>
31 <assertj-core.version>3.11.1</assertj-core.version>
32 <mockito-core.version>3.2.4</mockito-core.version>
33 <spring-core.version>5.2.3.RELEASE</spring-core.version>
34 <spring-boot-starter.version>2.2.4.RELEASE</spring-boot-starter.version>
35 <maven-javadoc-plugin.version>3.0.1</maven-javadoc-plugin.version>
36 <maven-surefire-plugin.version>3.0.0-M1</maven-surefire-plugin.version>
Paweldb979302020-02-05 11:24:54 +010037 <spring-boot-starter-actuator.version>2.2.4.RELEASE</spring-boot-starter-actuator.version>
Pawel Kasperkiewicz68016582020-02-06 11:54:06 +010038 <spring-boot-starter-log4j2.version>2.1.5.RELEASE</spring-boot-starter-log4j2.version>
Bartosz Gardziejewski4dd87392020-02-07 08:27:34 +010039 <springdoc-openapi-ui.version>1.2.21</springdoc-openapi-ui.version>
Bartosz Gardziejewskibddd4f02020-02-11 13:27:08 +010040 <bouncycastle.version>1.60</bouncycastle.version>
Pawel8b1072c2020-02-10 13:03:38 +010041 <docker-maven-plugin.version>0.33.0</docker-maven-plugin.version>
Tomasz Golabekb9dabed2020-02-11 09:12:09 +010042 <docker.tag>${project.version}</docker.tag>
Bartosz Gardziejewskic88b66b2020-02-12 07:49:02 +010043 <springdoc-openapi-maven-plugin.apiDocsUrl>http://localhost:8080/v3/api-docs
44 </springdoc-openapi-maven-plugin.apiDocsUrl>
Pawel Kasperkiewicz50f42bd2020-02-04 14:21:29 +010045 </properties>
46
47 <dependencyManagement>
48 <dependencies>
49 <dependency>
50 <!-- Import dependency management from Spring Boot -->
51 <groupId>org.springframework.boot</groupId>
52 <artifactId>spring-boot-dependencies</artifactId>
53 <version>${spring-boot-starter.version}</version>
54 <type>pom</type>
55 <scope>import</scope>
56 </dependency>
57 </dependencies>
58 </dependencyManagement>
59
60 <dependencies>
61 <dependency>
62 <groupId>org.springframework.boot</groupId>
63 <artifactId>spring-boot-starter-web</artifactId>
64 <version>${spring-boot-starter.version}</version>
Pawel Kasperkiewicz68016582020-02-06 11:54:06 +010065 <exclusions>
66 <exclusion>
67 <groupId>org.springframework.boot</groupId>
68 <artifactId>spring-boot-starter-logging</artifactId>
69 </exclusion>
70 </exclusions>
71 </dependency>
72 <dependency>
73 <groupId>org.springframework.boot</groupId>
74 <artifactId>spring-boot-starter-log4j2</artifactId>
75 <version>${spring-boot-starter-log4j2.version}</version>
Pawel Kasperkiewicz50f42bd2020-02-04 14:21:29 +010076 </dependency>
77 <dependency>
78 <groupId>org.springframework.boot</groupId>
79 <artifactId>spring-boot-starter-test</artifactId>
80 <version>${spring-boot-starter.version}</version>
81 <scope>test</scope>
82 <exclusions>
83 <exclusion>
84 <groupId>org.junit.vintage</groupId>
85 <artifactId>junit-vintage-engine</artifactId>
86 </exclusion>
87 </exclusions>
88 </dependency>
89 <dependency>
90 <groupId>org.mockito</groupId>
91 <artifactId>mockito-core</artifactId>
92 <version>${mockito-core.version}</version>
93 <scope>test</scope>
94 </dependency>
95 <dependency>
96 <groupId>org.assertj</groupId>
97 <artifactId>assertj-core</artifactId>
98 <version>${assertj-core.version}</version>
99 <scope>test</scope>
100 </dependency>
Paweldb979302020-02-05 11:24:54 +0100101 <dependency>
102 <groupId>org.springframework.boot</groupId>
103 <artifactId>spring-boot-starter-actuator</artifactId>
104 <version>${spring-boot-starter-actuator.version}</version>
105 </dependency>
Bartosz Gardziejewski4dd87392020-02-07 08:27:34 +0100106 <dependency>
107 <groupId>org.springdoc</groupId>
108 <artifactId>springdoc-openapi-ui</artifactId>
109 <version>${springdoc-openapi-ui.version}</version>
110 </dependency>
Bartosz Gardziejewskibddd4f02020-02-11 13:27:08 +0100111 <dependency>
112 <groupId>org.bouncycastle</groupId>
113 <artifactId>bcpkix-jdk15on</artifactId>
114 <version>${bouncycastle.version}</version>
115 </dependency>
116 <dependency>
117 <groupId>org.bouncycastle</groupId>
118 <artifactId>bcprov-jdk15on</artifactId>
119 <version>${bouncycastle.version}</version>
120 </dependency>
Pawel Kasperkiewicz50f42bd2020-02-04 14:21:29 +0100121 </dependencies>
122
123 <build>
124 <pluginManagement>
125 <plugins>
126 <plugin>
127 <groupId>org.springframework.boot</groupId>
128 <artifactId>spring-boot-maven-plugin</artifactId>
129 <version>${spring-boot-starter.version}</version>
130 </plugin>
131 <plugin>
132 <artifactId>maven-javadoc-plugin</artifactId>
133 <version>${maven-javadoc-plugin.version}</version>
134 </plugin>
135 <plugin>
136 <groupId>org.apache.maven.plugins</groupId>
137 <artifactId>maven-surefire-plugin</artifactId>
138 <version>${maven-surefire-plugin.version}</version>
139 </plugin>
Pawel Kasperkiewicz50f42bd2020-02-04 14:21:29 +0100140 </plugins>
141 </pluginManagement>
142 <plugins>
143 <plugin>
144 <groupId>org.springframework.boot</groupId>
145 <artifactId>spring-boot-maven-plugin</artifactId>
146 <executions>
147 <execution>
148 <goals>
149 <goal>repackage</goal>
150 </goals>
151 </execution>
Bartosz Gardziejewskic88b66b2020-02-12 07:49:02 +0100152 <execution>
153 <id>pre-integration-test</id>
154 <goals>
155 <goal>start</goal>
156 </goals>
157 </execution>
158 <execution>
159 <id>post-integration-test</id>
160 <goals>
161 <goal>stop</goal>
162 </goals>
163 </execution>
Pawel Kasperkiewicz50f42bd2020-02-04 14:21:29 +0100164 </executions>
165 </plugin>
166 <plugin>
167 <artifactId>maven-javadoc-plugin</artifactId>
168 <configuration>
169 <quiet>true</quiet>
170 <verbose>false</verbose>
171 <useStandardDocletOptions>false</useStandardDocletOptions>
Pawel8b1072c2020-02-10 13:03:38 +0100172 <javadocExecutable>${java.home}/bin/javadoc</javadocExecutable>
Pawel Kasperkiewicz50f42bd2020-02-04 14:21:29 +0100173 </configuration>
174 <executions>
175 <execution>
176 <id>aggregate</id>
177 <phase>site</phase>
178 <goals>
179 <goal>aggregate</goal>
180 </goals>
181 </execution>
182 <execution>
183 <id>attach-javadoc</id>
184 <goals>
185 <goal>jar</goal>
186 </goals>
187 </execution>
188 </executions>
189 </plugin>
Bartosz Gardziejewskic88b66b2020-02-12 07:49:02 +0100190 <plugin>
191 <groupId>org.springdoc</groupId>
192 <artifactId>springdoc-openapi-maven-plugin</artifactId>
193 <version>0.2</version>
194 <executions>
195 <execution>
196 <phase>integration-test</phase>
197 <goals>
198 <goal>generate</goal>
199 </goals>
200 </execution>
201 </executions>
202 <configuration>
203 <apiDocsUrl>${springdoc-openapi-maven-plugin.apiDocsUrl}</apiDocsUrl>
204 <outputFileName>api-docs.json</outputFileName>
205 <outputDir>${project.build.directory}</outputDir>
206 </configuration>
207 </plugin>
Pawel Kasperkiewicz50f42bd2020-02-04 14:21:29 +0100208 </plugins>
209 </build>
210
Pawel8b1072c2020-02-10 13:03:38 +0100211 <profiles>
212 <profile>
Tomasz Golabekb9dabed2020-02-11 09:12:09 +0100213 <id>docker-staging</id>
214 <properties>
215 <docker.tag>${project.version}-STAGING-${maven.build.timestamp}</docker.tag>
216 <docker.latest.tag>${project.version}-STAGING-latest</docker.latest.tag>
217 </properties>
218 </profile>
219
220 <profile>
Pawel8b1072c2020-02-10 13:03:38 +0100221 <id>docker</id>
222 <activation>
223 <activeByDefault>false</activeByDefault>
224 </activation>
225 <build>
226 <plugins>
227 <plugin>
228 <groupId>io.fabric8</groupId>
229 <artifactId>docker-maven-plugin</artifactId>
230 <version>${docker-maven-plugin.version}</version>
231 <executions>
232 <execution>
Tomasz Golabekb9dabed2020-02-11 09:12:09 +0100233 <id>clean-images</id>
234 <phase>pre-clean</phase>
Pawel8b1072c2020-02-10 13:03:38 +0100235 <goals>
Tomasz Golabekb9dabed2020-02-11 09:12:09 +0100236 <goal>remove</goal>
Pawel8b1072c2020-02-10 13:03:38 +0100237 </goals>
Tomasz Golabekb9dabed2020-02-11 09:12:09 +0100238 <configuration>
239 <removeAll>true</removeAll>
240 <image>onap/cert-service</image>
241 </configuration>
Pawel8b1072c2020-02-10 13:03:38 +0100242 </execution>
243 <execution>
Tomasz Golabekb9dabed2020-02-11 09:12:09 +0100244 <id>generate-images</id>
245 <phase>install</phase>
Pawel8b1072c2020-02-10 13:03:38 +0100246 <goals>
Tomasz Golabekb9dabed2020-02-11 09:12:09 +0100247 <goal>build</goal>
Pawel8b1072c2020-02-10 13:03:38 +0100248 </goals>
249 </execution>
Tomasz Golabekb9dabed2020-02-11 09:12:09 +0100250<!-- It has to be published on nexus firstly to uncomment integration tests-->
251<!-- <execution>-->
252<!-- <id>start</id>-->
253<!-- <phase>pre-integration-test</phase>-->
254<!-- <goals>-->
255<!-- <goal>start</goal>-->
256<!-- </goals>-->
257<!-- </execution>-->
258<!-- <execution>-->
259<!-- <id>stop</id>-->
260<!-- <phase>post-integration-test</phase>-->
261<!-- <goals>-->
262<!-- <goal>stop</goal>-->
263<!-- </goals>-->
264<!-- </execution>-->
265 <execution>
266 <id>push-images</id>
267 <phase>deploy</phase>
268 <goals>
269 <goal>push</goal>
270 </goals>
271 <configuration>
272 <image>onap/cert-service</image>
273 </configuration>
274 </execution>
Pawel8b1072c2020-02-10 13:03:38 +0100275 </executions>
276 <configuration>
Tomasz Golabekb9dabed2020-02-11 09:12:09 +0100277 <apiVersion>1.23</apiVersion>
278 <registry>nexus3.onap.org:10001</registry>
279 <authConfig>
280 <pull>
281 <username>docker</username>
282 <password>docker</password>
283 </pull>
284 </authConfig>
Pawel8b1072c2020-02-10 13:03:38 +0100285 <images>
286 <image>
Tomasz Golabekb9dabed2020-02-11 09:12:09 +0100287 <name>onap/cert-service</name>
288 <alias>cert-service</alias>
Pawel8b1072c2020-02-10 13:03:38 +0100289 <build>
290 <dockerFile>${project.basedir}/Dockerfile</dockerFile >
Tomasz Golabekb9dabed2020-02-11 09:12:09 +0100291 <tags>
292 <tag>${docker.tag}</tag>
293 </tags>
Pawel8b1072c2020-02-10 13:03:38 +0100294 </build>
295 <run>
296 <ports>
297 <port>8080:8080</port>
298 </ports>
299 <wait>
300 <!-- Check for this URL to return a 200 return code .... -->
301 <url>http://localhost:8080/actuator/health</url>
302 <time>120000</time>
303 </wait>
304 </run>
305 </image>
306 </images>
307 </configuration>
308 </plugin>
309 </plugins>
310 </build>
311 </profile>
312 </profiles>
Tomasz Golabek3b531c02020-02-12 08:56:23 +0100313
314 <distributionManagement>
315 <repository>
316 <id>ecomp-releases</id>
317 <name>AAF Release Repository</name>
318 <url>${nexusproxy}${releaseNexusPath}</url>
319 </repository>
320 <snapshotRepository>
321 <id>ecomp-snapshots</id>
322 <name>AAF Snapshot Repository</name>
323 <url>${nexusproxy}${snapshotNexusPath}</url>
324 </snapshotRepository>
325 <site>
326 <id>ecomp-site</id>
327 <url>dav:${nexusproxy}${sitePath}</url>
328 </site>
329 </distributionManagement>
330
Pawel Kasperkiewicz50f42bd2020-02-04 14:21:29 +0100331</project>