aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--Makefile2
-rw-r--r--README.md18
-rw-r--r--docker-compose.yml2
-rw-r--r--environment.config5
-rw-r--r--pom.xml83
5 files changed, 48 insertions, 62 deletions
diff --git a/Makefile b/Makefile
index fcf3f44..d675741 100644
--- a/Makefile
+++ b/Makefile
@@ -12,7 +12,7 @@ build:
docker:
@echo "Building ves-openapi-manager docker image"
- @$(DOCKER) build --tag ves-openapi-manager:latest .
+ @$(DOCKER) build --tag $(IMAGE):latest .
run:
@echo "Starting ves-openapi-manager docker containers"
diff --git a/README.md b/README.md
index 7d74f51..07c64a2 100644
--- a/README.md
+++ b/README.md
@@ -65,4 +65,20 @@ Results of validation are visible in two places:
- In SDC UI in Service -> Distributions view under specific distribution as component *ves-openapi-manager*.
It might take few minutes to show results after service distribution.
- In logs of ves-openapi-manager, right after validation takes place.
- \ No newline at end of file
+
+## Docker image
+
+### Building
+There are at least two ways to build docker image.
+
+Using makefile:
+```
+make build docker
+```
+
+Direct creation with mvn:
+```
+mvn clean package docker:build
+```
+
+Image will be named: *onap/org.onap.dcaegen2.platform.ves-openapi-manager* \ No newline at end of file
diff --git a/docker-compose.yml b/docker-compose.yml
index d708fd8..ce7cb96 100644
--- a/docker-compose.yml
+++ b/docker-compose.yml
@@ -2,7 +2,7 @@ version: '3'
services:
ves-openapi-manager:
- image: ves-openapi-manager:latest
+ image: onap/org.onap.dcaegen2.platform.ves-openapi-manager:latest
container_name: ves-openapi-manager
hostname: ves-openapi-manager
environment:
diff --git a/environment.config b/environment.config
index 0d34eef..57dfbe7 100644
--- a/environment.config
+++ b/environment.config
@@ -1,11 +1,14 @@
# Configuration file for ves-openapi-manager Makefile
-# consts
+# Consts
COMPOSE = docker-compose
MVN = mvn
DOCKER = docker
SSH = ssh
+# Image
+IMAGE=onap/org.onap.dcaegen2.platform.ves-openapi-manager
+
# Port-forwarding configuration
RKE_IP=10.129.36.103
WORKER_IP=10.129.36.116
diff --git a/pom.xml b/pom.xml
index 6f26677..dc04068 100644
--- a/pom.xml
+++ b/pom.xml
@@ -11,9 +11,9 @@
<relativePath/>
</parent>
- <groupId>org.onap.dcaegen2.platform</groupId>
+ <groupId>org.onap.dcaegen2.platform.ves-openapi-manager</groupId>
<artifactId>ves-openapi-manager</artifactId>
- <version>1.0.0</version>
+ <version>1.0.0-SNAPSHOT</version>
<packaging>jar</packaging>
<properties>
@@ -83,64 +83,31 @@
<target>${maven.compiler.target}</target>
</configuration>
</plugin>
+ <plugin>
+ <groupId>io.fabric8</groupId>
+ <artifactId>docker-maven-plugin</artifactId>
+ <version>${docker-maven-plugin.version}</version>
+ <configuration>
+ <skipPush>${skipDockerPush}</skipPush>
+ <verbose>true</verbose>
+ <imagePullPolicy>IfNotPresent</imagePullPolicy>
+ <images>
+ <image>
+ <alias>${project.artifactId}</alias>
+ <name>${docker-image.namespace}/${docker-image.name.prefix}.${project.artifactId}</name>
+ <registry>${onap.nexus.dockerregistry.daily}</registry>
+ <build>
+ <dockerFileDir>${project.basedir}</dockerFileDir>
+ <tags>
+ <tag>${project.version}-${maven.build.timestamp}Z</tag>
+ </tags>
+ </build>
+ </image>
+ </images>
+ </configuration>
+ </plugin>
</plugins>
</build>
- <profiles>
- <profile>
- <id>docker</id>
- <activation>
- <activeByDefault>false</activeByDefault>
- </activation>
- <properties>
- <os.detected.name>linux</os.detected.name>
- <os.detected.arch>x86_64</os.detected.arch>
- <os.detected.classifier>${os.detected.name}-${os.detected.arch}</os.detected.classifier>
- </properties>
- <build>
- <plugins>
- <plugin>
- <groupId>io.fabric8</groupId>
- <artifactId>docker-maven-plugin</artifactId>
- <version>${docker-maven-plugin.version}</version>
- <executions>
- <execution>
- <id>docker-build-image</id>
- <phase>package</phase>
- <goals>
- <goal>build</goal>
- </goals>
- </execution>
- <execution>
- <id>docker-push-image</id>
- <phase>deploy</phase>
- <goals>
- <goal>push</goal>
- </goals>
- </execution>
- </executions>
- <configuration>
- <skipPush>${skipDockerPush}</skipPush>
- <verbose>true</verbose>
- <imagePullPolicy>IfNotPresent</imagePullPolicy>
- <images>
- <image>
- <alias>${project.artifactId}</alias>
- <name>${docker-image.namespace}/${docker-image.name.prefix}.${project.artifactId}</name>
- <registry>${onap.nexus.dockerregistry.daily}</registry>
- <build>
- <dockerFileDir>${project.basedir}</dockerFileDir>
- <tags>
- <tag>${project.version}-STAGE-${maven.build.timestamp}Z</tag>
- </tags>
- </build>
- </image>
- </images>
- </configuration>
- </plugin>
- </plugins>
- </build>
- </profile>
- </profiles>
<dependencyManagement>
<dependencies>