93d527b9e70155c937ab3de200d05f82a9853102
[ccsdk/distribution.git] / odlsli / odlsli-ubuntu / pom.xml
1 <?xml version="1.0" encoding="UTF-8"?>
2 <project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
3         <modelVersion>4.0.0</modelVersion>
4
5         <parent>
6                 <groupId>org.onap.ccsdk.parent</groupId>
7                 <artifactId>odlparent-lite</artifactId>
8                 <version>1.2.1-SNAPSHOT</version>
9                 <relativePath/>
10         </parent>
11
12         <groupId>org.onap.ccsdk.distribution</groupId>
13         <artifactId>distribution-odlsli-ubuntu</artifactId>
14         <version>0.4.1-SNAPSHOT</version>
15         <packaging>pom</packaging>
16
17         <name>ccsdk-distribution :: odlsli-ubuntu</name>
18         <description>Creates Ubuntu-based ODLSLI  Docker container</description>
19         <organization>
20                 <name>openECOMP</name>
21         </organization>
22
23         <properties>
24             <base.image.name>onap/ccsdk-odl-fluorine-ubuntu-image</base.image.name>
25                 <image.name>onap/ccsdk-odlsli-image</image.name>
26                 <ccsdk.project.version>${project.version}</ccsdk.project.version>
27                 <ccsdk.features.version>${project.version}</ccsdk.features.version>
28                 <docker.buildArg.https_proxy>${https_proxy}</docker.buildArg.https_proxy>
29                 <maven.build.timestamp.format>yyyyMMdd'T'HHmmss'Z'</maven.build.timestamp.format>
30                 <opendaylight.root>opt/opendaylight</opendaylight.root>
31                 <docker.push.phase>deploy</docker.push.phase>
32                 <docker.verbose>true</docker.verbose>
33                 <ansible.gpg.key>93C4A3FD7BB9C367</ansible.gpg.key>
34         </properties>
35
36         <dependencies>
37                 <dependency>
38                         <groupId>${project.groupId}</groupId>
39                         <artifactId>dependencies</artifactId>
40                         <version>${project.version}</version>
41                         <classifier>repo</classifier>
42                         <type>zip</type>
43                 </dependency>
44
45                 <dependency>
46                         <groupId>org.onap.ccsdk.sli.core</groupId>
47                         <artifactId>dblib-installer</artifactId>
48                         <version>${ccsdk.sli.core.version}</version>
49                         <classifier>repo</classifier>
50                         <type>zip</type>
51                 </dependency>
52                 <dependency>
53                         <groupId>org.onap.ccsdk.sli.core</groupId>
54                         <artifactId>filters-installer</artifactId>
55                         <version>${ccsdk.sli.core.version}</version>
56                         <classifier>repo</classifier>
57                         <type>zip</type>
58                 </dependency>
59                 <dependency>
60                         <groupId>org.onap.ccsdk.sli.core</groupId>
61                         <artifactId>sli-installer</artifactId>
62                         <version>${ccsdk.sli.core.version}</version>
63                         <classifier>repo</classifier>
64                         <type>zip</type>
65                 </dependency>
66                 <dependency>
67                         <groupId>org.onap.ccsdk.sli.core</groupId>
68                         <artifactId>sliapi-installer</artifactId>
69                         <version>${ccsdk.sli.core.version}</version>
70                         <classifier>repo</classifier>
71                         <type>zip</type>
72                 </dependency>
73                 <dependency>
74                         <groupId>org.onap.ccsdk.sli.core</groupId>
75                         <artifactId>sliPluginUtils-installer</artifactId>
76                         <version>${ccsdk.sli.core.version}</version>
77                         <classifier>repo</classifier>
78                         <type>zip</type>
79                 </dependency>
80                 <dependency>
81                         <groupId>org.onap.ccsdk.sli.core</groupId>
82                         <artifactId>utils-installer</artifactId>
83                         <version>${ccsdk.sli.core.version}</version>
84                         <classifier>repo</classifier>
85                         <type>zip</type>
86                 </dependency>
87                 <dependency>
88                         <groupId>org.onap.ccsdk.sli.core</groupId>
89                         <artifactId>slicore-features-installer</artifactId>
90                         <version>${ccsdk.sli.core.version}</version>
91                         <classifier>repo</classifier>
92                         <type>zip</type>
93                 </dependency>
94                 <dependency>
95                         <groupId>org.onap.ccsdk.sli.adaptors</groupId>
96                         <artifactId>aai-service-installer</artifactId>
97                         <version>${ccsdk.sli.adaptors.version}</version>
98                         <classifier>repo</classifier>
99                         <type>zip</type>
100                 </dependency>
101         <dependency>
102                         <groupId>org.onap.ccsdk.sli.adaptors</groupId>
103                         <artifactId>ansible-adapter-installer</artifactId>
104                         <version>${ccsdk.sli.adaptors.version}</version>
105                         <classifier>repo</classifier>
106                         <type>zip</type>
107                 </dependency>
108                 <dependency>
109                         <groupId>org.onap.ccsdk.sli.adaptors</groupId>
110                         <artifactId>mdsal-resource-installer</artifactId>
111                         <version>${ccsdk.sli.adaptors.version}</version>
112                         <classifier>repo</classifier>
113                         <type>zip</type>
114                 </dependency>
115                 <dependency>
116                         <groupId>org.onap.ccsdk.sli.adaptors</groupId>
117                         <artifactId>resource-assignment-installer</artifactId>
118                         <version>${ccsdk.sli.adaptors.version}</version>
119                         <classifier>repo</classifier>
120                         <type>zip</type>
121                 </dependency>
122                 <dependency>
123                         <groupId>org.onap.ccsdk.sli.adaptors</groupId>
124                         <artifactId>netbox-client-installer</artifactId>
125                         <version>${ccsdk.sli.adaptors.version}</version>
126                         <classifier>repo</classifier>
127                         <type>zip</type>
128                 </dependency>
129                 <dependency>
130                         <groupId>org.onap.ccsdk.sli.adaptors</groupId>
131                         <artifactId>sql-resource-installer</artifactId>
132                         <version>${ccsdk.sli.adaptors.version}</version>
133                         <classifier>repo</classifier>
134                         <type>zip</type>
135                 </dependency>
136                 <dependency>
137                         <groupId>org.onap.ccsdk.sli.adaptors</groupId>
138                         <artifactId>sliadaptors-features-installer</artifactId>
139                         <version>${ccsdk.sli.adaptors.version}</version>
140                         <classifier>repo</classifier>
141                         <type>zip</type>
142                 </dependency>
143                 <dependency>
144                         <groupId>org.onap.ccsdk.sli.northbound</groupId>
145                         <artifactId>asdcApi-installer</artifactId>
146                         <version>${ccsdk.sli.northbound.version}</version>
147                         <classifier>repo</classifier>
148                         <type>zip</type>
149                 </dependency>
150                 <dependency>
151                         <groupId>org.onap.ccsdk.sli.northbound</groupId>
152                         <artifactId>dataChange-installer</artifactId>
153                         <version>${ccsdk.sli.northbound.version}</version>
154                         <classifier>repo</classifier>
155                         <type>zip</type>
156                 </dependency>
157                 <dependency>
158                         <groupId>org.onap.ccsdk.sli.northbound</groupId>
159                         <artifactId>lcm-installer</artifactId>
160                         <version>${ccsdk.sli.northbound.version}</version>
161                         <classifier>repo</classifier>
162                         <type>zip</type>
163                 </dependency>
164                 <dependency>
165                         <groupId>org.onap.ccsdk.sli.northbound</groupId>
166                         <artifactId>slinorthbound-features-installer</artifactId>
167                         <version>${ccsdk.sli.northbound.version}</version>
168                         <classifier>repo</classifier>
169                         <type>zip</type>
170                 </dependency>
171                 <dependency>
172                         <groupId>org.onap.ccsdk.sli.plugins</groupId>
173                         <artifactId>properties-node-installer</artifactId>
174                         <version>${ccsdk.sli.plugins.version}</version>
175                         <classifier>repo</classifier>
176                         <type>zip</type>
177                 </dependency>
178                 <dependency>
179                         <groupId>org.onap.ccsdk.sli.plugins</groupId>
180                         <artifactId>restapi-call-node-installer</artifactId>
181                         <version>${ccsdk.sli.plugins.version}</version>
182                         <classifier>repo</classifier>
183                         <type>zip</type>
184                 </dependency>
185                 <dependency>
186                         <groupId>org.onap.ccsdk.sli.plugins</groupId>
187                         <artifactId>template-node-installer</artifactId>
188                         <version>${ccsdk.sli.plugins.version}</version>
189                         <classifier>repo</classifier>
190                         <type>zip</type>
191                 </dependency>
192                 <dependency>
193                         <groupId>org.onap.ccsdk.sli.plugins</groupId>
194                         <artifactId>restconf-client-installer</artifactId>
195                         <version>${ccsdk.sli.plugins.version}</version>
196                         <classifier>repo</classifier>
197                         <type>zip</type>
198                 </dependency>
199                 <dependency>
200                         <groupId>org.onap.ccsdk.sli.plugins</groupId>
201                         <artifactId>sshapi-call-node-installer</artifactId>
202                         <version>${ccsdk.sli.plugins.version}</version>
203                         <classifier>repo</classifier>
204                         <type>zip</type>
205                 </dependency>
206                 <dependency>
207                         <groupId>org.onap.ccsdk.sli.plugins</groupId>
208                         <artifactId>sliplugins-features-installer</artifactId>
209                         <version>${ccsdk.sli.plugins.version}</version>
210                         <classifier>repo</classifier>
211                         <type>zip</type>
212                 </dependency>
213                 <dependency>
214                         <groupId>org.onap.ccsdk.features</groupId>
215                         <artifactId>features-installer</artifactId>
216                         <version>${ccsdk.features.version}</version>
217                         <classifier>repo</classifier>
218                         <type>zip</type>
219                 </dependency>
220                 <dependency>
221                         <groupId>org.onap.ccsdk.features</groupId>
222                         <artifactId>blueprints-processor-installer</artifactId>
223                         <version>${ccsdk.features.version}</version>
224                         <classifier>repo</classifier>
225                         <type>zip</type>
226                 </dependency>
227         </dependencies>
228
229         <build>
230         <extensions>
231                 <extension>
232                         <!-- this extension is required by wagon in order to pass the proxy -->
233                         <groupId>org.apache.maven.wagon</groupId>
234                         <artifactId>wagon-http-lightweight</artifactId>
235                         <version>2.2</version>
236                 </extension>
237         </extensions>
238                 <plugins>
239
240
241                         <plugin>
242                                 <groupId>org.codehaus.groovy.maven</groupId>
243                                 <artifactId>gmaven-plugin</artifactId>
244                                 <executions>
245                                         <execution>
246                                                 <phase>validate</phase>
247                                                 <goals>
248                                                         <goal>execute</goal>
249                                                 </goals>
250                                                 <configuration>
251                                                         <source>
252                                                                 println project.properties['ccsdk.project.version'];
253                                                                 def versionArray;
254                                                                 if (project.properties['ccsdk.project.version'] != null ) {
255                                                                     versionArray = project.properties['ccsdk.project.version'].split('\\.');
256                                                                 }
257
258                                                                 if (project.properties['ccsdk.project.version'].endsWith("-SNAPSHOT"))
259                                                                 {
260                                                                     project.properties['project.docker.latesttag.version']=versionArray[0] + '.' + versionArray[1] + "-STAGING-latest";
261                                                                 } else {
262                                                                     project.properties['project.docker.latesttag.version']=versionArray[0] + '.' + versionArray[1] + "-STAGING-latest";
263                                                                 }
264
265                                                                 println 'New Tag for docker:' + project.properties['project.docker.latesttag.version'];
266                                                         </source>
267                                                 </configuration>
268                                         </execution>
269                                 </executions>
270                         </plugin>
271
272
273
274                         <plugin>
275                                 <artifactId>maven-resources-plugin</artifactId>
276                                 <version>2.6</version>
277                                 <executions>
278                                         <execution>
279                                                 <id>copy-dockerfile</id>
280                                                 <goals>
281                                                         <goal>copy-resources</goal>
282                                                 </goals><!-- here the phase you need -->
283                                                 <phase>validate</phase>
284                                                 <configuration>
285                                                         <outputDirectory>${basedir}/target/docker-stage</outputDirectory>
286                                                         <resources>
287                                                                 <resource>
288                                                                         <directory>src/main/docker</directory>
289                                                                         <includes>
290                                                                                 <include>Dockerfile</include>
291                                                                         </includes>
292                                                                         <filtering>true</filtering>
293                                                                 </resource>
294                                                         </resources>
295                                                 </configuration>
296                                         </execution>
297
298                                         <execution>
299                                                 <id>copy-scripts</id>
300                                                 <goals>
301                                                         <goal>copy-resources</goal>
302                                                 </goals><!-- here the phase you need -->
303                                                 <phase>validate</phase>
304                                                 <configuration>
305                                                         <outputDirectory>${basedir}/target/docker-stage/opt/onap/ccsdk/bin</outputDirectory>
306                                                         <resources>
307                                                                 <resource>
308                                                                         <directory>../src/main/scripts</directory>
309                                                                         <includes>
310                                                                                 <include>*.sh</include>
311                                                                         </includes>
312                                                                         <filtering>false</filtering>
313                                                                 </resource>
314                                                         </resources>
315                                                 </configuration>
316                                         </execution>
317
318                                         <execution>
319                                                 <id>copy-odl-resources</id>
320                                                 <goals>
321                                                         <goal>copy-resources</goal>
322                                                 </goals><!-- here the phase you need -->
323                                                 <phase>validate</phase>
324                                                 <configuration>
325                                                         <outputDirectory>${basedir}/target/docker-stage</outputDirectory>
326                                                         <resources>
327                                                                 <resource>
328                                                                         <directory>../src/main/resources</directory>
329                                                                         <includes>
330                                                                                 <include>idmlight.db.mv.db</include>
331                                                                                 <include>org.ops4j.pax.logging.cfg</include>
332                                                                                 <include>install_ccsdk.yml</include>
333                                                                                 <include>ansible-sources.list</include>
334                                                                         </includes>
335                                                                         <filtering>false</filtering>
336                                                                 </resource>
337                                                         </resources>
338                                                 </configuration>
339                                         </execution>
340                                         <execution>
341                                                 <id>copy-config</id>
342                                                 <goals>
343                                                         <goal>copy-resources</goal>
344                                                 </goals><!-- here the phase you need -->
345                                                 <phase>validate</phase>
346                                                 <configuration>
347                                                         <outputDirectory>${basedir}/target/docker-stage</outputDirectory>
348                                                         <resources>
349                                                                 <resource>
350                                                                         <directory>../src/main/resources</directory>
351                                                                         <includes>
352                                                                                 <include>org.ops4j.pax.logging.cfg</include>
353                                                                         </includes>
354                                                                         <filtering>false</filtering>
355                                                                 </resource>
356                                                         </resources>
357                                                 </configuration>
358                                         </execution>
359                                         <execution>
360                                                 <id>copy-data</id>
361                                                 <goals>
362                                                         <goal>copy-resources</goal>
363                                                 </goals><!-- here the phase you need -->
364                                                 <phase>validate</phase>
365                                                 <configuration>
366                                                         <outputDirectory>${basedir}/target/docker-stage/opt/onap/ccsdk/data</outputDirectory>
367                                                         <resources>
368                                                                 <resource>
369                                                                         <directory>../src/main/resources</directory>
370                                                                         <includes>
371                                                                                 <include>*.dump</include>
372                                                                         </includes>
373                                                                         <filtering>false</filtering>
374                                                                 </resource>
375                                                         </resources>
376                                                 </configuration>
377                                         </execution>
378                                         <execution>
379                                                 <id>copy-properties</id>
380                                                 <goals>
381                                                         <goal>copy-resources</goal>
382                                                 </goals><!-- here the phase you need -->
383                                                 <phase>validate</phase>
384                                                 <configuration>
385                                                         <outputDirectory>${basedir}/target/docker-stage/opt/onap/ccsdk/data/properties</outputDirectory>
386                                                         <resources>
387                                                                 <resource>
388                                                                         <directory>../src/main/properties</directory>
389                                                                         <includes>
390                                                                                 <include>*.properties</include>
391                                                                         </includes>
392                                                                         <filtering>false</filtering>
393                                                                 </resource>
394                                                         </resources>
395                                                 </configuration>
396                                         </execution>
397                                         <execution>
398                                                 <id>copy-keystores</id>
399                                                 <goals>
400                                                         <goal>copy-resources</goal>
401                                                 </goals><!-- here the phase you need -->
402                                                 <phase>validate</phase>
403                                                 <configuration>
404                                                         <outputDirectory>${basedir}/target/docker-stage/opt/onap/ccsdk/data/stores</outputDirectory>
405                                                         <resources>
406                                                                 <resource>
407                                                                         <directory>../src/main/stores</directory>
408                                                                         <includes>
409                                                                                 <include>*.jks</include>
410                                                                         </includes>
411                                                                         <filtering>false</filtering>
412                                                                 </resource>
413                                                         </resources>
414                                                 </configuration>
415                                         </execution>
416                                 </executions>
417                         </plugin>
418                         <plugin>
419                                 <groupId>org.apache.maven.plugins</groupId>
420                                 <artifactId>maven-dependency-plugin</artifactId>
421                                 <version>3.0.2</version>
422                                 <executions>
423                                         <execution>
424                                                 <id>unpack features</id>
425                                                 <phase>generate-sources</phase>
426                                                 <goals>
427                                                         <goal>unpack-dependencies</goal>
428                                                 </goals>
429                                                 <configuration>
430                                                         <outputDirectory>${basedir}/target/docker-stage</outputDirectory>
431                                                         <excludeTransitive>true</excludeTransitive>
432                                                 </configuration>
433                                         </execution>
434                                         <execution>
435                                                 <id>unpack dgs</id>
436                                                 <phase>generate-sources</phase>
437                                                 <goals>
438                                                         <goal>unpack</goal>
439                                                 </goals>
440                                                 <configuration>
441                                                         <outputDirectory>${basedir}/target/docker-stage/opt/onap/ccsdk</outputDirectory>
442                                                         <artifactItems>
443                                                                 <artifactItem>
444                                                                         <groupId>${project.groupId}</groupId>
445                                                                         <artifactId>platform-logic-installer</artifactId>
446                                                                         <version>${project.version}</version>
447                                                                         <type>zip</type>
448                                                                 </artifactItem>
449                                                         </artifactItems>
450                                                 </configuration>
451                                         </execution>
452                                 </executions>
453                         </plugin>
454                         <plugin>
455                                 <groupId>org.codehaus.mojo</groupId>
456                                 <artifactId>exec-maven-plugin</artifactId>
457                                 <version>1.5.0</version>
458                                 <executions>
459
460                                         <execution>
461                                                 <id>change shell permissions</id>
462                                                 <phase>process-sources</phase>
463                                                 <goals>
464                                                         <goal>exec</goal>
465                                                 </goals>
466                                                 <configuration>
467                                                         <executable>/usr/bin/find</executable>
468                                                         <arguments>
469                                                                 <argument>${basedir}/target/docker-stage/opt/onap/ccsdk</argument>
470                                                                 <argument>-name</argument>
471                                                                 <argument>*.sh</argument>
472                                                                 <argument>-exec</argument>
473                                                                 <argument>chmod</argument>
474                                                                 <argument>+x</argument>
475                                                                 <argument>{}</argument>
476                                                                 <argument>;</argument>
477                                                         </arguments>
478                                                 </configuration>
479                                         </execution>
480                                 </executions>
481                         </plugin>
482
483
484                 </plugins>
485         </build>
486
487         <profiles>
488                 <profile>
489                         <id>docker</id>
490                         <build>
491                                 <plugins>
492                                         <plugin>
493                                                 <groupId>io.fabric8</groupId>
494                                                 <artifactId>docker-maven-plugin</artifactId>
495                                                 <version>0.16.5</version>
496                                                 <inherited>false</inherited>
497                                                 <configuration>
498                                                         <images>
499                                                                 <image>
500                                                                         <name>${image.name}</name>
501                                                                         <build>
502                                                                                 <cleanup>try</cleanup>
503                                                                                 <dockerFileDir>${basedir}/target/docker-stage</dockerFileDir>
504                                                                                 <dockerFile>${basedir}/target/docker-stage/Dockerfile</dockerFile>
505                                                                                 <tags>
506                                                                                         <tag>${project.version}</tag>
507                                                                                         <tag>${project.version}-STAGING-${maven.build.timestamp}</tag>
508                                                                                         <tag>${project.docker.latesttag.version}</tag>
509                                                                                 </tags>
510                                                                         </build>
511                                                                 </image>
512                                                         </images>
513                                                 </configuration>
514                                                 <executions>
515                                                         <execution>
516                                                                 <id>generate-images</id>
517                                                                 <phase>package</phase>
518                                                                 <goals>
519                                                                         <goal>build</goal>
520                                                                 </goals>
521                                                         </execution>
522
523                                                         <execution>
524                                                                 <id>push-images</id>
525                                                                 <phase>${docker.push.phase}</phase>
526                                                                 <goals>
527                                                                         <goal>build</goal>
528                                                                         <goal>push</goal>
529                                                                 </goals>
530                                                         </execution>
531                                                 </executions>
532                                         </plugin>
533                                 </plugins>
534                         </build>
535                 </profile>
536         </profiles>
537 </project>

© 2017 ONAP. Copyright © The Linux Foundation ®. All Rights Reserved.
The Linux Foundation has registered trademarks and uses trademarks.
For a list of trademarks of The Linux Foundation, please see our Trademark Usage page.
Linux is a registered trademark of Linus Torvalds.
Privacy Policy and Terms of Use