1 <?xml version="1.0" encoding="UTF-8"?>
3 ========================LICENSE_START=================================
6 Copyright (C) 2019 AT&T Intellectual Property
7 Modifications Copyright (C) 2020 Nordix Foundation
9 Licensed under the Apache License, Version 2.0 (the "License");
10 you may not use this file except in compliance with the License.
11 You may obtain a copy of the License at
13 http://www.apache.org/licenses/LICENSE-2.0
15 Unless required by applicable law or agreed to in writing, software
16 distributed under the License is distributed on an "AS IS" BASIS,
17 WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
18 See the License for the specific language governing permissions and
19 limitations under the License.
20 ========================LICENSE_END===================================
23 xmlns="http://maven.apache.org/POM/4.0.0"
24 xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
25 xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
26 <modelVersion>4.0.0</modelVersion>
28 <groupId>org.o-ran-sc.portal.nonrtric.controlpanel</groupId>
29 <artifactId>nonrtric-controlpanel-parent</artifactId>
30 <version>1.0.0-SNAPSHOT</version>
32 <artifactId>nonrtric-controlpanel-be</artifactId>
33 <name>Non-RT RIC Control Panel Webapp backend</name>
35 <epsdk-fw.version>2.6.0</epsdk-fw.version>
36 <springfox.version>2.9.2</springfox.version>
37 <immutable.version>2.7.1</immutable.version>
38 <apache-axis2.version>1.7.9</apache-axis2.version>
39 <formatter-maven-plugin.version>2.8.1</formatter-maven-plugin.version>
40 <spotless-maven-plugin.version>1.18.0</spotless-maven-plugin.version>
41 <jacoco-maven-plugin.version>0.8.5</jacoco-maven-plugin.version>
42 <docker-maven-plugin.version>0.33.0</docker-maven-plugin.version>
43 <!-- Set by Jenkins -->
44 <build.number>0</build.number>
48 <id>onap-releases</id>
49 <name>ONAP - Release Repository</name>
50 <url>https://nexus.onap.org/content/repositories/releases</url>
54 <!-- Platform components -->
56 <groupId>org.onap.portal.sdk</groupId>
57 <artifactId>epsdk-fw</artifactId>
58 <version>${epsdk-fw.version}</version>
61 <groupId>commons-logging</groupId>
62 <artifactId>commons-logging</artifactId>
65 <groupId>log4j</groupId>
66 <artifactId>log4j</artifactId>
69 <groupId>log4j</groupId>
70 <artifactId>apache-log4j-extras</artifactId>
73 <groupId>org.slf4j</groupId>
74 <artifactId>slf4j-log4j12</artifactId>
77 <groupId>junit</groupId>
78 <artifactId>junit</artifactId>
81 <groupId>commons-fileupload</groupId>
82 <artifactId>commons-fileupload</artifactId>
85 <groupId>commons-beanutils</groupId>
86 <artifactId>commons-beanutils</artifactId>
88 <!-- EELF omits "test" scope on this dependency -->
90 <groupId>org.powermock</groupId>
91 <artifactId>powermock-module-junit4</artifactId>
93 <!-- EELF omits "test" scope on this dependency -->
95 <groupId>org.powermock</groupId>
96 <artifactId>powermock-api-mockito</artifactId>
101 <groupId>org.springframework.boot</groupId>
102 <artifactId>spring-boot-starter-security</artifactId>
105 <groupId>org.springframework.boot</groupId>
106 <artifactId>spring-boot-starter-web</artifactId>
109 <groupId>org.springframework.boot</groupId>
110 <artifactId>spring-boot-starter-webflux</artifactId>
113 <groupId>org.slf4j</groupId>
114 <artifactId>slf4j-api</artifactId>
117 <groupId>org.apache.axis2</groupId>
118 <artifactId>axis2-kernel</artifactId>
119 <version>${apache-axis2.version}</version>
121 <!-- Bridge uses of Apache commons logging, like EPSDK-FW -->
123 <groupId>org.slf4j</groupId>
124 <artifactId>jcl-over-slf4j</artifactId>
127 <groupId>ch.qos.logback</groupId>
128 <artifactId>logback-classic</artifactId>
131 <groupId>ch.qos.logback</groupId>
132 <artifactId>logback-core</artifactId>
135 <groupId>io.springfox</groupId>
136 <artifactId>springfox-swagger2</artifactId>
137 <version>${springfox.version}</version>
140 <groupId>io.springfox</groupId>
141 <artifactId>springfox-swagger-ui</artifactId>
142 <version>${springfox.version}</version>
145 <groupId>org.immutables</groupId>
146 <artifactId>value</artifactId>
147 <version>${immutable.version}</version>
148 <scope>provided</scope>
151 <groupId>org.immutables</groupId>
152 <artifactId>gson</artifactId>
153 <version>${immutable.version}</version>
155 <!-- Test dependencies -->
156 <!-- Mockito supports development, not just testing -->
158 <groupId>org.mockito</groupId>
159 <artifactId>mockito-core</artifactId>
163 <groupId>org.springframework.boot</groupId>
164 <artifactId>spring-boot-starter-test</artifactId>
168 <groupId>org.junit.jupiter</groupId>
169 <artifactId>junit-jupiter-api</artifactId>
173 <groupId>org.junit.jupiter</groupId>
174 <artifactId>junit-jupiter-engine</artifactId>
178 <groupId>org.junit.platform</groupId>
179 <artifactId>junit-platform-launcher</artifactId>
183 <groupId>io.projectreactor</groupId>
184 <artifactId>reactor-test</artifactId>
188 <groupId>com.squareup.okhttp3</groupId>
189 <artifactId>mockwebserver</artifactId>
196 <groupId>org.springframework.boot</groupId>
197 <artifactId>spring-boot-maven-plugin</artifactId>
200 <groupId>net.revelc.code.formatter</groupId>
201 <artifactId>formatter-maven-plugin</artifactId>
202 <version>${formatter-maven-plugin.version}</version>
204 <configFile>${project.basedir}/eclipse-formatter.xml</configFile>
206 <!-- https://code.revelc.net/formatter-maven-plugin/ use
207 mvn formatter:format spotless:apply process-sources -->
210 <groupId>com.diffplug.spotless</groupId>
211 <artifactId>spotless-maven-plugin</artifactId>
212 <version>${spotless-maven-plugin.version}</version>
215 <removeUnusedImports />
217 <order>com,java,javax,org</order>
221 <!-- https://github.com/diffplug/spotless/tree/master/plugin-maven
222 use mvn spotless:apply to rewrite source files use mvn spotless:check to
223 validate source files -->
225 <!-- Add the build number to the jar manifest. Spring-Boot uses a complex
226 packaging process that makes access to the original Manifest.MF very difficult.
227 However, Java provides access to the implementation version for a package,
228 so cram the build number into there. -->
230 <groupId>org.apache.maven.plugins</groupId>
231 <artifactId>maven-jar-plugin</artifactId>
235 <addDefaultImplementationEntries>true</addDefaultImplementationEntries>
238 <Implementation-Version>${project.version}-b${build.number}</Implementation-Version>
244 <artifactId>maven-resources-plugin</artifactId>
247 <id>copy-resources</id>
248 <phase>validate</phase>
250 <goal>copy-resources</goal>
253 <outputDirectory>${project.build.directory}/classes/resources/</outputDirectory>
256 <directory>${project.parent.basedir}/webapp-frontend/dist/controlpanelApp/</directory>
263 <!-- do not deploy a jar or pom file -->
265 <groupId>org.apache.maven.plugins</groupId>
266 <artifactId>maven-deploy-plugin</artifactId>
272 <groupId>org.jacoco</groupId>
273 <artifactId>jacoco-maven-plugin</artifactId>
274 <version>${jacoco-maven-plugin.version}</version>
277 <id>default-prepare-agent</id>
279 <goal>prepare-agent</goal>
283 <id>default-report</id>
284 <phase>prepare-package</phase>
291 <!-- https://stackoverflow.com/questions/39126226/fabric8-springboot-full-example -->
293 <groupId>io.fabric8</groupId>
294 <artifactId>docker-maven-plugin</artifactId>
295 <version>${docker-maven-plugin.version}</version>
297 <verbose>true</verbose>
298 <!-- environment variables supplied by Jenkins -->
299 <pullRegistry>${env.CONTAINER_PULL_REGISTRY}</pullRegistry>
300 <pushRegistry>${env.CONTAINER_PUSH_REGISTRY}</pushRegistry>
303 <!-- Specify a tag to avoid default tag "latest" -->
304 <!-- Avoid maven artifact name here -->
305 <name>o-ran-sc/nonrtric-controlpanel:${project.version}</name>
307 <from>openjdk:11-jre-slim</from>
309 <!-- Add tag with build number -->
310 <tag>${project.version}</tag>
313 <descriptorRef>artifact</descriptorRef>
316 <!-- Ensure logs dir exists and is world writable -->
317 <runCmd>mkdir /logs</runCmd>
318 <runCmd>chmod -R 777 /logs</runCmd>
321 <!-- Include maven dir on classpath for prop files -->
327 <arg>maven:maven/${project.artifactId}-${project.version}.${project.packaging}</arg>
328 <arg>-Dloader.main=org.oransc.portal.nonrtric.controlpanel.ControlPanelApplication</arg>
329 <arg>-Djava.security.egd=file:/dev/./urandom</arg>
330 <arg>org.springframework.boot.loader.PropertiesLauncher</arg>
337 <!-- build Docker images in install phase, push in deploy phase -->