diff options
author | prathamesh morde <prathamesh.morde@bell.ca> | 2019-04-12 11:41:36 -0400 |
---|---|---|
committer | Oleg Mitsura <oleg.mitsura@amdocs.com> | 2019-04-17 17:24:47 -0400 |
commit | 8b3652a56866d2906e0da3431158153386233f4c (patch) | |
tree | ed678c6cb45727e1960f4a36383af645120eef30 /ms/cds-sdc-listener/application/pom.xml | |
parent | 37d99fb2be6910d3f9cdfdddfafc3f14c68d5b74 (diff) |
Work in Progress cds-sdc-listener containerization
Change-Id: Ib99f2c2f7c3f8ad46ec9630a548370e7467a96b4
Issue-ID: CCSDK-1145
Signed-off-by: prathamesh morde <prathamesh.morde@bell.ca>
Diffstat (limited to 'ms/cds-sdc-listener/application/pom.xml')
-rw-r--r-- | ms/cds-sdc-listener/application/pom.xml | 107 |
1 files changed, 105 insertions, 2 deletions
diff --git a/ms/cds-sdc-listener/application/pom.xml b/ms/cds-sdc-listener/application/pom.xml index c58bb130f..3f8e1a319 100644 --- a/ms/cds-sdc-listener/application/pom.xml +++ b/ms/cds-sdc-listener/application/pom.xml @@ -6,7 +6,8 @@ ~ proprietary to Bell Canada and are protected by trade secret or copyright law. ~ Unauthorized copying of this file, via any medium is strictly prohibited. --> -<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"> +<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"> <parent> <groupId>org.onap.ccsdk.parent</groupId> @@ -18,11 +19,17 @@ <modelVersion>4.0.0</modelVersion> <artifactId>cds-sdc-listener-application</artifactId> <version>0.4.2-SNAPSHOT</version> - <name>CDS-SDC Listener Application </name> + <name>CDS-SDC Listener Application</name> <properties> <grpc.version>1.17.1</grpc.version> <protobuf.version>3.6.1</protobuf.version> + <image.name>onap/ccsdk-cds-sdc-listener</image.name> + <docker.push.phase>deploy</docker.push.phase> + <project.version>${parent.version}</project.version> + <!-- Start of Docker Related Properties --> + <docker.fabric.version>0.26.1</docker.fabric.version> + <ccsdk.project.version>${project.version}</ccsdk.project.version> </properties> <dependencies> @@ -106,7 +113,103 @@ </execution> </executions> </plugin> + <plugin> + <artifactId>maven-antrun-plugin</artifactId> + <version>1.8</version> + <executions> + <execution> + <id>copy</id> + <phase>package</phase> + <configuration> + <target> + <echo>ANT TASK - copying Docker files</echo> + <copy todir="${basedir}/target/docker-stage" overwrite="true" flatten="true"> + <fileset dir="${basedir}/src/main/docker"> + <include name="Dockerfile"/> + <include name="start.sh"/> + </fileset> + <fileset dir="${basedir}/target"> + <include name="*.jar"/> + </fileset> + <fileset dir="${basedir}/src/main/resources/"> + <include name="application.yml"/> + </fileset> + </copy> + </target> + </configuration> + <goals> + <goal>run</goal> + </goals> + </execution> + </executions> + </plugin> + <plugin> + <groupId>org.codehaus.groovy.maven</groupId> + <artifactId>gmaven-plugin</artifactId> + <version>1.0</version> + <executions> + <execution> + <phase>validate</phase> + <goals> + <goal>execute</goal> + </goals> + <configuration> + <source>${basedir}/../../../TagVersion.groovy</source> + </configuration> + </execution> + </executions> + </plugin> </plugins> </build> + <profiles> + <profile> + <id>docker</id> + <build> + <plugins> + <plugin> + <groupId>io.fabric8</groupId> + <artifactId>docker-maven-plugin</artifactId> + <version>${docker.fabric.version}</version> + <inherited>false</inherited> + <configuration> + <images> + <image> + <name>${image.name}</name> + <build> + <cleanup>try</cleanup> + <dockerFileDir>${basedir}/target/docker-stage</dockerFileDir> + <tags> + <tag>${project.docker.latestminortag.version}</tag> + <tag>${project.docker.latestfulltag.version}</tag> + <tag>${project.docker.latesttagtimestamp.version}</tag> + </tags> + </build> + </image> + </images> + <verbose>true</verbose> + </configuration> + <executions> + <execution> + <id>generate-images</id> + <phase>package</phase> + <goals> + <goal>build</goal> + </goals> + </execution> + <execution> + <id>push-images</id> + <phase>${docker.push.phase}</phase> + <goals> + <goal>build</goal> + <goal>push</goal> + </goals> + </execution> + </executions> + </plugin> + </plugins> + </build> + </profile> + </profiles> + </project> |