summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorBin Yang <bin.yang@windriver.com>2019-07-15 10:48:31 +0000
committerBin Yang <bin.yang@windriver.com>2019-07-15 10:48:31 +0000
commit64457526dc2685a588d6b8560c9a76d01a795a4a (patch)
tree76959dbf2ea666f6e728643a877598b6a6506ba8
parent6be2a6d04b96b75f2d353d65a670ebe8525fa665 (diff)
Migrate docker job for multivimbroker
Change-Id: Ie13ca858acbd608b9592268598e9c3f3ee03e599 Issue-ID: MULTICLOUD-704 Signed-off-by: Bin Yang <bin.yang@windriver.com>
-rw-r--r--multivimbroker/pom.xml72
1 files changed, 72 insertions, 0 deletions
diff --git a/multivimbroker/pom.xml b/multivimbroker/pom.xml
index dea669e..fd7de1c 100644
--- a/multivimbroker/pom.xml
+++ b/multivimbroker/pom.xml
@@ -113,4 +113,76 @@
</plugin>
</plugins>
</build>
+ <profiles>
+ <profile>
+ <id>docker</id>
+ <build>
+ <plugins>
+ <plugin>
+ <groupId>org.apache.maven.plugins</groupId>
+ <artifactId>maven-resources-plugin</artifactId>
+ <version>3.1.0</version>
+ <executions>
+ <execution>
+ <id>copy-resources</id>
+ <phase>validate</phase>
+ <goals>
+ <goal>copy-resources</goal>
+ </goals>
+ <configuration>
+ <outputDirectory>${project.basedir}/docker_target</outputDirectory>
+ <resources>
+ <resource>
+ <directory>${project.basedir}/docker</directory>
+ <filtering>true</filtering>
+ </resource>
+ </resources>
+ </configuration>
+ </execution>
+ </executions>
+ </plugin>
+ <plugin>
+ <groupId>org.apache.maven.plugins</groupId>
+ <artifactId>maven-antrun-plugin</artifactId>
+ <version>1.6</version>
+ <executions>
+ <execution>
+ <phase>install</phase>
+ <inherited>false</inherited>
+ <configuration>
+ <target>
+ <exec executable="docker">
+ <arg value="build"/>
+ <arg value="-t"/>
+ <arg value="${CONTAINER_PUSH_REGISTRY}/onap/multicloud/framework:${project.version}"/>
+ <arg value="docker_target"/>
+ </exec>
+ <exec executable="docker">
+ <arg value="tag"/>
+ <arg value="${CONTAINER_PUSH_REGISTRY}/onap/multicloud/framework:${project.version}"/>
+ <arg value="${CONTAINER_PUSH_REGISTRY}/onap/multicloud/framework:latest"/>
+ </exec>
+ <exec executable="docker">
+ <arg value="push"/>
+ <arg value="${CONTAINER_PUSH_REGISTRY}/onap/multicloud/framework:${project.version}"/>
+ </exec>
+ <exec executable="docker">
+ <arg value="push"/>
+ <arg value="${CONTAINER_PUSH_REGISTRY}/onap/multicloud/framework:latest"/>
+ </exec>
+ </target>
+ </configuration>
+ <goals>
+ <goal>run</goal>
+ </goals>
+ </execution>
+ </executions>
+ </plugin>
+ </plugins>
+ </build>
+ <activation>
+ <activeByDefault>false</activeByDefault>
+ </activation>
+ </profile>
+ </profiles>
</project>