Add k8s-upload-profile node type and logic.
[ccsdk/cds.git] / ms / blueprintsprocessor / application / pom.xml
1 <?xml version="1.0" encoding="UTF-8"?>
2 <!--
3   ~  Copyright © 2017-2018 AT&T Intellectual Property.
4   ~
5   ~  Modifications Copyright © 2018 IBM.
6   ~  Modifications Copyright © 2019 Bell Canada.
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   -->
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     <parent>
25         <groupId>org.onap.ccsdk.cds.blueprintsprocessor</groupId>
26         <artifactId>parent</artifactId>
27         <version>1.0.0-SNAPSHOT</version>
28         <relativePath>../parent</relativePath>
29     </parent>
30
31     <artifactId>application</artifactId>
32     <packaging>jar</packaging>
33
34     <name>Blueprints Processor Application</name>
35     <description>Blueprints Processor Application</description>
36
37     <properties>
38         <assembly.id>maven</assembly.id>
39         <name.space>org.onap.ccsdk.cds</name.space>
40         <serviceArtifactName>blueprintsprocessor</serviceArtifactName>
41         <image.name>onap/ccsdk-blueprintsprocessor</image.name>
42         <docker.push.phase>deploy</docker.push.phase>
43         <docker.verbose>true</docker.verbose>
44         <ccsdk.project.version>${project.version}</ccsdk.project.version>
45         <ccsdk.build.timestamp>${maven.build.timestamp}</ccsdk.build.timestamp>
46     </properties>
47
48     <dependencies>
49         <dependency>
50             <groupId>org.onap.ccsdk.cds.blueprintsprocessor</groupId>
51             <artifactId>blueprint-core</artifactId>
52             <exclusions>
53                 <exclusion>
54                     <groupId>org.springframework.boot</groupId>
55                     <artifactId>spring-boot-starter-logging</artifactId>
56                 </exclusion>
57             </exclusions>
58         </dependency>
59         <dependency>
60             <groupId>org.springframework.boot</groupId>
61             <artifactId>spring-boot-starter-security</artifactId>
62             <exclusions>
63                 <exclusion>
64                     <groupId>org.springframework.boot</groupId>
65                     <artifactId>spring-boot-starter-logging</artifactId>
66                 </exclusion>
67             </exclusions>
68         </dependency>
69
70         <!-- Error Catalog Services -->
71         <dependency>
72             <groupId>org.onap.ccsdk.cds.error.catalog</groupId>
73             <artifactId>error-catalog-services</artifactId>
74         </dependency>
75
76         <!-- North Bound -->
77         <dependency>
78             <groupId>org.onap.ccsdk.cds.blueprintsprocessor</groupId>
79             <artifactId>designer-api</artifactId>
80         </dependency>
81         <dependency>
82             <groupId>org.onap.ccsdk.cds.blueprintsprocessor</groupId>
83             <artifactId>resource-api</artifactId>
84         </dependency>
85         <dependency>
86             <groupId>org.onap.ccsdk.cds.blueprintsprocessor</groupId>
87             <artifactId>selfservice-api</artifactId>
88         </dependency>
89         <dependency>
90             <groupId>org.onap.ccsdk.cds.blueprintsprocessor</groupId>
91             <artifactId>configs-api</artifactId>
92         </dependency>
93         <dependency>
94             <groupId>org.onap.ccsdk.cds.blueprintsprocessor</groupId>
95             <artifactId>health-api</artifactId>
96         </dependency>
97         <dependency>
98             <groupId>org.onap.ccsdk.cds.blueprintsprocessor</groupId>
99             <artifactId>health-api-common</artifactId>
100         </dependency>
101
102         <!-- Functions -->
103         <dependency>
104             <groupId>org.onap.ccsdk.cds.blueprintsprocessor.functions</groupId>
105             <artifactId>python-executor</artifactId>
106         </dependency>
107         <dependency>
108             <groupId>org.onap.ccsdk.cds.blueprintsprocessor.functions</groupId>
109             <artifactId>restful-executor</artifactId>
110         </dependency>
111         <dependency>
112             <groupId>org.onap.ccsdk.cds.blueprintsprocessor.functions</groupId>
113             <artifactId>ansible-awx-executor</artifactId>
114         </dependency>
115         <dependency>
116             <groupId>org.onap.ccsdk.cds.blueprintsprocessor.functions</groupId>
117             <artifactId>netconf-executor</artifactId>
118         </dependency>
119         <dependency>
120             <groupId>org.onap.ccsdk.cds.blueprintsprocessor.functions</groupId>
121             <artifactId>restconf-executor</artifactId>
122         </dependency>
123         <dependency>
124             <groupId>org.onap.ccsdk.cds.blueprintsprocessor.functions</groupId>
125             <artifactId>cli-executor</artifactId>
126         </dependency>
127         <dependency>
128             <groupId>org.onap.ccsdk.cds.blueprintsprocessor.functions</groupId>
129             <artifactId>config-snapshots</artifactId>
130         </dependency>
131         <dependency>
132             <groupId>org.onap.ccsdk.cds.blueprintsprocessor.functions</groupId>
133             <artifactId>k8s-profile-upload</artifactId>
134         </dependency>
135         <dependency>
136             <groupId>com.h2database</groupId>
137             <artifactId>h2</artifactId>
138         </dependency>
139         <dependency>
140             <groupId>org.powermock</groupId>
141             <artifactId>powermock-api-mockito2</artifactId>
142             <scope>test</scope>
143         </dependency>
144         <dependency>
145             <groupId>org.springframework.boot</groupId>
146             <artifactId>spring-boot-starter-test</artifactId>
147             <scope>test</scope>
148         </dependency>
149         <dependency>
150             <groupId>org.jetbrains.kotlin</groupId>
151             <artifactId>kotlin-test-junit</artifactId>
152             <scope>test</scope>
153         </dependency>
154         <dependency>
155             <groupId>io.projectreactor</groupId>
156             <artifactId>reactor-test</artifactId>
157             <scope>test</scope>
158         </dependency>
159         <!-- BEGIN UAT -->
160         <dependency>
161             <groupId>org.skyscreamer</groupId>
162             <artifactId>jsonassert</artifactId>
163         </dependency>
164         <dependency>
165             <groupId>org.yaml</groupId>
166             <artifactId>snakeyaml</artifactId>
167         </dependency>
168         <dependency>
169             <groupId>com.nhaarman.mockitokotlin2</groupId>
170             <artifactId>mockito-kotlin</artifactId>
171             <!-- It's unusual but 'compile' here is the right scope since mockito is being used at runtime by
172                  the UatServices (/api/v1/uat/spy and /api/v1/uat/verify endpoints) -->
173             <scope>compile</scope>
174         </dependency>
175         <dependency>
176             <groupId>com.schibsted.spt.data</groupId>
177             <artifactId>jslt</artifactId>
178         </dependency>
179         <dependency>
180             <groupId>org.apache.httpcomponents</groupId>
181             <artifactId>httpclient</artifactId>
182             <version>${apache.httpcomponents.client.version}</version>
183         </dependency>
184         <dependency>
185             <groupId>org.apache.httpcomponents</groupId>
186             <artifactId>httpmime</artifactId>
187             <version>${apache.httpcomponents.client.version}</version>
188         </dependency>
189         <dependency>
190             <groupId>com.github.tomakehurst</groupId>
191             <artifactId>wiremock-jre8</artifactId>
192             <version>2.25.0</version>
193             <scope>test</scope>
194         </dependency>
195         <!-- END UAT -->
196         <dependency>
197             <groupId>ch.qos.logback</groupId>
198             <artifactId>logback-classic</artifactId>
199         </dependency>
200
201     </dependencies>
202
203     <build>
204         <resources>
205             <resource>
206                 <!--config and resource files -->
207                 <directory>${basedir}/etc</directory>
208                 <targetPath>${basedir}/target/etc</targetPath>
209                 <filtering>true</filtering>
210                 <includes>
211                     <include>**/*</include>
212                 </includes>
213             </resource>
214             <resource>
215                 <!--config and resource files -->
216                 <directory>${basedir}/src/main/resources</directory>
217                 <targetPath>${basedir}/target/src/main/resources</targetPath>
218                 <filtering>true</filtering>
219                 <includes>
220                     <include>**/*</include>
221                 </includes>
222             </resource>
223             <resource>
224                 <directory>src/main/resources</directory>
225                 <includes>
226                     <include>**/*</include>
227                 </includes>
228                 <filtering>true</filtering>
229             </resource>
230         </resources>
231         <plugins>
232             <plugin>
233                 <artifactId>maven-resources-plugin</artifactId>
234                 <version>2.6</version>
235                 <executions>
236                     <execution>
237                         <id>copy-dockerfile</id>
238                         <goals>
239                             <goal>copy-resources</goal>
240                         </goals><!-- here the phase you need -->
241                         <phase>validate</phase>
242                         <configuration>
243                             <outputDirectory>${basedir}/target/docker-stage</outputDirectory>
244                             <resources>
245                                 <resource>
246                                     <directory>src/main/docker</directory>
247                                     <includes>
248                                         <include>*</include>
249                                     </includes>
250                                     <filtering>true</filtering>
251                                 </resource>
252                             </resources>
253                         </configuration>
254                     </execution>
255                 </executions>
256             </plugin>
257             <plugin>
258                 <groupId>org.apache.maven.plugins</groupId>
259                 <artifactId>maven-antrun-plugin</artifactId>
260                 <executions>
261                     <execution>
262                         <id>ant-test</id>
263                         <phase>package</phase>
264                         <configuration>
265                             <tasks>
266                                 <fixcrlf srcdir="${basedir}" eol="unix" includes="**/*.sh, **/*.source"/>
267                             </tasks>
268                         </configuration>
269                         <goals>
270                             <goal>run</goal>
271                         </goals>
272                     </execution>
273                 </executions>
274             </plugin>
275             <plugin><!--build the final artifact for docker deployment -->
276                 <artifactId>maven-assembly-plugin</artifactId>
277                 <version>3.1.0</version>
278                 <configuration>
279                     <!-- <skipAssembly>${skip.assembly}</skipAssembly> -->
280                     <outputDirectory>${basedir}/target/docker-stage</outputDirectory>
281                     <descriptors>
282                         <descriptor>src/main/docker/distribution.xml</descriptor>
283                     </descriptors>
284                     <tarLongFileMode>posix</tarLongFileMode>
285                 </configuration>
286                 <executions>
287                     <execution>
288                         <id>${assembly.id}</id>
289                         <phase>package</phase>
290                         <goals>
291                             <goal>single</goal>
292                         </goals>
293                     </execution>
294                 </executions>
295             </plugin>
296             <plugin>
297                 <groupId>org.codehaus.groovy.maven</groupId>
298                 <artifactId>gmaven-plugin</artifactId>
299                 <version>1.0</version>
300                 <executions>
301                     <execution>
302                         <phase>validate</phase>
303                         <goals>
304                             <goal>execute</goal>
305                         </goals>
306                         <configuration>
307                             <source>${basedir}/../../../TagVersion.groovy</source>
308                         </configuration>
309                     </execution>
310                 </executions>
311             </plugin>
312             <plugin>
313                 <artifactId>maven-compiler-plugin</artifactId>
314                 <version>3.1</version>
315                 <configuration>
316                     <source>1.8</source>
317                     <target>1.8</target>
318                 </configuration>
319             </plugin>
320             <plugin>
321                 <groupId>pl.project13.maven</groupId>
322                 <artifactId>git-commit-id-plugin</artifactId>
323             </plugin>
324         </plugins>
325     </build>
326
327     <profiles>
328         <profile>
329             <id>docker</id>
330             <build>
331                 <plugins>
332                     <plugin>
333                         <groupId>io.fabric8</groupId>
334                         <artifactId>docker-maven-plugin</artifactId>
335                         <version>0.26.1</version>
336                         <inherited>false</inherited>
337                         <configuration>
338                             <images>
339                                 <image>
340                                     <name>${image.name}</name>
341                                     <build>
342                                         <cleanup>try</cleanup>
343                                         <dockerFileDir>${basedir}/target/docker-stage</dockerFileDir>
344                                         <tags>
345                                             <tag>${project.docker.latestminortag.version}</tag>
346                                             <tag>${project.docker.latestfulltag.version}</tag>
347                                             <tag>${project.docker.latesttagtimestamp.version}</tag>
348                                         </tags>
349                                     </build>
350                                 </image>
351                             </images>
352                             <verbose>true</verbose>
353                         </configuration>
354                         <executions>
355                             <execution>
356                                 <id>generate-images</id>
357                                 <phase>package</phase>
358                                 <goals>
359                                     <goal>build</goal>
360                                 </goals>
361                             </execution>
362                             <execution>
363                                 <id>push-images</id>
364                                 <phase>${docker.push.phase}</phase>
365                                 <goals>
366                                     <goal>build</goal>
367                                     <goal>push</goal>
368                                 </goals>
369                             </execution>
370                         </executions>
371                     </plugin>
372                 </plugins>
373             </build>
374         </profile>
375     </profiles>
376 </project>