summaryrefslogtreecommitdiffstats
path: root/ms/cds-sdc-listener/application/pom.xml
diff options
context:
space:
mode:
Diffstat (limited to 'ms/cds-sdc-listener/application/pom.xml')
-rw-r--r--ms/cds-sdc-listener/application/pom.xml107
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>