blob: 820bcced17d034f33b492a0b4e471f5f13ae8064 [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>
Pawel486429d2020-02-10 10:36:16 +010019 <groupId>org.onap.aaf</groupId>
20 <artifactId>aaf-certservice-parent</artifactId>
Tomasz Golabek6b5dc292020-02-12 10:46:23 +010021 <version>0.0.1</version>
Pawel Kasperkiewicz50f42bd2020-02-04 14:21:29 +010022 </parent>
Tomasz Golabek3b531c02020-02-12 08:56:23 +010023
Pawel Kasperkiewicz50f42bd2020-02-04 14:21:29 +010024 <artifactId>cert-service</artifactId>
Tomasz Golabek6b5dc292020-02-12 10:46:23 +010025 <version>0.0.1</version>
Pawel Kasperkiewicz50f42bd2020-02-04 14:21:29 +010026 <name>cert-service</name>
27 <description>Certification service</description>
28 <packaging>jar</packaging>
29
30 <properties>
31 <java.version>11</java.version>
32 <assertj-core.version>3.11.1</assertj-core.version>
33 <mockito-core.version>3.2.4</mockito-core.version>
34 <spring-core.version>5.2.3.RELEASE</spring-core.version>
35 <spring-boot-starter.version>2.2.4.RELEASE</spring-boot-starter.version>
36 <maven-javadoc-plugin.version>3.0.1</maven-javadoc-plugin.version>
37 <maven-surefire-plugin.version>3.0.0-M1</maven-surefire-plugin.version>
Paweldb979302020-02-05 11:24:54 +010038 <spring-boot-starter-actuator.version>2.2.4.RELEASE</spring-boot-starter-actuator.version>
Pawel Kasperkiewicz68016582020-02-06 11:54:06 +010039 <spring-boot-starter-log4j2.version>2.1.5.RELEASE</spring-boot-starter-log4j2.version>
Bartosz Gardziejewski4dd87392020-02-07 08:27:34 +010040 <springdoc-openapi-ui.version>1.2.21</springdoc-openapi-ui.version>
Bartosz Gardziejewskibddd4f02020-02-11 13:27:08 +010041 <bouncycastle.version>1.60</bouncycastle.version>
Pawel8b1072c2020-02-10 13:03:38 +010042 <docker-maven-plugin.version>0.33.0</docker-maven-plugin.version>
Tomasz Golabekb9dabed2020-02-11 09:12:09 +010043 <docker.tag>${project.version}</docker.tag>
Bartosz Gardziejewskic88b66b2020-02-12 07:49:02 +010044 <springdoc-openapi-maven-plugin.apiDocsUrl>http://localhost:8080/v3/api-docs
45 </springdoc-openapi-maven-plugin.apiDocsUrl>
Pawel Kasperkiewicz50f42bd2020-02-04 14:21:29 +010046 </properties>
47
48 <dependencyManagement>
49 <dependencies>
50 <dependency>
51 <!-- Import dependency management from Spring Boot -->
52 <groupId>org.springframework.boot</groupId>
53 <artifactId>spring-boot-dependencies</artifactId>
54 <version>${spring-boot-starter.version}</version>
55 <type>pom</type>
56 <scope>import</scope>
57 </dependency>
58 </dependencies>
59 </dependencyManagement>
60
61 <dependencies>
62 <dependency>
63 <groupId>org.springframework.boot</groupId>
64 <artifactId>spring-boot-starter-web</artifactId>
65 <version>${spring-boot-starter.version}</version>
Pawel Kasperkiewicz68016582020-02-06 11:54:06 +010066 <exclusions>
67 <exclusion>
68 <groupId>org.springframework.boot</groupId>
69 <artifactId>spring-boot-starter-logging</artifactId>
70 </exclusion>
71 </exclusions>
72 </dependency>
73 <dependency>
74 <groupId>org.springframework.boot</groupId>
75 <artifactId>spring-boot-starter-log4j2</artifactId>
76 <version>${spring-boot-starter-log4j2.version}</version>
Pawel Kasperkiewicz50f42bd2020-02-04 14:21:29 +010077 </dependency>
78 <dependency>
79 <groupId>org.springframework.boot</groupId>
80 <artifactId>spring-boot-starter-test</artifactId>
81 <version>${spring-boot-starter.version}</version>
82 <scope>test</scope>
83 <exclusions>
84 <exclusion>
85 <groupId>org.junit.vintage</groupId>
86 <artifactId>junit-vintage-engine</artifactId>
87 </exclusion>
88 </exclusions>
89 </dependency>
90 <dependency>
91 <groupId>org.mockito</groupId>
92 <artifactId>mockito-core</artifactId>
93 <version>${mockito-core.version}</version>
94 <scope>test</scope>
95 </dependency>
96 <dependency>
97 <groupId>org.assertj</groupId>
98 <artifactId>assertj-core</artifactId>
99 <version>${assertj-core.version}</version>
100 <scope>test</scope>
101 </dependency>
Paweldb979302020-02-05 11:24:54 +0100102 <dependency>
103 <groupId>org.springframework.boot</groupId>
104 <artifactId>spring-boot-starter-actuator</artifactId>
105 <version>${spring-boot-starter-actuator.version}</version>
106 </dependency>
Bartosz Gardziejewski4dd87392020-02-07 08:27:34 +0100107 <dependency>
108 <groupId>org.springdoc</groupId>
109 <artifactId>springdoc-openapi-ui</artifactId>
110 <version>${springdoc-openapi-ui.version}</version>
111 </dependency>
Bartosz Gardziejewskibddd4f02020-02-11 13:27:08 +0100112 <dependency>
113 <groupId>org.bouncycastle</groupId>
114 <artifactId>bcpkix-jdk15on</artifactId>
115 <version>${bouncycastle.version}</version>
116 </dependency>
117 <dependency>
118 <groupId>org.bouncycastle</groupId>
119 <artifactId>bcprov-jdk15on</artifactId>
120 <version>${bouncycastle.version}</version>
121 </dependency>
Pawel Kasperkiewicz50f42bd2020-02-04 14:21:29 +0100122 </dependencies>
123
124 <build>
125 <pluginManagement>
126 <plugins>
127 <plugin>
128 <groupId>org.springframework.boot</groupId>
129 <artifactId>spring-boot-maven-plugin</artifactId>
130 <version>${spring-boot-starter.version}</version>
131 </plugin>
132 <plugin>
133 <artifactId>maven-javadoc-plugin</artifactId>
134 <version>${maven-javadoc-plugin.version}</version>
135 </plugin>
136 <plugin>
137 <groupId>org.apache.maven.plugins</groupId>
138 <artifactId>maven-surefire-plugin</artifactId>
139 <version>${maven-surefire-plugin.version}</version>
140 </plugin>
Pawel Kasperkiewicz50f42bd2020-02-04 14:21:29 +0100141 </plugins>
142 </pluginManagement>
143 <plugins>
144 <plugin>
145 <groupId>org.springframework.boot</groupId>
146 <artifactId>spring-boot-maven-plugin</artifactId>
147 <executions>
148 <execution>
149 <goals>
150 <goal>repackage</goal>
151 </goals>
152 </execution>
Bartosz Gardziejewskic88b66b2020-02-12 07:49:02 +0100153 <execution>
154 <id>pre-integration-test</id>
155 <goals>
156 <goal>start</goal>
157 </goals>
158 </execution>
159 <execution>
160 <id>post-integration-test</id>
161 <goals>
162 <goal>stop</goal>
163 </goals>
164 </execution>
Pawel Kasperkiewicz50f42bd2020-02-04 14:21:29 +0100165 </executions>
166 </plugin>
167 <plugin>
168 <artifactId>maven-javadoc-plugin</artifactId>
169 <configuration>
170 <quiet>true</quiet>
171 <verbose>false</verbose>
172 <useStandardDocletOptions>false</useStandardDocletOptions>
Pawel8b1072c2020-02-10 13:03:38 +0100173 <javadocExecutable>${java.home}/bin/javadoc</javadocExecutable>
Pawel Kasperkiewicz50f42bd2020-02-04 14:21:29 +0100174 </configuration>
175 <executions>
176 <execution>
177 <id>aggregate</id>
178 <phase>site</phase>
179 <goals>
180 <goal>aggregate</goal>
181 </goals>
182 </execution>
183 <execution>
184 <id>attach-javadoc</id>
185 <goals>
186 <goal>jar</goal>
187 </goals>
188 </execution>
189 </executions>
190 </plugin>
Bartosz Gardziejewskic88b66b2020-02-12 07:49:02 +0100191 <plugin>
192 <groupId>org.springdoc</groupId>
193 <artifactId>springdoc-openapi-maven-plugin</artifactId>
194 <version>0.2</version>
195 <executions>
196 <execution>
197 <phase>integration-test</phase>
198 <goals>
199 <goal>generate</goal>
200 </goals>
201 </execution>
202 </executions>
203 <configuration>
204 <apiDocsUrl>${springdoc-openapi-maven-plugin.apiDocsUrl}</apiDocsUrl>
205 <outputFileName>api-docs.json</outputFileName>
206 <outputDir>${project.build.directory}</outputDir>
207 </configuration>
208 </plugin>
Pawel Kasperkiewicz50f42bd2020-02-04 14:21:29 +0100209 </plugins>
210 </build>
211
Pawel8b1072c2020-02-10 13:03:38 +0100212 <profiles>
213 <profile>
Tomasz Golabekb9dabed2020-02-11 09:12:09 +0100214 <id>docker-staging</id>
215 <properties>
216 <docker.tag>${project.version}-STAGING-${maven.build.timestamp}</docker.tag>
217 <docker.latest.tag>${project.version}-STAGING-latest</docker.latest.tag>
218 </properties>
219 </profile>
220
221 <profile>
Pawel8b1072c2020-02-10 13:03:38 +0100222 <id>docker</id>
223 <activation>
224 <activeByDefault>false</activeByDefault>
225 </activation>
226 <build>
227 <plugins>
228 <plugin>
229 <groupId>io.fabric8</groupId>
230 <artifactId>docker-maven-plugin</artifactId>
231 <version>${docker-maven-plugin.version}</version>
232 <executions>
233 <execution>
Tomasz Golabekb9dabed2020-02-11 09:12:09 +0100234 <id>clean-images</id>
235 <phase>pre-clean</phase>
Pawel8b1072c2020-02-10 13:03:38 +0100236 <goals>
Tomasz Golabekb9dabed2020-02-11 09:12:09 +0100237 <goal>remove</goal>
Pawel8b1072c2020-02-10 13:03:38 +0100238 </goals>
Tomasz Golabekb9dabed2020-02-11 09:12:09 +0100239 <configuration>
240 <removeAll>true</removeAll>
241 <image>onap/cert-service</image>
242 </configuration>
Pawel8b1072c2020-02-10 13:03:38 +0100243 </execution>
244 <execution>
Tomasz Golabekb9dabed2020-02-11 09:12:09 +0100245 <id>generate-images</id>
246 <phase>install</phase>
Pawel8b1072c2020-02-10 13:03:38 +0100247 <goals>
Tomasz Golabekb9dabed2020-02-11 09:12:09 +0100248 <goal>build</goal>
Pawel8b1072c2020-02-10 13:03:38 +0100249 </goals>
250 </execution>
Tomasz Golabekb9dabed2020-02-11 09:12:09 +0100251<!-- It has to be published on nexus firstly to uncomment integration tests-->
252<!-- <execution>-->
253<!-- <id>start</id>-->
254<!-- <phase>pre-integration-test</phase>-->
255<!-- <goals>-->
256<!-- <goal>start</goal>-->
257<!-- </goals>-->
258<!-- </execution>-->
259<!-- <execution>-->
260<!-- <id>stop</id>-->
261<!-- <phase>post-integration-test</phase>-->
262<!-- <goals>-->
263<!-- <goal>stop</goal>-->
264<!-- </goals>-->
265<!-- </execution>-->
266 <execution>
267 <id>push-images</id>
268 <phase>deploy</phase>
269 <goals>
270 <goal>push</goal>
271 </goals>
272 <configuration>
273 <image>onap/cert-service</image>
274 </configuration>
275 </execution>
Pawel8b1072c2020-02-10 13:03:38 +0100276 </executions>
277 <configuration>
Tomasz Golabekb9dabed2020-02-11 09:12:09 +0100278 <apiVersion>1.23</apiVersion>
279 <registry>nexus3.onap.org:10001</registry>
280 <authConfig>
281 <pull>
282 <username>docker</username>
283 <password>docker</password>
284 </pull>
285 </authConfig>
Pawel8b1072c2020-02-10 13:03:38 +0100286 <images>
287 <image>
Tomasz Golabekb9dabed2020-02-11 09:12:09 +0100288 <name>onap/cert-service</name>
289 <alias>cert-service</alias>
Pawel8b1072c2020-02-10 13:03:38 +0100290 <build>
291 <dockerFile>${project.basedir}/Dockerfile</dockerFile >
Tomasz Golabekb9dabed2020-02-11 09:12:09 +0100292 <tags>
293 <tag>${docker.tag}</tag>
294 </tags>
Pawel8b1072c2020-02-10 13:03:38 +0100295 </build>
296 <run>
297 <ports>
298 <port>8080:8080</port>
299 </ports>
300 <wait>
301 <!-- Check for this URL to return a 200 return code .... -->
302 <url>http://localhost:8080/actuator/health</url>
303 <time>120000</time>
304 </wait>
305 </run>
306 </image>
307 </images>
308 </configuration>
309 </plugin>
310 </plugins>
311 </build>
312 </profile>
313 </profiles>
Tomasz Golabek3b531c02020-02-12 08:56:23 +0100314
315 <distributionManagement>
316 <repository>
317 <id>ecomp-releases</id>
318 <name>AAF Release Repository</name>
319 <url>${nexusproxy}${releaseNexusPath}</url>
320 </repository>
321 <snapshotRepository>
322 <id>ecomp-snapshots</id>
323 <name>AAF Snapshot Repository</name>
324 <url>${nexusproxy}${snapshotNexusPath}</url>
325 </snapshotRepository>
326 <site>
327 <id>ecomp-site</id>
328 <url>dav:${nexusproxy}${sitePath}</url>
329 </site>
330 </distributionManagement>
331
Pawel Kasperkiewicz50f42bd2020-02-04 14:21:29 +0100332</project>