aboutsummaryrefslogtreecommitdiffstats
path: root/pom.xml
diff options
context:
space:
mode:
authorPiotr Jaszczyk <piotr.jaszczyk@nokia.com>2018-08-03 13:05:15 +0200
committerPiotr Jaszczyk <piotr.jaszczyk@nokia.com>2018-08-13 15:19:36 +0200
commit8a2552ac94981cfa18cce551066d9ca4ec668558 (patch)
tree2e704490e9f0dd10b37e6bfab09b4e51809783ec /pom.xml
parent88726d99b07a91495b800d6155d796c634560882 (diff)
Reorganize docker build
* Docker is built in "docker" profile * It is turned on by default * "mvn install" builds and tags docker image * "mvn deploy" pushes the image to the registry * "mvn -DskipDocker ..." skips docker build * Temporarily use OpenJDK 8 instead of 10 - it require us to specify additional JVM options for use inside containers on production hence addition of run-java.sh Change-Id: Ifa67df4ed7de9f3d300d6f6de999a890486dea24 Signed-off-by: Piotr Jaszczyk <piotr.jaszczyk@nokia.com> Issue-ID: DCAEGEN2-653 Signed-off-by: Piotr Jaszczyk <piotr.jaszczyk@nokia.com>
Diffstat (limited to 'pom.xml')
-rw-r--r--pom.xml26
1 files changed, 17 insertions, 9 deletions
diff --git a/pom.xml b/pom.xml
index 6bbcef3b..7504d4f2 100644
--- a/pom.xml
+++ b/pom.xml
@@ -82,11 +82,11 @@
<!-- Docker -->
<skipDocker>false</skipDocker>
+ <maven.build.timestamp.format>yyyyMMdd'T'HHmmss</maven.build.timestamp.format>
<docker-image.registry>${onap.nexus.dockerregistry.daily}</docker-image.registry>
<docker-image.namespace>onap</docker-image.namespace>
<docker-image.name>${project.groupId}.${project.artifactId}</docker-image.name>
<docker.http_proxy></docker.http_proxy>
- <docker.https_proxy></docker.https_proxy>
</properties>
@@ -406,7 +406,7 @@
<executions>
<execution>
<id>docker-build-image</id>
- <phase>deploy</phase>
+ <phase>package</phase>
<goals>
<goal>build</goal>
</goals>
@@ -425,25 +425,33 @@
<images>
<image>
<alias>${project.artifactId}</alias>
- <name>${docker-image.registry}/${docker-image.namespace}/${docker-image.name}
+ <name>${docker-image.namespace}/${docker-image.name}
</name>
- <tags>
- <tag>${project.version}-SNAPSHOT-${maven.build.timestamp}Z</tag>
- <tag>${project.version}</tag>
- <tag>latest</tag>
- </tags>
+ <registry>${docker-image.registry}</registry>
<build>
<!--
<args>
<http_proxy>${docker.http_proxy}</http_proxy>
- <https_proxy>${docker.https_proxy}</https_proxy>
+ <https_proxy>${docker.http_proxy}</https_proxy>
</args>
-->
<dockerFileDir>${project.basedir}</dockerFileDir>
+ <tags>
+ <tag>${project.version}-SNAPSHOT-${maven.build.timestamp}Z</tag>
+ <tag>${project.version}</tag>
+ <tag>latest</tag>
+ </tags>
</build>
</image>
</images>
</configuration>
+ <dependencies>
+ <dependency>
+ <groupId>io.fabric8</groupId>
+ <artifactId>run-java-sh</artifactId>
+ <version>1.2.2</version>
+ </dependency>
+ </dependencies>
</plugin>
</plugins>
</pluginManagement>