[MOD/Runtime] Fix build issues
[dcaegen2/platform.git] / mod / runtimeapi / runtime-web / pom.xml
1 <?xml version="1.0" encoding="UTF-8"?>
2 <!--
3 ============LICENSE_START=======================================================
4 Copyright (c) 2019-2022 AT&T Intellectual Property. All rights reserved.
5 Copyright (c) 2020 Nokia
6 ================================================================================
7 Licensed under the Apache License, Version 2.0 (the "License");
8 you may not use this file except in compliance with the License.
9 You may obtain a copy of the License at
10
11      http://www.apache.org/licenses/LICENSE-2.0
12
13 Unless required by applicable law or agreed to in writing, software
14 distributed under the License is distributed on an "AS IS" BASIS,
15 WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
16 See the License for the specific language governing permissions and
17 limitations under the License.
18 ============LICENSE_END=========================================================
19 -->
20 <project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
21     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     <parent>
24         <groupId>org.onap.dcaegen2.platform.mod</groupId>
25         <artifactId>runtimeapi</artifactId>
26         <version>1.3.2</version>
27     </parent>
28     <artifactId>runtime-web</artifactId>
29     <version>1.3.2-SNAPSHOT</version>
30     <packaging>jar</packaging>
31     <name>runtime-web</name>
32     <description>MOD Runtime Web Module</description>
33     <dependencies>
34         <dependency>
35             <groupId>org.onap.dcaegen2.platform.mod</groupId>
36             <artifactId>runtime-core</artifactId>
37             <version>1.3.2</version>
38         </dependency>
39         <dependency>
40             <groupId>org.springframework.boot</groupId>
41             <artifactId>spring-boot-starter-actuator</artifactId>
42         </dependency>
43         <dependency>
44             <groupId>org.springframework.boot</groupId>
45             <artifactId>spring-boot-starter-web</artifactId>
46         </dependency>
47
48         <dependency>
49             <groupId>org.springframework.boot</groupId>
50             <artifactId>spring-boot-devtools</artifactId>
51             <scope>runtime</scope>
52             <optional>true</optional>
53         </dependency>
54         <dependency>
55             <groupId>org.springframework.boot</groupId>
56             <artifactId>spring-boot-starter-test</artifactId>
57             <scope>test</scope>
58         </dependency>
59         <!-- https://mvnrepository.com/artifact/com.google.guava/guava -->
60         <dependency>
61             <groupId>com.google.guava</groupId>
62             <artifactId>guava</artifactId>
63             <version>28.0-jre</version>
64         </dependency>
65         <dependency>
66             <groupId>io.springfox</groupId>
67             <artifactId>springfox-boot-starter</artifactId>
68             <version>3.0.0</version>
69         </dependency>
70         <dependency>
71             <groupId>io.springfox</groupId>
72             <artifactId>springfox-swagger-ui</artifactId>
73             <version>3.0.0</version>
74         </dependency>
75         <dependency>
76             <groupId>org.apache.httpcomponents</groupId>
77             <artifactId>httpclient</artifactId>
78             <version>4.5.8</version>
79             <scope>test</scope>
80         </dependency>
81     </dependencies>
82
83     <build>
84         <plugins>
85             <plugin>
86                 <groupId>org.springframework.boot</groupId>
87                 <artifactId>spring-boot-maven-plugin</artifactId>
88                 <version>2.6.2</version>
89                 <executions>
90                     <execution>
91                         <goals>
92                             <goal>repackage</goal>
93                         </goals>
94                     </execution>
95                 </executions>
96             </plugin>
97             <plugin>
98                 <groupId>io.fabric8</groupId>
99                 <artifactId>docker-maven-plugin</artifactId>
100                 <configuration>
101                     <verbose>true</verbose>
102                     <pullRegistry>${docker.pull.registry}</pullRegistry>
103                     <pushRegistry>${docker.push.registry}</pushRegistry>
104                     <images>
105                         <image>
106                             <name>onap/${project.groupId}.${project.artifactId}</name>
107                             <registry>${onap.nexus.dockerregistry.daily}</registry>
108                             <build>
109                                 <from>openjdk:11-jre-slim</from>
110                                 <tags>
111                                     <tag>latest</tag>
112                                     <tag>${project.version}</tag>
113                                     <tag>${project.version}-${maven.build.timestamp}Z</tag>
114                                 </tags>
115                                 <assembly>
116                                     <descriptorRef>artifact</descriptorRef>
117                                 </assembly>
118                                 <runCmds>
119                                     <runCmd>apt-get update &amp;&amp; apt-get install -y wget</runCmd>
120                                     <runCmd>wget https://get.helm.sh/helm-v3.5.4-linux-amd64.tar.gz &amp;&amp; tar xvf helm-v3.5.4-linux-amd64.tar.gz &amp;&amp; mv linux-amd64/helm /usr/local/bin/</runCmd>
121                                     <runCmd>groupadd -r dcaemod &amp;&amp; useradd -ms /bin/bash dcaemod -g dcaemod &amp;&amp; mkdir -p /maven/data &amp;&amp; chown -R dcaemod:dcaemod /maven/data</runCmd>
122                                 </runCmds>
123                                 <workdir>/maven</workdir>
124                                 <volumes>
125                                     <volume>/tmp</volume>
126                                 </volumes>
127                                 <ports>
128                                     <port>9090</port>
129                                 </ports>
130                                 <user>dcaemod</user>
131                                 <entryPoint>
132                                     <exec>
133                                         <arg>java</arg>
134                                         <arg>-Djava.security.egd=file:/dev/./urandom</arg>
135                                         <arg>-jar</arg>
136                                         <arg>${project.artifactId}-${project.version}.${project.packaging}</arg>
137                                     </exec>
138                                 </entryPoint>
139                             </build>
140                         </image>
141                     </images>
142                 </configuration>
143                 <executions>
144                     <execution>
145                         <goals>
146                             <goal>build</goal>
147                             <goal>push</goal>
148                         </goals>
149                     </execution>
150                 </executions>
151             </plugin>
152         </plugins>
153     </build>
154
155 </project>