Chenfei Gao | 6ea2e1b | 2019-01-31 16:09:09 -0500 | [diff] [blame] | 1 | <!-- |
| 2 | ============LICENSE_START======================================================= |
Pamela Dragosh | 6059258 | 2021-02-24 07:16:07 -0500 | [diff] [blame] | 3 | Copyright (C) 2019,2021 AT&T Intellectual Property. All rights reserved. |
Rashmi Pujar | 5f91967 | 2022-02-04 21:49:30 -0500 | [diff] [blame] | 4 | Modifications Copyright (C) 2020-2022 Bell Canada. |
liamfallon | d4f570f | 2023-02-17 19:14:22 +0000 | [diff] [blame] | 5 | Modifications Copyright (C) 2022-2023 Nordix Foundation. |
Chenfei Gao | 6ea2e1b | 2019-01-31 16:09:09 -0500 | [diff] [blame] | 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 | |
| 19 | SPDX-License-Identifier: Apache-2.0 |
| 20 | ============LICENSE_END========================================================= |
| 21 | --> |
| 22 | |
| 23 | <project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" |
| 24 | xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd"> |
| 25 | |
| 26 | <modelVersion>4.0.0</modelVersion> |
| 27 | |
| 28 | <parent> |
| 29 | <groupId>org.onap.policy.api</groupId> |
Ram Krishna Verma | 1d4ce8d | 2020-02-05 16:28:33 -0500 | [diff] [blame] | 30 | <artifactId>api-packages</artifactId> |
saul.gill | 99e7c9a | 2024-04-26 09:24:35 +0100 | [diff] [blame] | 31 | <version>3.1.3-SNAPSHOT</version> |
Chenfei Gao | 6ea2e1b | 2019-01-31 16:09:09 -0500 | [diff] [blame] | 32 | </parent> |
| 33 | |
| 34 | <packaging>pom</packaging> |
| 35 | <artifactId>policy-api-docker</artifactId> |
Ram Krishna Verma | 1d4ce8d | 2020-02-05 16:28:33 -0500 | [diff] [blame] | 36 | <name>${project.artifactId}</name> |
Chenfei Gao | 6ea2e1b | 2019-01-31 16:09:09 -0500 | [diff] [blame] | 37 | <description>Policy api docker image</description> |
| 38 | |
| 39 | <properties> |
| 40 | <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding> |
| 41 | <project.reporting.outputEncoding>UTF-8</project.reporting.outputEncoding> |
| 42 | <dist.project.version>${project.version}</dist.project.version> |
| 43 | <docker.skip>false</docker.skip> |
| 44 | <docker.skip.build>false</docker.skip.build> |
| 45 | <docker.skip.push>false</docker.skip.push> |
danielhanrahan | 07ba043 | 2022-08-30 07:31:13 +0100 | [diff] [blame] | 46 | <docker.contextDir>${project.basedir}/src/main/docker</docker.contextDir> |
Chenfei Gao | 6ea2e1b | 2019-01-31 16:09:09 -0500 | [diff] [blame] | 47 | <maven.build.timestamp.format>yyyyMMdd'T'HHmm</maven.build.timestamp.format> |
| 48 | </properties> |
| 49 | |
| 50 | <build> |
| 51 | <finalName>${project.artifactId}-${project.version}</finalName> |
| 52 | <plugins> |
| 53 | <plugin> |
Taka Cho | 477b30c | 2021-08-09 14:35:06 -0400 | [diff] [blame] | 54 | <groupId>org.codehaus.gmaven</groupId> |
| 55 | <artifactId>groovy-maven-plugin</artifactId> |
Chenfei Gao | 6ea2e1b | 2019-01-31 16:09:09 -0500 | [diff] [blame] | 56 | <executions> |
| 57 | <execution> |
| 58 | <phase>validate</phase> |
| 59 | <goals> |
| 60 | <goal>execute</goal> |
| 61 | </goals> |
| 62 | <configuration> |
Taka Cho | 477b30c | 2021-08-09 14:35:06 -0400 | [diff] [blame] | 63 | <source>https://github.com/onap/policy-docker/raw/master/utils/groovy/docker-tag.groovy</source> |
Chenfei Gao | 6ea2e1b | 2019-01-31 16:09:09 -0500 | [diff] [blame] | 64 | </configuration> |
| 65 | </execution> |
| 66 | </executions> |
| 67 | </plugin> |
| 68 | |
| 69 | <plugin> |
danielhanrahan | 4be0395 | 2022-06-27 16:23:29 +0100 | [diff] [blame] | 70 | <groupId>io.github.git-commit-id</groupId> |
| 71 | <artifactId>git-commit-id-maven-plugin</artifactId> |
danielhanrahan | 4be0395 | 2022-06-27 16:23:29 +0100 | [diff] [blame] | 72 | </plugin> |
| 73 | |
| 74 | <plugin> |
Chenfei Gao | 6ea2e1b | 2019-01-31 16:09:09 -0500 | [diff] [blame] | 75 | <groupId>io.fabric8</groupId> |
| 76 | <artifactId>docker-maven-plugin</artifactId> |
Chenfei Gao | 6ea2e1b | 2019-01-31 16:09:09 -0500 | [diff] [blame] | 77 | |
| 78 | <configuration> |
| 79 | <verbose>true</verbose> |
| 80 | <apiVersion>1.23</apiVersion> |
| 81 | <pullRegistry>${docker.pull.registry}</pullRegistry> |
| 82 | <pushRegistry>${docker.push.registry}</pushRegistry> |
| 83 | |
| 84 | <images> |
| 85 | <image> |
| 86 | <name>onap/policy-api</name> |
| 87 | <build> |
| 88 | <cleanup>try</cleanup> |
danielhanrahan | 3c97dd4 | 2022-05-17 15:37:02 +0100 | [diff] [blame] | 89 | <dockerFile>${dockerFile}</dockerFile> |
danielhanrahan | 07ba043 | 2022-08-30 07:31:13 +0100 | [diff] [blame] | 90 | <contextDir>${docker.contextDir}</contextDir> |
Chenfei Gao | 6ea2e1b | 2019-01-31 16:09:09 -0500 | [diff] [blame] | 91 | <tags> |
| 92 | <tag>${project.version}</tag> |
| 93 | <tag>${project.version}-${maven.build.timestamp}</tag> |
Rashmi Pujar | 11e7349 | 2019-06-07 15:48:40 -0400 | [diff] [blame] | 94 | <tag>${project.docker.latest.minmax.tag.version}</tag> |
Chenfei Gao | 6ea2e1b | 2019-01-31 16:09:09 -0500 | [diff] [blame] | 95 | </tags> |
| 96 | <assembly> |
| 97 | <inline> |
| 98 | <dependencySets> |
| 99 | <dependencySet> |
| 100 | <includes> |
| 101 | <include>org.onap.policy.api:policy-api-tarball</include> |
| 102 | </includes> |
| 103 | <outputDirectory>/lib</outputDirectory> |
| 104 | <outputFileNameMapping>policy-api.tar.gz</outputFileNameMapping> |
| 105 | </dependencySet> |
Rashmi Pujar | 5f91967 | 2022-02-04 21:49:30 -0500 | [diff] [blame] | 106 | <dependencySet> |
| 107 | <includes> |
| 108 | <include>org.onap.policy.api:api-main</include> |
| 109 | </includes> |
| 110 | <outputFileNameMapping>api.jar</outputFileNameMapping> |
| 111 | </dependencySet> |
Chenfei Gao | 6ea2e1b | 2019-01-31 16:09:09 -0500 | [diff] [blame] | 112 | </dependencySets> |
| 113 | </inline> |
| 114 | </assembly> |
| 115 | </build> |
| 116 | </image> |
| 117 | </images> |
| 118 | </configuration> |
| 119 | |
| 120 | <executions> |
| 121 | <execution> |
| 122 | <id>clean-images</id> |
| 123 | <phase>pre-clean</phase> |
| 124 | <goals> |
| 125 | <goal>remove</goal> |
| 126 | </goals> |
| 127 | <configuration> |
| 128 | <removeAll>true</removeAll> |
| 129 | </configuration> |
| 130 | </execution> |
| 131 | |
| 132 | <execution> |
| 133 | <id>generate-images</id> |
| 134 | <phase>generate-sources</phase> |
| 135 | <goals> |
| 136 | <goal>build</goal> |
| 137 | </goals> |
| 138 | </execution> |
| 139 | |
| 140 | <execution> |
| 141 | <id>push-images</id> |
| 142 | <phase>deploy</phase> |
| 143 | <goals> |
| 144 | <goal>build</goal> |
| 145 | <goal>push</goal> |
| 146 | </goals> |
Chenfei Gao | 6ea2e1b | 2019-01-31 16:09:09 -0500 | [diff] [blame] | 147 | </execution> |
| 148 | </executions> |
| 149 | </plugin> |
| 150 | |
| 151 | <plugin> |
| 152 | <groupId>org.apache.maven.plugins</groupId> |
| 153 | <artifactId>maven-deploy-plugin</artifactId> |
| 154 | <configuration> |
| 155 | <skip>true</skip> |
| 156 | </configuration> |
| 157 | </plugin> |
| 158 | </plugins> |
| 159 | </build> |
| 160 | |
| 161 | <dependencies> |
| 162 | <dependency> |
| 163 | <groupId>org.onap.policy.api</groupId> |
| 164 | <artifactId>policy-api-tarball</artifactId> |
| 165 | <version>${project.version}</version> |
| 166 | <classifier>tarball</classifier> |
| 167 | <type>tar.gz</type> |
| 168 | </dependency> |
| 169 | </dependencies> |
danielhanrahan | 3c97dd4 | 2022-05-17 15:37:02 +0100 | [diff] [blame] | 170 | </project> |