blob: 215ec75804cb9393d9cab839415924c1bc9de86a [file] [log] [blame]
PatrikBuhra2bc79c2019-10-29 13:39:00 +01001<?xml version="1.0" encoding="UTF-8"?>
2<!--<![CDATA[
3========================LICENSE_START=================================
4O-RAN-SC
5%%
6Copyright (C) 2019 AT&T Intellectual Property
7%%
8Licensed under the Apache License, Version 2.0 (the "License");
9you may not use this file except in compliance with the License.
10You may obtain a copy of the License at
11
12 http://www.apache.org/licenses/LICENSE-2.0
13
14Unless required by applicable law or agreed to in writing, software
15distributed under the License is distributed on an "AS IS" BASIS,
16WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
17See the License for the specific language governing permissions and
18limitations under the License.
19========================LICENSE_END===================================
20]]>-->
21<project xmlns="http://maven.apache.org/POM/4.0.0"
22 xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
23 xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
24 <modelVersion>4.0.0</modelVersion>
25 <parent>
PatrikBuhr6e59d4a2019-11-06 13:31:57 +010026 <groupId>org.o-ran-sc.nonrt.ric-dashboard</groupId>
PatrikBuhra2bc79c2019-10-29 13:39:00 +010027 <artifactId>ric-dash-parent</artifactId>
PatrikBuhr6e59d4a2019-11-06 13:31:57 +010028 <version>1.0.0-SNAPSHOT</version>
PatrikBuhra2bc79c2019-10-29 13:39:00 +010029 </parent>
30 <artifactId>ric-dash-be</artifactId>
PatrikBuhr6e59d4a2019-11-06 13:31:57 +010031 <name>NonRT RIC Dashboard Webapp backend</name>
PatrikBuhra2bc79c2019-10-29 13:39:00 +010032 <properties>
33 <springfox.version>2.9.2</springfox.version>
34 <!-- Set by Jenkins -->
35 <build.number>0</build.number>
36 </properties>
37 <repositories>
38 <repository>
39 <id>onap-releases</id>
40 <name>ONAP - Release Repository</name>
41 <url>https://nexus.onap.org/content/repositories/releases</url>
42 </repository>
43 </repositories>
44 <dependencies>
45 <!-- Platform components -->
46 <dependency>
47 <groupId>org.o-ran-sc.ric.plt.a1controller.client</groupId>
48 <artifactId>a1-controller-client</artifactId>
49 <version>0.1.0-SNAPSHOT</version>
50 </dependency>
51 <dependency>
52 <groupId>org.onap.portal.sdk</groupId>
53 <artifactId>epsdk-fw</artifactId>
54 <version>2.6.0</version>
55 <exclusions>
56 <exclusion>
57 <groupId>commons-logging</groupId>
58 <artifactId>commons-logging</artifactId>
59 </exclusion>
60 <exclusion>
61 <groupId>log4j</groupId>
62 <artifactId>log4j</artifactId>
63 </exclusion>
64 <exclusion>
65 <groupId>log4j</groupId>
66 <artifactId>apache-log4j-extras</artifactId>
67 </exclusion>
68 <exclusion>
69 <groupId>org.slf4j</groupId>
70 <artifactId>slf4j-log4j12</artifactId>
71 </exclusion>
72 <exclusion>
73 <groupId>junit</groupId>
74 <artifactId>junit</artifactId>
75 </exclusion>
76 <exclusion>
77 <groupId>commons-fileupload</groupId>
78 <artifactId>commons-fileupload</artifactId>
79 </exclusion>
80 <exclusion>
81 <groupId>commons-beanutils</groupId>
82 <artifactId>commons-beanutils</artifactId>
83 </exclusion>
84 <!-- EELF omits "test" scope on this dependency -->
85 <exclusion>
86 <groupId>org.powermock</groupId>
87 <artifactId>powermock-module-junit4</artifactId>
88 </exclusion>
89 <!-- EELF omits "test" scope on this dependency -->
90 <exclusion>
91 <groupId>org.powermock</groupId>
92 <artifactId>powermock-api-mockito</artifactId>
93 </exclusion>
94 </exclusions>
95 </dependency>
96 <dependency>
97 <groupId>org.springframework.boot</groupId>
98 <artifactId>spring-boot-starter-security</artifactId>
99 </dependency>
100 <dependency>
101 <groupId>org.springframework.boot</groupId>
102 <artifactId>spring-boot-starter-web</artifactId>
103 </dependency>
104 <dependency>
105 <groupId>org.slf4j</groupId>
106 <artifactId>slf4j-api</artifactId>
107 </dependency>
108 <!-- Bridge uses of Apache commons logging, like EPSDK-FW -->
109 <dependency>
110 <groupId>org.slf4j</groupId>
111 <artifactId>jcl-over-slf4j</artifactId>
112 </dependency>
113 <dependency>
114 <groupId>ch.qos.logback</groupId>
115 <artifactId>logback-classic</artifactId>
116 </dependency>
117 <dependency>
118 <groupId>ch.qos.logback</groupId>
119 <artifactId>logback-core</artifactId>
120 </dependency>
121 <dependency>
122 <groupId>io.springfox</groupId>
123 <artifactId>springfox-swagger2</artifactId>
124 <version>${springfox.version}</version>
125 </dependency>
126 <dependency>
127 <groupId>io.springfox</groupId>
128 <artifactId>springfox-swagger-ui</artifactId>
129 <version>${springfox.version}</version>
130 </dependency>
131 <!-- Test dependencies -->
132 <!-- Mockito supports development, not just testing -->
133 <dependency>
134 <groupId>org.mockito</groupId>
135 <artifactId>mockito-core</artifactId>
136 <scope>test</scope>
137 </dependency>
138 <dependency>
139 <groupId>org.springframework.boot</groupId>
140 <artifactId>spring-boot-starter-test</artifactId>
141 <scope>test</scope>
142 </dependency>
143 <dependency>
144 <groupId>org.junit.jupiter</groupId>
145 <artifactId>junit-jupiter-api</artifactId>
146 <scope>test</scope>
147 </dependency>
148 <dependency>
149 <groupId>org.junit.jupiter</groupId>
150 <artifactId>junit-jupiter-engine</artifactId>
151 <scope>test</scope>
152 </dependency>
153 <dependency>
154 <groupId>org.junit.platform</groupId>
155 <artifactId>junit-platform-launcher</artifactId>
156 <!-- Override Spring-Boot choice for Eclipse -->
157 <version>1.4.2</version>
158 <scope>test</scope>
159 </dependency>
160 </dependencies>
161 <build>
162 <plugins>
163 <plugin>
164 <groupId>org.springframework.boot</groupId>
165 <artifactId>spring-boot-maven-plugin</artifactId>
166 </plugin>
167 <plugin>
168 <!-- Most configuration and all execution is inherited -->
169 <groupId>org.codehaus.mojo</groupId>
170 <artifactId>license-maven-plugin</artifactId>
171 <configuration>
172 <roots>
173 <root>src</root>
174 </roots>
175 <excludes>
176 <exclude>**/*.json</exclude>
177 </excludes>
178 </configuration>
179 </plugin>
180 <!-- Add the build number to the jar manifest. Spring-Boot uses a complex
181 packaging process that makes access to the original Manifest.MF very difficult.
182 However, Java provides access to the implementation version for a package,
183 so cram the build number into there. -->
184 <plugin>
185 <groupId>org.apache.maven.plugins</groupId>
186 <artifactId>maven-jar-plugin</artifactId>
187 <configuration>
188 <archive>
189 <manifest>
190 <addDefaultImplementationEntries>true</addDefaultImplementationEntries>
191 </manifest>
192 <manifestEntries>
193 <Implementation-Version>${project.version}-b${build.number}</Implementation-Version>
194 </manifestEntries>
195 </archive>
196 </configuration>
197 </plugin>
198 <plugin>
199 <artifactId>maven-resources-plugin</artifactId>
200 <executions>
201 <execution>
202 <id>copy-resources</id>
203 <phase>validate</phase>
204 <goals>
205 <goal>copy-resources</goal>
206 </goals>
207 <configuration>
208 <outputDirectory>${project.build.directory}/classes/resources/</outputDirectory>
209 <resources>
210 <resource>
211 <directory>${project.parent.basedir}/webapp-frontend/dist/dashApp/</directory>
212 </resource>
213 </resources>
214 </configuration>
215 </execution>
216 </executions>
217 </plugin>
218 <!-- do not deploy a jar or pom file -->
219 <plugin>
220 <groupId>org.apache.maven.plugins</groupId>
221 <artifactId>maven-deploy-plugin</artifactId>
222 <configuration>
223 <skip>true</skip>
224 </configuration>
225 </plugin>
226 <plugin>
227 <groupId>org.jacoco</groupId>
228 <artifactId>jacoco-maven-plugin</artifactId>
229 <version>0.8.4</version>
230 <executions>
231 <execution>
232 <id>default-prepare-agent</id>
233 <goals>
234 <goal>prepare-agent</goal>
235 </goals>
236 </execution>
237 <execution>
238 <id>default-report</id>
239 <phase>prepare-package</phase>
240 <goals>
241 <goal>report</goal>
242 </goals>
243 </execution>
244 </executions>
245 </plugin>
246 <!-- https://stackoverflow.com/questions/39126226/fabric8-springboot-full-example -->
247 <plugin>
248 <groupId>io.fabric8</groupId>
249 <artifactId>docker-maven-plugin</artifactId>
250 <version>0.30.0</version>
251 <configuration>
252 <verbose>true</verbose>
253 <!-- environment variables supplied by Jenkins -->
254 <pullRegistry>${env.CONTAINER_PULL_REGISTRY}</pullRegistry>
255 <pushRegistry>${env.CONTAINER_PUSH_REGISTRY}</pushRegistry>
256 <images>
257 <image>
258 <!-- Specify a tag to avoid default tag "latest" -->
259 <!-- Avoid maven artifact name here -->
wriderb6d7de82019-11-18 23:47:42 -0500260 <name>o-ran-sc/nonrtric-dashboard:${project.version}</name>
PatrikBuhra2bc79c2019-10-29 13:39:00 +0100261 <build>
262 <from>openjdk:11-jre-slim</from>
263 <tags>
264 <!-- Add tag with build number -->
265 <tag>${project.version}</tag>
266 </tags>
267 <assembly>
268 <descriptorRef>artifact</descriptorRef>
269 </assembly>
270 <runCmds>
271 <!-- Ensure logs dir exists and is world writable -->
272 <runCmd>mkdir /logs</runCmd>
273 <runCmd>chmod -R 777 /logs</runCmd>
274 </runCmds>
275 <cmd>
276 <!-- Include maven dir on classpath for prop files -->
277 <exec>
278 <arg>java</arg>
279 <arg>-Xms128m</arg>
280 <arg>-Xmx256m</arg>
281 <arg>-cp</arg>
282 <arg>maven:maven/${project.artifactId}-${project.version}.${project.packaging}</arg>
283 <arg>-Dloader.main=org.oransc.ric.portal.dashboard.DashboardApplication</arg>
284 <arg>-Djava.security.egd=file:/dev/./urandom</arg>
285 <arg>org.springframework.boot.loader.PropertiesLauncher</arg>
286 </exec>
287 </cmd>
288 </build>
289 </image>
290 </images>
291 </configuration>
292 <!-- build Docker images in install phase, push in deploy phase -->
293 <executions>
294 <execution>
295 <goals>
296 <goal>build</goal>
297 <goal>push</goal>
298 </goals>
299 </execution>
300 </executions>
301 </plugin>
302 </plugins>
303 </build>
304</project>