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>
6 <groupId>org.onap.ccsdk.distribution</groupId>
7 <artifactId>distribution-root</artifactId>
8 <version>1.1.1-SNAPSHOT</version>
11 <groupId>org.onap.ccsdk.distribution</groupId>
12 <artifactId>distribution-dgbuilder-docker</artifactId>
13 <packaging>pom</packaging>
15 <name>ccsdk-distribution :: dgbuilder-docker</name>
16 <description>Creates docker container for dgbuilder</description>
22 <image.name>onap/ccsdk-dgbuilder-image</image.name>
23 <uniquedockertag>${env.UNIQUE_DOCKER_TAG}</uniquedockertag>
30 <groupId>org.codehaus.groovy.maven</groupId>
31 <artifactId>gmaven-plugin</artifactId>
32 <version>1.0</version>
35 <phase>validate</phase>
40 <source>${basedir}/../src/main/scripts/TagSnapshotVersion.groovy</source>
46 <artifactId>maven-resources-plugin</artifactId>
47 <version>2.6</version>
50 <id>copy-dockerfile</id>
52 <goal>copy-resources</goal>
53 </goals><!-- here the phase you need -->
54 <phase>validate</phase>
56 <outputDirectory>${basedir}/target/docker-stage</outputDirectory>
59 <directory>src/main/docker</directory>
61 <include>Dockerfile</include>
63 <filtering>true</filtering>
72 <groupId>org.codehaus.mojo</groupId>
73 <artifactId>exec-maven-plugin</artifactId>
74 <version>1.5.0</version>
77 <id>Make-stage-dir</id>
78 <phase>generate-sources</phase>
83 <executable>/bin/mkdir</executable>
85 <argument>-p</argument>
86 <argument>${basedir}/target/docker-stage/opt/onap/ccsdk</argument>
91 <id>Unzip dgbuilder</id>
92 <phase>generate-sources</phase>
97 <executable>/usr/bin/unzip</executable>
99 <argument>-d</argument>
100 <argument>${basedir}/target/docker-stage/opt/onap/ccsdk</argument>
101 <argument>../dgbuilder/target/*.zip</argument>
106 <id>Copy dgbuilder</id>
107 <phase>generate-sources</phase>
112 <executable>/bin/cp</executable>
114 <argument>-r</argument>
115 <argument>../dgbuilder</argument>
116 <argument>${basedir}/target/docker-stage/opt/onap/ccsdk</argument>
122 <id>dgbuilder createReleaseDir</id>
123 <phase>generate-sources</phase>
128 <executable>/bin/bash</executable>
130 <argument>${basedir}/target/docker-stage/opt/onap/ccsdk/dgbuilder/createReleaseDir.sh</argument>
131 <argument>1702</argument>
132 <argument>dguser</argument>
133 <argument>change_email_id@dgbuilder.com</argument>
139 <id>change shell permissions</id>
140 <phase>process-sources</phase>
145 <executable>/usr/bin/find</executable>
147 <argument>${basedir}/target/docker-stage/opt/onap/ccsdk</argument>
148 <argument>-name</argument>
149 <argument>*.sh</argument>
150 <argument>-exec</argument>
151 <argument>chmod</argument>
152 <argument>+x</argument>
153 <argument>{}</argument>
154 <argument>;</argument>
169 <groupId>io.fabric8</groupId>
170 <artifactId>docker-maven-plugin</artifactId>
171 <version>0.34.0</version>
172 <inherited>false</inherited>
176 <name>${image.name}</name>
178 <cleanup>try</cleanup>
179 <contextDir>${basedir}/target/docker-stage</contextDir>
180 <dockerFile>Dockerfile</dockerFile>
182 <tag>${project.docker.latestminortag.snapshot.version}</tag>
183 <tag>${project.docker.latestfulltag.snapshot.version}</tag>
184 <tag>${project.docker.latesttagtimestamp.snapshot.version}</tag>
185 <tag>${project.docker.uniquedockertag.snapshot.version}</tag>
190 <verbose>${docker.verbose}</verbose>
191 <!-- Hardocding skipPush to false, as during verification CSIT currently pulling docker image from nexus -->
192 <!-- <skipPush>${docker.skip.push}</skipPush> -->
193 <skipPush>false</skipPush>
197 <id>build-push-images</id>