elinuxhenrik | f507d92 | 2020-03-19 14:52:24 +0100 | [diff] [blame] | 1 | <?xml version="1.0" encoding="UTF-8"?> |
PatrikBuhr | 0bcfde8 | 2020-04-21 08:37:07 +0200 | [diff] [blame] | 2 | <!--<![CDATA[ |
elinuxhenrik | f507d92 | 2020-03-19 14:52:24 +0100 | [diff] [blame] | 3 | ========================LICENSE_START================================= |
| 4 | O-RAN-SC |
| 5 | %% |
| 6 | Copyright (C) 2019 AT&T Intellectual Property |
| 7 | Modifications Copyright (C) 2020 Nordix Foundation |
| 8 | %% |
| 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 |
| 12 | |
| 13 | http://www.apache.org/licenses/LICENSE-2.0 |
| 14 | |
| 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=================================== |
| 21 | ]]>--> |
| 22 | <project |
| 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> |
| 27 | <parent> |
| 28 | <groupId>org.o-ran-sc.portal.nonrtric.controlpanel</groupId> |
| 29 | <artifactId>nonrtric-controlpanel-parent</artifactId> |
elinuxhenrik | 1be62af | 2020-12-03 15:21:36 +0100 | [diff] [blame^] | 30 | <version>2.2.0-SNAPSHOT</version> |
elinuxhenrik | f507d92 | 2020-03-19 14:52:24 +0100 | [diff] [blame] | 31 | </parent> |
| 32 | <artifactId>nonrtric-controlpanel-be</artifactId> |
elinuxhenrik | 22cfc3d | 2020-03-30 08:53:58 +0200 | [diff] [blame] | 33 | <name>Non-RT RIC Control Panel Webapp backend</name> |
elinuxhenrik | f507d92 | 2020-03-19 14:52:24 +0100 | [diff] [blame] | 34 | <properties> |
elinuxhenrik | 0e656f1 | 2020-03-24 09:09:54 +0100 | [diff] [blame] | 35 | <epsdk-fw.version>2.6.0</epsdk-fw.version> |
elinuxhenrik | f507d92 | 2020-03-19 14:52:24 +0100 | [diff] [blame] | 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> |
elinuxhenrik | 0e656f1 | 2020-03-24 09:09:54 +0100 | [diff] [blame] | 41 | <jacoco-maven-plugin.version>0.8.5</jacoco-maven-plugin.version> |
| 42 | <docker-maven-plugin.version>0.33.0</docker-maven-plugin.version> |
RehanRaza | 60e8bb7 | 2020-10-08 16:12:06 +0200 | [diff] [blame] | 43 | <json.version>20190722</json.version> |
elinuxhenrik | f507d92 | 2020-03-19 14:52:24 +0100 | [diff] [blame] | 44 | <!-- Set by Jenkins --> |
| 45 | <build.number>0</build.number> |
| 46 | </properties> |
| 47 | <repositories> |
| 48 | <repository> |
| 49 | <id>onap-releases</id> |
| 50 | <name>ONAP - Release Repository</name> |
| 51 | <url>https://nexus.onap.org/content/repositories/releases</url> |
| 52 | </repository> |
| 53 | </repositories> |
| 54 | <dependencies> |
elinuxhenrik | f507d92 | 2020-03-19 14:52:24 +0100 | [diff] [blame] | 55 | <dependency> |
| 56 | <groupId>org.springframework.boot</groupId> |
| 57 | <artifactId>spring-boot-starter-web</artifactId> |
| 58 | </dependency> |
| 59 | <dependency> |
PatrikBuhr | 0bcfde8 | 2020-04-21 08:37:07 +0200 | [diff] [blame] | 60 | <groupId>org.springframework.boot</groupId> |
| 61 | <artifactId>spring-boot-starter-webflux</artifactId> |
| 62 | </dependency> |
| 63 | <dependency> |
elinuxhenrik | f507d92 | 2020-03-19 14:52:24 +0100 | [diff] [blame] | 64 | <groupId>org.slf4j</groupId> |
| 65 | <artifactId>slf4j-api</artifactId> |
| 66 | </dependency> |
| 67 | <dependency> |
| 68 | <groupId>org.apache.axis2</groupId> |
| 69 | <artifactId>axis2-kernel</artifactId> |
| 70 | <version>${apache-axis2.version}</version> |
| 71 | </dependency> |
elinuxhenrik | 6b4c6ef | 2020-11-23 16:39:20 +0100 | [diff] [blame] | 72 | <dependency> |
| 73 | <groupId>org.projectlombok</groupId> |
| 74 | <artifactId>lombok</artifactId> |
| 75 | <scope>provided</scope> |
| 76 | </dependency> |
elinuxhenrik | f507d92 | 2020-03-19 14:52:24 +0100 | [diff] [blame] | 77 | <!-- Bridge uses of Apache commons logging, like EPSDK-FW --> |
| 78 | <dependency> |
| 79 | <groupId>org.slf4j</groupId> |
| 80 | <artifactId>jcl-over-slf4j</artifactId> |
| 81 | </dependency> |
| 82 | <dependency> |
| 83 | <groupId>ch.qos.logback</groupId> |
| 84 | <artifactId>logback-classic</artifactId> |
| 85 | </dependency> |
| 86 | <dependency> |
| 87 | <groupId>ch.qos.logback</groupId> |
| 88 | <artifactId>logback-core</artifactId> |
| 89 | </dependency> |
| 90 | <dependency> |
| 91 | <groupId>io.springfox</groupId> |
| 92 | <artifactId>springfox-swagger2</artifactId> |
| 93 | <version>${springfox.version}</version> |
| 94 | </dependency> |
| 95 | <dependency> |
| 96 | <groupId>io.springfox</groupId> |
| 97 | <artifactId>springfox-swagger-ui</artifactId> |
| 98 | <version>${springfox.version}</version> |
| 99 | </dependency> |
| 100 | <dependency> |
| 101 | <groupId>org.immutables</groupId> |
| 102 | <artifactId>value</artifactId> |
| 103 | <version>${immutable.version}</version> |
| 104 | <scope>provided</scope> |
| 105 | </dependency> |
| 106 | <dependency> |
| 107 | <groupId>org.immutables</groupId> |
| 108 | <artifactId>gson</artifactId> |
| 109 | <version>${immutable.version}</version> |
| 110 | </dependency> |
RehanRaza | 60e8bb7 | 2020-10-08 16:12:06 +0200 | [diff] [blame] | 111 | <dependency> |
| 112 | <groupId>org.json</groupId> |
| 113 | <artifactId>json</artifactId> |
| 114 | <version>${json.version}</version> |
| 115 | </dependency> |
elinuxhenrik | f507d92 | 2020-03-19 14:52:24 +0100 | [diff] [blame] | 116 | <!-- Test dependencies --> |
| 117 | <!-- Mockito supports development, not just testing --> |
| 118 | <dependency> |
| 119 | <groupId>org.mockito</groupId> |
| 120 | <artifactId>mockito-core</artifactId> |
| 121 | <scope>test</scope> |
| 122 | </dependency> |
| 123 | <dependency> |
| 124 | <groupId>org.springframework.boot</groupId> |
| 125 | <artifactId>spring-boot-starter-test</artifactId> |
| 126 | <scope>test</scope> |
| 127 | </dependency> |
| 128 | <dependency> |
| 129 | <groupId>org.junit.jupiter</groupId> |
| 130 | <artifactId>junit-jupiter-api</artifactId> |
| 131 | <scope>test</scope> |
| 132 | </dependency> |
| 133 | <dependency> |
| 134 | <groupId>org.junit.jupiter</groupId> |
| 135 | <artifactId>junit-jupiter-engine</artifactId> |
| 136 | <scope>test</scope> |
| 137 | </dependency> |
| 138 | <dependency> |
| 139 | <groupId>org.junit.platform</groupId> |
| 140 | <artifactId>junit-platform-launcher</artifactId> |
| 141 | <scope>test</scope> |
| 142 | </dependency> |
PatrikBuhr | 0bcfde8 | 2020-04-21 08:37:07 +0200 | [diff] [blame] | 143 | <dependency> |
| 144 | <groupId>io.projectreactor</groupId> |
| 145 | <artifactId>reactor-test</artifactId> |
| 146 | <scope>test</scope> |
| 147 | </dependency> |
| 148 | <dependency> |
| 149 | <groupId>com.squareup.okhttp3</groupId> |
| 150 | <artifactId>mockwebserver</artifactId> |
| 151 | <scope>test</scope> |
| 152 | </dependency> |
elinuxhenrik | f507d92 | 2020-03-19 14:52:24 +0100 | [diff] [blame] | 153 | </dependencies> |
| 154 | <build> |
| 155 | <plugins> |
Lathish | aab2df1 | 2020-05-14 11:41:33 +0100 | [diff] [blame] | 156 | <plugin> |
| 157 | <groupId>org.codehaus.mojo</groupId> |
| 158 | <artifactId>build-helper-maven-plugin</artifactId> |
| 159 | <executions> |
| 160 | <execution> |
| 161 | <id>add-source</id> |
| 162 | <phase>generate-sources</phase> |
| 163 | <goals> |
| 164 | <goal>add-source</goal> |
| 165 | </goals> |
| 166 | <configuration> |
| 167 | <sources> |
| 168 | <source>${project.build.directory}/generated-sources/annotations/</source> |
| 169 | </sources> |
| 170 | </configuration> |
| 171 | </execution> |
| 172 | </executions> |
| 173 | </plugin> |
elinuxhenrik | f507d92 | 2020-03-19 14:52:24 +0100 | [diff] [blame] | 174 | <plugin> |
| 175 | <groupId>org.springframework.boot</groupId> |
| 176 | <artifactId>spring-boot-maven-plugin</artifactId> |
| 177 | </plugin> |
| 178 | <plugin> |
| 179 | <groupId>net.revelc.code.formatter</groupId> |
| 180 | <artifactId>formatter-maven-plugin</artifactId> |
| 181 | <version>${formatter-maven-plugin.version}</version> |
| 182 | <configuration> |
| 183 | <configFile>${project.basedir}/eclipse-formatter.xml</configFile> |
| 184 | </configuration> |
| 185 | <!-- https://code.revelc.net/formatter-maven-plugin/ use |
| 186 | mvn formatter:format spotless:apply process-sources --> |
| 187 | </plugin> |
| 188 | <plugin> |
| 189 | <groupId>com.diffplug.spotless</groupId> |
| 190 | <artifactId>spotless-maven-plugin</artifactId> |
| 191 | <version>${spotless-maven-plugin.version}</version> |
| 192 | <configuration> |
| 193 | <java> |
| 194 | <removeUnusedImports /> |
| 195 | <importOrder> |
| 196 | <order>com,java,javax,org</order> |
| 197 | </importOrder> |
| 198 | </java> |
| 199 | </configuration> |
| 200 | <!-- https://github.com/diffplug/spotless/tree/master/plugin-maven |
| 201 | use mvn spotless:apply to rewrite source files use mvn spotless:check to |
| 202 | validate source files --> |
| 203 | </plugin> |
elinuxhenrik | f507d92 | 2020-03-19 14:52:24 +0100 | [diff] [blame] | 204 | <!-- Add the build number to the jar manifest. Spring-Boot uses a complex |
| 205 | packaging process that makes access to the original Manifest.MF very difficult. |
| 206 | However, Java provides access to the implementation version for a package, |
| 207 | so cram the build number into there. --> |
| 208 | <plugin> |
| 209 | <groupId>org.apache.maven.plugins</groupId> |
| 210 | <artifactId>maven-jar-plugin</artifactId> |
| 211 | <configuration> |
| 212 | <archive> |
| 213 | <manifest> |
| 214 | <addDefaultImplementationEntries>true</addDefaultImplementationEntries> |
| 215 | </manifest> |
| 216 | <manifestEntries> |
| 217 | <Implementation-Version>${project.version}-b${build.number}</Implementation-Version> |
| 218 | </manifestEntries> |
| 219 | </archive> |
| 220 | </configuration> |
| 221 | </plugin> |
| 222 | <plugin> |
| 223 | <artifactId>maven-resources-plugin</artifactId> |
| 224 | <executions> |
| 225 | <execution> |
| 226 | <id>copy-resources</id> |
| 227 | <phase>validate</phase> |
| 228 | <goals> |
| 229 | <goal>copy-resources</goal> |
| 230 | </goals> |
| 231 | <configuration> |
| 232 | <outputDirectory>${project.build.directory}/classes/resources/</outputDirectory> |
| 233 | <resources> |
| 234 | <resource> |
| 235 | <directory>${project.parent.basedir}/webapp-frontend/dist/controlpanelApp/</directory> |
| 236 | </resource> |
| 237 | </resources> |
| 238 | </configuration> |
| 239 | </execution> |
| 240 | </executions> |
| 241 | </plugin> |
| 242 | <!-- do not deploy a jar or pom file --> |
| 243 | <plugin> |
| 244 | <groupId>org.apache.maven.plugins</groupId> |
| 245 | <artifactId>maven-deploy-plugin</artifactId> |
| 246 | <configuration> |
| 247 | <skip>true</skip> |
| 248 | </configuration> |
| 249 | </plugin> |
| 250 | <plugin> |
| 251 | <groupId>org.jacoco</groupId> |
| 252 | <artifactId>jacoco-maven-plugin</artifactId> |
elinuxhenrik | 0e656f1 | 2020-03-24 09:09:54 +0100 | [diff] [blame] | 253 | <version>${jacoco-maven-plugin.version}</version> |
elinuxhenrik | f507d92 | 2020-03-19 14:52:24 +0100 | [diff] [blame] | 254 | <executions> |
| 255 | <execution> |
| 256 | <id>default-prepare-agent</id> |
| 257 | <goals> |
| 258 | <goal>prepare-agent</goal> |
| 259 | </goals> |
| 260 | </execution> |
| 261 | <execution> |
| 262 | <id>default-report</id> |
| 263 | <phase>prepare-package</phase> |
| 264 | <goals> |
| 265 | <goal>report</goal> |
| 266 | </goals> |
| 267 | </execution> |
| 268 | </executions> |
| 269 | </plugin> |
| 270 | <!-- https://stackoverflow.com/questions/39126226/fabric8-springboot-full-example --> |
| 271 | <plugin> |
| 272 | <groupId>io.fabric8</groupId> |
| 273 | <artifactId>docker-maven-plugin</artifactId> |
elinuxhenrik | 0e656f1 | 2020-03-24 09:09:54 +0100 | [diff] [blame] | 274 | <version>${docker-maven-plugin.version}</version> |
elinuxhenrik | f507d92 | 2020-03-19 14:52:24 +0100 | [diff] [blame] | 275 | <configuration> |
| 276 | <verbose>true</verbose> |
| 277 | <!-- environment variables supplied by Jenkins --> |
| 278 | <pullRegistry>${env.CONTAINER_PULL_REGISTRY}</pullRegistry> |
| 279 | <pushRegistry>${env.CONTAINER_PUSH_REGISTRY}</pushRegistry> |
| 280 | <images> |
| 281 | <image> |
| 282 | <!-- Specify a tag to avoid default tag "latest" --> |
| 283 | <!-- Avoid maven artifact name here --> |
| 284 | <name>o-ran-sc/nonrtric-controlpanel:${project.version}</name> |
| 285 | <build> |
| 286 | <from>openjdk:11-jre-slim</from> |
| 287 | <tags> |
| 288 | <!-- Add tag with build number --> |
| 289 | <tag>${project.version}</tag> |
| 290 | </tags> |
| 291 | <assembly> |
| 292 | <descriptorRef>artifact</descriptorRef> |
| 293 | </assembly> |
| 294 | <runCmds> |
| 295 | <!-- Ensure logs dir exists and is world writable --> |
| 296 | <runCmd>mkdir /logs</runCmd> |
| 297 | <runCmd>chmod -R 777 /logs</runCmd> |
| 298 | </runCmds> |
| 299 | <cmd> |
| 300 | <!-- Include maven dir on classpath for prop files --> |
| 301 | <exec> |
| 302 | <arg>java</arg> |
| 303 | <arg>-Xms128m</arg> |
| 304 | <arg>-Xmx256m</arg> |
| 305 | <arg>-cp</arg> |
| 306 | <arg>maven:maven/${project.artifactId}-${project.version}.${project.packaging}</arg> |
elinuxhenrik | 22cfc3d | 2020-03-30 08:53:58 +0200 | [diff] [blame] | 307 | <arg>-Dloader.main=org.oransc.portal.nonrtric.controlpanel.ControlPanelApplication</arg> |
elinuxhenrik | f507d92 | 2020-03-19 14:52:24 +0100 | [diff] [blame] | 308 | <arg>-Djava.security.egd=file:/dev/./urandom</arg> |
| 309 | <arg>org.springframework.boot.loader.PropertiesLauncher</arg> |
| 310 | </exec> |
| 311 | </cmd> |
| 312 | </build> |
| 313 | </image> |
| 314 | </images> |
| 315 | </configuration> |
| 316 | <!-- build Docker images in install phase, push in deploy phase --> |
| 317 | <executions> |
| 318 | <execution> |
| 319 | <goals> |
| 320 | <goal>build</goal> |
| 321 | <goal>push</goal> |
| 322 | </goals> |
| 323 | </execution> |
| 324 | </executions> |
| 325 | </plugin> |
| 326 | </plugins> |
| 327 | </build> |
| 328 | </project> |