summaryrefslogtreecommitdiffstats
path: root/ms
diff options
context:
space:
mode:
authorBT2983 <BT2983@att.com>2018-09-20 14:26:33 -0600
committerBT2983 <BT2983@att.com>2018-09-20 14:26:33 -0600
commit933fa9bed1e29475796f97c2fd6af370536574d6 (patch)
tree91c5bd2edf35ec526702898bac524301697f41e8 /ms
parent15ac6196f60ba08a7567139ab43c5c60aa2d1a1f (diff)
naming ms - pom updates for docker.
Switching to io.fabric8 plugin. Change-Id: I5b37c90983fe5f5df5860c623413afd661bbf0b6 Issue-ID: CCSDK-588 Signed-off-by: BT2983 <BT2983@att.com>
Diffstat (limited to 'ms')
-rw-r--r--ms/neng/pom.xml263
1 files changed, 118 insertions, 145 deletions
diff --git a/ms/neng/pom.xml b/ms/neng/pom.xml
index 3f90e0af..8f6c7b15 100644
--- a/ms/neng/pom.xml
+++ b/ms/neng/pom.xml
@@ -55,10 +55,12 @@
<project.version>0.3.0</project.version>
<ccsdk.distribution.version>0.2.4</ccsdk.distribution.version>
<docker.buildArg.https_proxy>${https_proxy}</docker.buildArg.https_proxy>
- <docker.push.phase>deploy</docker.push.phase>
- <docker.build.phase>deploy</docker.build.phase>
- <docker.verbose>true</docker.verbose>
- <ccsdk.project.version>${project.version}</ccsdk.project.version>
+ <docker.push.phase>deploy</docker.push.phase>
+ <docker.build.phase>deploy</docker.build.phase>
+ <docker.verbose>true</docker.verbose>
+ <ccsdk.project.version>${project.version}</ccsdk.project.version>
+ <image.name>onap/ccsdk-apps-ms-neng</image.name>
+
</properties>
<profiles>
@@ -114,72 +116,111 @@
</build>
</profile>
- <profile>
- <id>dockerTBD</id>
- <build>
- <plugins>
- <plugin>
- <groupId>com.spotify</groupId>
- <artifactId>docker-maven-plugin</artifactId>
- <version>0.4.11</version>
- <executions>
- <execution>
- <id>push-images</id>
- <phase>${docker.build.phase}</phase>
- <goals>
- <goal>build</goal>
- <goal>push</goal>
- </goals>
- </execution>
- </executions>
- <configuration>
- <imageName>${docker.registry}/onap/ccsdk-apps-ms-neng:${project.version}</imageName>
- <dockerDirectory>${basedir}/target/docker</dockerDirectory>
- <serverId>docker-hub</serverId>
- <registryUrl>https://${docker.registry}</registryUrl>
- <imageTags>
- <imageTag>${project.version}</imageTag>
- <imageTag>${project.version}-STAGING-${maven.build.timestamp}</imageTag>
- <imageTag>${project.docker.latesttag.version}</imageTag>
- </imageTags>
- <forceTags>true</forceTags>
- <resources>
- <resource>
- <targetPath>/</targetPath>
- <directory>${project.build.directory}</directory>
- <include>${project.build.finalName}.jar</include>
- </resource>
- <resource>
- <targetPath>/</targetPath>
- <directory>${project.build.directory}</directory>
- <include>opt/etc/config/*</include>
- </resource>
- <resource>
- <targetPath>/</targetPath>
- <directory>${project.build.directory}</directory>
- <include>opt/etc/keystore/*</include>
- </resource>
- <resource>
- <targetPath>/</targetPath>
- <directory>${project.build.directory}</directory>
- <include>opt/etc/truststore/*</include>
- </resource>
- <resource>
- <targetPath>/</targetPath>
- <directory>${project.build.directory}</directory>
- <include>opt/aai/keystore/*</include>
- </resource>
- <resource>
- <targetPath>/</targetPath>
- <directory>${project.build.directory}</directory>
- <include>etc/*</include>
- </resource>
- </resources>
- </configuration>
- </plugin>
- </plugins>
- </build>
- </profile>
+ <profile>
+ <id>docker</id>
+ <build>
+ <plugins>
+ <plugin>
+ <artifactId>maven-resources-plugin</artifactId>
+ <version>2.6</version>
+ <executions>
+ <execution>
+ <id>copy-dockerfile</id>
+ <goals>
+ <goal>copy-resources</goal>
+ </goals>
+ <phase>${docker.build.phase}</phase>
+ <configuration>
+ <outputDirectory>${basedir}/target/docker-stage</outputDirectory>
+ <resources>
+ <resource>
+ <directory>src/main/docker</directory>
+ <includes>
+ <include>startService.sh</include>
+ <include>Dockerfile</include>
+ </includes>
+ <filtering>true</filtering>
+ </resource>
+ </resources>
+ </configuration>
+ </execution>
+ <execution>
+ <id>copy-app-jar</id>
+ <goals>
+ <goal>copy-resources</goal>
+ </goals>
+ <phase>${docker.build.phase}</phase>
+ <configuration>
+ <outputDirectory>${basedir}/target/docker-stage</outputDirectory>
+ <resources>
+ <resource>
+ <directory>${basedir}/target/</directory>
+ <includes>
+ <include>NetworkElementNameGen.jar</include>
+ </includes>
+ <filtering>false</filtering>
+ </resource>
+ </resources>
+ </configuration>
+ </execution>
+ <execution>
+ <id>copy-config</id>
+ <goals>
+ <goal>copy-resources</goal>
+ </goals>
+ <phase>${docker.build.phase}</phase>
+ <configuration>
+ <outputDirectory>${basedir}/target/docker-stage/opt/etc/config</outputDirectory>
+ <resources>
+ <resource>
+ <directory>${basedir}/opt/etc/config</directory>
+ <includes>
+ <include>*</include>
+ </includes>
+ <filtering>true</filtering>
+ </resource>
+ </resources>
+ </configuration>
+ </execution>
+ </executions>
+ </plugin>
+
+
+ <plugin>
+ <groupId>io.fabric8</groupId>
+ <artifactId>docker-maven-plugin</artifactId>
+ <version>0.26.1</version>
+ <inherited>false</inherited>
+ <configuration>
+ <images>
+ <image>
+ <name>${image.name}</name>
+ <build>
+ <cleanup>try</cleanup>
+ <dockerFileDir>${basedir}/target/docker-stage</dockerFileDir>
+ <tags>
+ <tag>${project.version}</tag>
+ <tag>${project.docker.latesttag.version}</tag>
+ </tags>
+ </build>
+ </image>
+ </images>
+ <verbose>true</verbose>
+ </configuration>
+ <executions>
+ <execution>
+ <id>push-images</id>
+ <phase>${docker.build.phase}</phase>
+ <goals>
+ <goal>build</goal>
+ <goal>push</goal>
+ </goals>
+ </execution>
+ </executions>
+ </plugin>
+ </plugins>
+ </build>
+ </profile>
</profiles>
@@ -271,11 +312,11 @@
<groupId>org.liquibase</groupId>
<artifactId>liquibase-core</artifactId>
</dependency>
- <dependency>
- <groupId>org.mariadb.jdbc</groupId>
- <artifactId>mariadb-java-client</artifactId>
- <version>${mariadb.connector.version}</version>
- </dependency>
+ <dependency>
+ <groupId>org.mariadb.jdbc</groupId>
+ <artifactId>mariadb-java-client</artifactId>
+ <version>${mariadb.connector.version}</version>
+ </dependency>
<dependency>
<groupId>com.h2database</groupId>
<artifactId>h2</artifactId>
@@ -331,6 +372,7 @@
<build>
<finalName>NetworkElementNameGen</finalName>
<plugins>
+
<plugin>
<groupId>org.codehaus.groovy.maven</groupId>
<artifactId>gmaven-plugin</artifactId>
@@ -474,68 +516,6 @@
<artifactId>exec-maven-plugin</artifactId>
<groupId>org.codehaus.mojo</groupId>
</plugin>
- <!--
- <plugin>
- <groupId>io.fabric8</groupId>
- <artifactId>docker-maven-plugin</artifactId>
- <inherited>false</inherited>
- <configuration>
- <verbose>false</verbose>
- <images>
- <image>
- <name>onap/ccsdk-apps-ms-neng</name>
- <build>
- <cleanup>try</cleanup>
- <dockerFileDir>${basedir}/src/main/docker</dockerFileDir>
- <dockerFile>Dockerfile</dockerFile>
- <tags>
- <tag>${project.version}</tag>
- </tags>
-
- <assembly>
- <targetDir>/</targetDir>
- <inline>
- <files>
- <file>
- <source>${project.build.directory}/${build.finalName}.${project.packaging}</source>
- </file>
- </files>
- <fileSet>
- <directory>${basedir}/opt/etc</directory>
- <outputDirectory>opt/etc</outputDirectory>
- <includes>
- <include>**</include>
- </includes>
- </fileSet>
- </inline>
- </assembly>
-
-
- </build>
- </image>
- </images>
- </configuration>
- <executions>
- <execution>
- <id>generate-images</id>
- <phase>package</phase>
- <goals>
- <goal>build</goal>
- </goals>
- </execution>
-
- <execution>
- <id>push-images</id>
- <phase>deploy</phase>
- <goals>
- <goal>build</goal>
- <goal>push</goal>
- </goals>
- </execution>
- </executions>
- </plugin>
- -->
-
<plugin>
<groupId>org.springframework.boot</groupId>
@@ -550,16 +530,9 @@
</executions>
</plugin>
</plugins>
+
<resources>
<resource>
- <directory>src/main/docker</directory>
- <targetPath>../docker</targetPath>
- <filtering>true</filtering>
- <includes>
- <include>**/*</include>
- </includes>
- </resource>
- <resource>
<directory>src/main/resources</directory>
<filtering>true</filtering>
<includes>