TCAgen2 container CrashLoopBackOff error fix
[dcaegen2/analytics/tca-gen2.git] / dcae-analytics / dcae-analytics-tca-web / pom.xml
1 <?xml version="1.0" encoding="UTF-8"?>
2 <!--
3   ~ ================================================================================
4   ~ Copyright (c) 2018-2020 AT&T Intellectual Property. All rights reserved.
5   ~ ================================================================================
6   ~ Modifications Copyright (C) 2019 IBM
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
23 <project xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
24          xmlns="http://maven.apache.org/POM/4.0.0"
25          xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
26
27     <modelVersion>4.0.0</modelVersion>
28
29     <parent>
30         <groupId>org.onap.dcaegen2.analytics.tca-gen2</groupId>
31         <artifactId>dcae-analytics</artifactId>
32         <version>1.2.2-SNAPSHOT</version>
33     </parent>
34
35     <artifactId>dcae-analytics-tca-web</artifactId>
36     <packaging>jar</packaging>
37
38     <!-- THE MODULE CONTAINS WEB RELATED CODE FOR TCA -->
39     <name>DCAE Analytics TCA Web</name>
40     <description>Contains Web related code for TCA</description>
41
42     <properties>
43         <main.basedir>${project.parent.basedir}</main.basedir>
44         <docker.image.name>onap/${project.groupId}.${project.artifactId}</docker.image.name>
45         <maven.build.timestamp.format>yyyyMMdd'T'HHmmss</maven.build.timestamp.format>  
46     </properties>
47
48     <dependencies>
49
50         <!-- PROJECT DEPENDENCIES -->
51         <dependency>
52             <groupId>${project.groupId}</groupId>
53             <artifactId>dcae-analytics-web</artifactId>
54         </dependency>
55         <dependency>
56             <groupId>${project.groupId}</groupId>
57             <artifactId>dcae-analytics-tca-core</artifactId>
58         </dependency>
59
60
61         <!-- SPRING DEPENDENCIES -->
62         <dependency>
63             <groupId>org.springframework.boot</groupId>
64             <artifactId>spring-boot-starter-actuator</artifactId>
65             <exclusions>
66                 <exclusion>
67                     <groupId>io.undertow</groupId>
68                     <artifactId>undertow-core</artifactId>
69               </exclusion>
70             </exclusions>
71
72         </dependency>
73         <dependency>
74             <groupId>io.micrometer</groupId>
75             <artifactId>micrometer-registry-prometheus</artifactId>
76         </dependency>
77
78
79         <!-- SPRING CONFIGURATION META DATA ANNOTATION PROCESSOR -->
80         <dependency>
81             <groupId>org.springframework.boot</groupId>
82             <artifactId>spring-boot-configuration-processor</artifactId>
83             <optional>true</optional>
84         </dependency>
85
86         <!-- CODE GENERATION -->
87         <dependency>
88             <groupId>org.projectlombok</groupId>
89             <artifactId>lombok</artifactId>
90             <scope>provided</scope>
91         </dependency>
92
93         <!-- FIND BUGS -->
94         <dependency>
95             <groupId>com.google.code.findbugs</groupId>
96             <artifactId>jsr305</artifactId>
97         </dependency>
98         <dependency>
99             <groupId>com.google.code.findbugs</groupId>
100             <artifactId>annotations</artifactId>
101         </dependency>
102
103         <!-- REST API SWAGGER -->
104         <dependency>
105             <groupId>io.springfox</groupId>
106             <artifactId>springfox-swagger2</artifactId>
107         </dependency>
108         <dependency>
109             <groupId>io.springfox</groupId>
110             <artifactId>springfox-swagger-ui</artifactId>
111         </dependency>
112
113         <!-- TEST DEPENDENCIES -->
114         <dependency>
115             <groupId>${project.groupId}</groupId>
116             <artifactId>dcae-analytics-test</artifactId>
117         </dependency>
118         <!-- https://mvnrepository.com/artifact/io.undertow/undertow-core -->
119       <dependency>
120         <groupId>io.undertow</groupId>
121         <artifactId>undertow-core</artifactId>
122       </dependency>
123         <dependency>
124             <groupId>io.netty</groupId>
125             <artifactId>netty-handler</artifactId>
126             <version>4.1.54.Final</version>
127         </dependency>
128         <dependency>
129             <groupId>io.netty</groupId>
130             <artifactId>netty-handler-proxy</artifactId>
131             <version>4.1.54.Final</version>
132         </dependency>
133
134     </dependencies>
135
136     <dependencyManagement>
137         <dependencies>
138             <dependency>
139                 <groupId>org.springframework</groupId>
140                 <artifactId>spring-core</artifactId>
141                 <version>5.1.12.RELEASE</version>
142             </dependency>
143         </dependencies>
144     </dependencyManagement>
145
146     <build>
147         <resources>
148             <resource>
149                 <directory>${project.basedir}/src/main/resources</directory>
150             </resource>
151             <resource>
152                 <directory>${project.build.directory}/git</directory>
153             </resource>
154         </resources>
155
156         <plugins>
157             <plugin>
158                 <groupId>pl.project13.maven</groupId>
159                 <artifactId>git-commit-id-plugin</artifactId>
160             </plugin>
161             <plugin>
162                 <groupId>org.springframework.boot</groupId>
163                 <artifactId>spring-boot-maven-plugin</artifactId>
164             </plugin>
165             <!-- DOCKER PLUGIN -->
166             <plugin>
167                    <groupId>com.spotify</groupId>
168                    <artifactId>dockerfile-maven-plugin</artifactId>
169                    <version>1.4.10</version>
170                      <configuration>
171                           <contextDirectory>${project.basedir}</contextDirectory>
172                           <repository>${docker.repository}/${docker.image.name}</repository>
173                           <useMavenSettingsForAuth>true</useMavenSettingsForAuth>
174                        <buildArgs>
175                              <PROJECT_BUILD_DIR_NAME>target</PROJECT_BUILD_DIR_NAME>
176                              <DEPENDENCIES_DIR>${dependency.dir.name}</DEPENDENCIES_DIR>
177                              <DOCKER_ARTIFACT_DIR>/opt</DOCKER_ARTIFACT_DIR>
178                              <FINAL_JAR>${project.build.finalName}.jar</FINAL_JAR>
179                        </buildArgs>
180                  </configuration>
181                  <executions>
182                         <execution>
183                                 <id>build-image</id>
184                                 <phase>install</phase>
185                                 <goals>
186                                         <goal>build</goal>
187                                 </goals>
188                         </execution>
189                         <execution>
190                                <id>tag-version</id>
191                                <phase>install</phase>
192                                <goals>
193                                       <goal>tag</goal>
194                                       <goal>push</goal>
195                                </goals>
196                                 <configuration>
197                                         <tag>${project.version}</tag>
198                                 </configuration>
199                         </execution>
200                         <execution>
201                                <id>tag-version-ts</id>
202                                <phase>install</phase>
203                                <goals>
204                                       <goal>tag</goal>
205                                       <goal>push</goal>
206                                </goals>
207                                 <configuration>
208                                         <tag>${project.version}-${maven.build.timestamp}Z</tag>
209                                 </configuration>
210                         </execution>
211                 </executions>
212            </plugin>
213         </plugins>
214     </build>
215 </project>