blob: 9f96b2fcd0a2967b22aea3c0a4dc3fec70542d0d [file] [log] [blame]
ChrisC025301d2017-01-31 11:40:03 +01001<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
Anaël Clossonf15b97e2017-02-08 10:46:48 +01002 xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
Rob Daughertye8000512018-08-01 00:02:38 -04003
ChrisC025301d2017-01-31 11:40:03 +01004 <modelVersion>4.0.0</modelVersion>
5
6 <parent>
Arthur Martella22e015f2018-02-22 14:24:40 -05007 <groupId>org.onap.so</groupId>
ChrisC025301d2017-01-31 11:40:03 +01008 <artifactId>packages</artifactId>
Benjamin, Max (mb388a)5a6a6de2018-07-30 15:56:09 -04009 <version>1.3.0-SNAPSHOT</version>
ChrisC025301d2017-01-31 11:40:03 +010010 </parent>
11
12 <packaging>pom</packaging>
ChrisC025301d2017-01-31 11:40:03 +010013 <artifactId>docker</artifactId>
Rob Daughertye8000512018-08-01 00:02:38 -040014 <name>Docker Images</name>
15 <description>Docker Images</description>
ChrisC025301d2017-01-31 11:40:03 +010016
17 <properties>
18 <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
19 <project.reporting.outputEncoding>UTF-8</project.reporting.outputEncoding>
Rob Daughertye8000512018-08-01 00:02:38 -040020 <so.project.version>${project.version}</so.project.version>
21 <docker.skip>false</docker.skip>
22 <docker.skip.build>false</docker.skip.build>
23 <docker.skip.push>false</docker.skip.push>
Rob Daughertyf5893182018-04-05 16:09:32 -040024 <docker.pull.registry>nexus3.onap.org:10001</docker.pull.registry>
25 <docker.push.registry>nexus3.onap.org:10003</docker.push.registry>
ChrisC025301d2017-01-31 11:40:03 +010026 </properties>
27
28 <build>
29 <finalName>${project.artifactId}-${project.version}</finalName>
30 <plugins>
31 <plugin>
Rob Daughertye8000512018-08-01 00:02:38 -040032 <groupId>org.codehaus.groovy.maven</groupId>
33 <artifactId>gmaven-plugin</artifactId>
34 <version>1.0</version>
Anaël Closson13e0d022017-02-14 11:17:50 +010035 <executions>
36 <execution>
Rob Daughertye8000512018-08-01 00:02:38 -040037 <phase>validate</phase>
Anaël Closson13e0d022017-02-14 11:17:50 +010038 <goals>
Rob Daughertye8000512018-08-01 00:02:38 -040039 <goal>execute</goal>
Anaël Closson13e0d022017-02-14 11:17:50 +010040 </goals>
Anaël Closson13e0d022017-02-14 11:17:50 +010041 <configuration>
Rob Daughertye8000512018-08-01 00:02:38 -040042 <source>
43 println 'Project version: ' + project.properties['so.project.version'];
44 def versionArray;
45 if ( project.properties['so.project.version'] != null ) {
46 versionArray = project.properties['so.project.version'].split('-');
47 }
48
49 if ( project.properties['so.project.version'].endsWith("-SNAPSHOT") ) {
50 project.properties['project.docker.latesttag.version']=versionArray[0] + "-SNAPSHOT-latest";
51 } else {
Rob Daugherty568e98f2018-08-01 10:09:48 -040052 project.properties['project.docker.latesttag.version']=versionArray[0] + "-STAGING-latest";
Rob Daughertye8000512018-08-01 00:02:38 -040053 }
54
55 println 'New tag for docker: ' + project.properties['project.docker.latesttag.version'];
56 </source>
Anaël Closson13e0d022017-02-14 11:17:50 +010057 </configuration>
58 </execution>
59 </executions>
60 </plugin>
Rob Daughertye8000512018-08-01 00:02:38 -040061
Anaël Closson13e0d022017-02-14 11:17:50 +010062 <plugin>
ChrisC025301d2017-01-31 11:40:03 +010063 <groupId>io.fabric8</groupId>
64 <artifactId>docker-maven-plugin</artifactId>
Rob Daughertyf5893182018-04-05 16:09:32 -040065 <version>0.19.1</version>
ChrisC025301d2017-01-31 11:40:03 +010066
67 <configuration>
68 <verbose>true</verbose>
69 <apiVersion>1.23</apiVersion>
Rob Daughertyf5893182018-04-05 16:09:32 -040070 <pullRegistry>${docker.pull.registry}</pullRegistry>
71 <pushRegistry>${docker.push.registry}</pushRegistry>
Anaël Clossonf15b97e2017-02-08 10:46:48 +010072
ChrisC025301d2017-01-31 11:40:03 +010073 <images>
74 <image>
Rob Daughertye8000512018-08-01 00:02:38 -040075 <name>so/base-image:1.0</name>
ChrisC025301d2017-01-31 11:40:03 +010076 <build>
77 <cleanup>try</cleanup>
78 <dockerFileDir>docker-files</dockerFileDir>
Rob Daughertye8000512018-08-01 00:02:38 -040079 <dockerFile>Dockerfile.so-base-image</dockerFile>
ChrisC025301d2017-01-31 11:40:03 +010080 </build>
81 </image>
82 <image>
Rob Daughertye8000512018-08-01 00:02:38 -040083 <name>so/catalog-db-adapter</name>
ChrisC025301d2017-01-31 11:40:03 +010084 <build>
ChrisC025301d2017-01-31 11:40:03 +010085 <cleanup>try</cleanup>
86 <dockerFileDir>docker-files</dockerFileDir>
Rob Daughertye8000512018-08-01 00:02:38 -040087 <dockerFile>Dockerfile.so-app</dockerFile>
JulienBec3f8ddf2017-03-08 02:19:21 -080088 <tags>
Rob Daughertye8000512018-08-01 00:02:38 -040089 <tag>${project.version}</tag>
90 <tag>${project.version}-${maven.build.timestamp}</tag>
Determe, Sebastien (sd378r)94ee9252017-05-02 03:53:18 -070091 <tag>${project.docker.latesttag.version}</tag>
JulienBec3f8ddf2017-03-08 02:19:21 -080092 </tags>
ChrisC025301d2017-01-31 11:40:03 +010093 <assembly>
Rob Daughertye8000512018-08-01 00:02:38 -040094 <inline>
95 <dependencySets>
96 <dependencySet>
97 <includes>
98 <include>org.onap.so.adapters:mso-catalog-db-adapter</include>
99 </includes>
100 <outputFileNameMapping>app.jar</outputFileNameMapping>
101 </dependencySet>
102 </dependencySets>
103 </inline>
ChrisC025301d2017-01-31 11:40:03 +0100104 </assembly>
105 </build>
106 </image>
Rob Daughertye8000512018-08-01 00:02:38 -0400107 <image>
Rob Daugherty8b090d12018-08-02 20:55:30 -0400108 <name>so/request-db-adapter</name>
Rob Daughertye8000512018-08-01 00:02:38 -0400109 <build>
110 <cleanup>try</cleanup>
111 <dockerFileDir>docker-files</dockerFileDir>
112 <dockerFile>Dockerfile.so-app</dockerFile>
113 <tags>
114 <tag>${project.version}</tag>
115 <tag>${project.version}-${maven.build.timestamp}</tag>
116 <tag>${project.docker.latesttag.version}</tag>
117 </tags>
118 <assembly>
119 <inline>
120 <dependencySets>
121 <dependencySet>
122 <includes>
123 <include>org.onap.so.adapters:mso-requests-db-adapter</include>
124 </includes>
125 <outputFileNameMapping>app.jar</outputFileNameMapping>
126 </dependencySet>
127 </dependencySets>
128 </inline>
129 </assembly>
130 </build>
131 </image>
132 <image>
133 <name>so/sdnc-adapter</name>
134 <build>
135 <cleanup>try</cleanup>
136 <dockerFileDir>docker-files</dockerFileDir>
137 <dockerFile>Dockerfile.so-app</dockerFile>
138 <tags>
139 <tag>${project.version}</tag>
140 <tag>${project.version}-${maven.build.timestamp}</tag>
141 <tag>${project.docker.latesttag.version}</tag>
142 </tags>
143 <assembly>
144 <inline>
145 <dependencySets>
146 <dependencySet>
147 <includes>
148 <include>org.onap.so:mso-sdnc-adapter</include>
149 </includes>
150 <outputFileNameMapping>app.jar</outputFileNameMapping>
151 </dependencySet>
152 </dependencySets>
153 </inline>
154 </assembly>
155 </build>
156 </image>
157 <image>
Rob Daugherty8b090d12018-08-02 20:55:30 -0400158 <name>so/openstack-adapter</name>
Rob Daughertye8000512018-08-01 00:02:38 -0400159 <build>
160 <cleanup>try</cleanup>
161 <dockerFileDir>docker-files</dockerFileDir>
162 <dockerFile>Dockerfile.so-app</dockerFile>
163 <tags>
164 <tag>${project.version}</tag>
165 <tag>${project.version}-${maven.build.timestamp}</tag>
166 <tag>${project.docker.latesttag.version}</tag>
167 </tags>
168 <assembly>
169 <inline>
170 <dependencySets>
171 <dependencySet>
172 <includes>
173 <include>org.onap.so:mso-openstack-adapters</include>
174 </includes>
175 <outputFileNameMapping>app.jar</outputFileNameMapping>
176 </dependencySet>
177 </dependencySets>
178 </inline>
179 </assembly>
180 </build>
181 </image>
182 <image>
Rob Daugherty91682972018-08-01 15:20:54 -0400183 <name>so/vfc-adapter</name>
184 <build>
185 <cleanup>try</cleanup>
186 <dockerFileDir>docker-files</dockerFileDir>
187 <dockerFile>Dockerfile.so-app</dockerFile>
188 <tags>
189 <tag>${project.version}</tag>
190 <tag>${project.version}-${maven.build.timestamp}</tag>
191 <tag>${project.docker.latesttag.version}</tag>
192 </tags>
193 <assembly>
194 <inline>
195 <dependencySets>
196 <dependencySet>
197 <includes>
198 <include>org.onap.so.adapters:mso-vfc-adapter</include>
199 </includes>
200 <outputFileNameMapping>app.jar</outputFileNameMapping>
201 </dependencySet>
202 </dependencySets>
203 </inline>
204 </assembly>
205 </build>
206 </image>
207 <image>
Rob Daughertye8000512018-08-01 00:02:38 -0400208 <name>so/asdc-controller</name>
209 <build>
210 <cleanup>try</cleanup>
211 <dockerFileDir>docker-files</dockerFileDir>
212 <dockerFile>Dockerfile.so-app</dockerFile>
213 <tags>
214 <tag>${project.version}</tag>
215 <tag>${project.version}-${maven.build.timestamp}</tag>
216 <tag>${project.docker.latesttag.version}</tag>
217 </tags>
218 <assembly>
219 <inline>
220 <dependencySets>
221 <dependencySet>
222 <includes>
223 <include>org.onap.so:asdc-controller</include>
224 </includes>
225 <outputFileNameMapping>app.jar</outputFileNameMapping>
226 </dependencySet>
227 </dependencySets>
228 </inline>
229 </assembly>
230 </build>
231 </image>
232 <image>
233 <name>so/bpmn-infra</name>
234 <build>
235 <cleanup>try</cleanup>
236 <dockerFileDir>docker-files</dockerFileDir>
237 <dockerFile>Dockerfile.so-app</dockerFile>
238 <tags>
239 <tag>${project.version}</tag>
240 <tag>${project.version}-${maven.build.timestamp}</tag>
241 <tag>${project.docker.latesttag.version}</tag>
242 </tags>
243 <assembly>
244 <inline>
245 <dependencySets>
246 <dependencySet>
247 <includes>
248 <include>org.onap.so:mso-infrastructure-bpmn</include>
249 </includes>
250 <outputFileNameMapping>app.jar</outputFileNameMapping>
251 </dependencySet>
252 </dependencySets>
253 </inline>
254 </assembly>
255 </build>
256 </image>
257 <image>
258 <name>so/api-handler-infra</name>
259 <build>
260 <cleanup>try</cleanup>
261 <dockerFileDir>docker-files</dockerFileDir>
262 <dockerFile>Dockerfile.so-app</dockerFile>
263 <tags>
264 <tag>${project.version}</tag>
265 <tag>${project.version}-${maven.build.timestamp}</tag>
266 <tag>${project.docker.latesttag.version}</tag>
267 </tags>
268 <assembly>
269 <inline>
270 <dependencySets>
271 <dependencySet>
272 <includes>
273 <include>org.onap.so:mso-api-handler-infra</include>
274 </includes>
275 <outputFileNameMapping>app.jar</outputFileNameMapping>
276 </dependencySet>
277 </dependencySets>
278 </inline>
279 </assembly>
280 </build>
281 </image>
ChrisC025301d2017-01-31 11:40:03 +0100282 </images>
283 </configuration>
Rob Daughertye8000512018-08-01 00:02:38 -0400284
ChrisC025301d2017-01-31 11:40:03 +0100285 <executions>
286 <execution>
287 <id>clean-images</id>
288 <phase>pre-clean</phase>
289 <goals>
290 <goal>remove</goal>
291 </goals>
292 <configuration>
Anaël Clossonf15b97e2017-02-08 10:46:48 +0100293 <removeAll>true</removeAll>
ChrisC025301d2017-01-31 11:40:03 +0100294 </configuration>
295 </execution>
Anaël Clossonf15b97e2017-02-08 10:46:48 +0100296
ChrisC025301d2017-01-31 11:40:03 +0100297 <execution>
298 <id>generate-images</id>
299 <phase>generate-sources</phase>
300 <goals>
301 <goal>build</goal>
302 </goals>
303 </execution>
304
305 <execution>
306 <id>push-images</id>
307 <phase>deploy</phase>
308 <goals>
309 <goal>build</goal>
310 <goal>push</goal>
311 </goals>
312 <configuration>
Rob Daugherty8b090d12018-08-02 20:55:30 -0400313 <image>so/catalog-db-adapter,so/request-db-adapter,so/sdnc-adapter,so/openstack-adapter,so/vfc-adapter,so/asdc-controller,so/bpmn-infra,so/api-handler-infra</image>
ChrisC025301d2017-01-31 11:40:03 +0100314 </configuration>
315 </execution>
316 </executions>
ChrisC025301d2017-01-31 11:40:03 +0100317 </plugin>
318
319 <plugin>
320 <groupId>org.apache.maven.plugins</groupId>
321 <artifactId>maven-deploy-plugin</artifactId>
322 <version>2.8</version>
323 <configuration>
324 <skip>true</skip>
325 </configuration>
326 </plugin>
327 </plugins>
328 </build>
329
Rob Daughertye8000512018-08-01 00:02:38 -0400330 <dependencies>
331 <dependency>
332 <groupId>org.onap.so.adapters</groupId>
333 <artifactId>mso-catalog-db-adapter</artifactId>
334 <version>${project.version}</version>
335 </dependency>
336 <dependency>
337 <groupId>org.onap.so.adapters</groupId>
338 <artifactId>mso-requests-db-adapter</artifactId>
339 <version>${project.version}</version>
340 </dependency>
341 <dependency>
342 <groupId>org.onap.so</groupId>
343 <artifactId>mso-sdnc-adapter</artifactId>
344 <version>${project.version}</version>
345 </dependency>
346 <dependency>
347 <groupId>org.onap.so</groupId>
348 <artifactId>mso-openstack-adapters</artifactId>
349 <version>${project.version}</version>
350 </dependency>
351 <dependency>
Rob Daugherty91682972018-08-01 15:20:54 -0400352 <groupId>org.onap.so.adapters</groupId>
353 <artifactId>mso-vfc-adapter</artifactId>
354 <version>${project.version}</version>
355 </dependency>
356 <dependency>
Rob Daughertye8000512018-08-01 00:02:38 -0400357 <groupId>org.onap.so</groupId>
358 <artifactId>asdc-controller</artifactId>
359 <version>${project.version}</version>
360 </dependency>
361 <dependency>
362 <groupId>org.onap.so</groupId>
363 <artifactId>mso-infrastructure-bpmn</artifactId>
364 <version>${project.version}</version>
365 </dependency>
366 <dependency>
367 <groupId>org.onap.so</groupId>
368 <artifactId>mso-api-handler-infra</artifactId>
369 <version>${project.version}</version>
370 </dependency>
371 </dependencies>
Anaël Clossonf15b97e2017-02-08 10:46:48 +0100372</project>