fix odl patches
[ccsdk/distribution.git] / 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.distribution</groupId>
7         <artifactId>distribution-root</artifactId>
8         <version>1.6.1-SNAPSHOT</version>
9     </parent>
10
11     <artifactId>distribution-ubuntu</artifactId>
12     <packaging>pom</packaging>
13
14     <name>ccsdk-distribution :: ubuntu</name>
15     <description>Creates base ubuntu Docker container</description>
16     <organization>
17         <name>openECOMP</name>
18     </organization>
19
20     <properties>
21         <image.name>onap/ccsdk-ubuntu-image</image.name>
22     </properties>
23
24     <build>
25         <plugins>
26             <plugin>
27                 <groupId>org.codehaus.gmaven</groupId>
28                 <artifactId>groovy-maven-plugin</artifactId>
29                 <version>2.1.1</version>
30                 <executions>
31                     <execution>
32                         <phase>validate</phase>
33                         <goals>
34                             <goal>execute</goal>
35                         </goals>
36                         <configuration>
37                             <source>${basedir}/../src/main/scripts/TagVersion.groovy</source>
38                         </configuration>
39                     </execution>
40                 </executions>
41             </plugin>
42
43             <plugin>
44                 <artifactId>maven-resources-plugin</artifactId>
45                 <version>2.6</version>
46                 <executions>
47                     <execution>
48                         <id>copy-dockerfile</id>
49                         <goals>
50                             <goal>copy-resources</goal>
51                         </goals><!-- here the phase you need -->
52                         <phase>validate</phase>
53                         <configuration>
54                             <outputDirectory>${basedir}/target/docker-stage</outputDirectory>
55                             <resources>
56                                 <resource>
57                                     <directory>src/main/docker</directory>
58                                     <includes>
59                                         <include>Dockerfile</include>
60                                     </includes>
61                                     <filtering>true</filtering>
62                                 </resource>
63                             </resources>
64                         </configuration>
65                     </execution>
66                 </executions>
67             </plugin>
68         </plugins>
69     </build>
70
71     <profiles>
72         <profile>
73             <id>docker</id>
74             <build>
75                 <plugins>
76                     <plugin>
77                         <groupId>io.fabric8</groupId>
78                         <artifactId>docker-maven-plugin</artifactId>
79                         <version>0.34.0</version>
80                         <inherited>false</inherited>
81                         <configuration>
82                             <images>
83                                 <image>
84                                     <name>${image.name}</name>
85                                     <build>
86                                         <cleanup>try</cleanup>
87                                         <noCache>true</noCache>
88                                         <contextDir>${basedir}/target/docker-stage</contextDir>
89                                         <dockerFile>Dockerfile</dockerFile>
90                                         <tags>
91                                             <tag>${project.docker.latestminortag.version}</tag>
92                                             <tag>${project.docker.latestfulltag.version}</tag>
93                                             <tag>${project.docker.latesttagtimestamp.version}</tag>
94                                         </tags>
95                                     </build>
96                                 </image>
97                             </images>
98                             <verbose>${docker.verbose}</verbose>
99                             <skipPush>${docker.skip.push}</skipPush>
100                         </configuration>
101                         <executions>
102                             <execution>
103                                 <id>build-push-images</id>
104                                 <goals>
105                                     <goal>build</goal>
106                                     <goal>push</goal>
107                                 </goals>
108                             </execution>
109                         </executions>
110                     </plugin>
111                 </plugins>
112             </build>
113         </profile>
114     </profiles>
115 </project>