Change to mvn-targets
[ci-management.git] / jjb / include-docker-blessing.sh
index 3cb67cf..0c843f7 100755 (executable)
@@ -1,14 +1,20 @@
 #!/bin/bash
 
-if [ -z "$VERSION" ];
+if [ -z "$X" ];
 then
-    echo "Error: no version provided"
+    echo "Error: no version provided"
     exit 1
 fi
 
-if [ -z "$TIMESTAMP" ];
+if [ -z "$Y" ];
 then
-    echo "Error: no timestamp provided"
+    echo "Error: no Y version provided"
+    exit 1
+fi
+
+if [ -z "$Z" ];
+then
+    echo "Error: no Z version provided"
     exit 1
 fi
 
@@ -18,11 +24,11 @@ then
     exit 1
 fi
 
-RELEASE_REPOSITORY="nexus3.openecomp.org:10002"
-SNAPSHOT_REPOSITORY="nexus3.openecomp.org:10003"
-STAGING_IMAGE="openecomp/$PROJECT:$VERSION-STAGING-$TIMESTAMP"
-RELEASE_IMAGE="openecomp/$PROJECT:$VERSION"
+RELEASE_REPOSITORY="nexus3.onap.org:10002"
+SNAPSHOT_REPOSITORY="nexus3.onap.org:10003"
+STAGING_IMAGE="openecomp/$PROJECT:$X.$Y-STAGING-latest"
+RELEASE_IMAGE="openecomp/$PROJECT:$X.$Y.$Z"
 
 docker pull "$SNAPSHOT_REPOSITORY/$STAGING_IMAGE"
 docker tag "$SNAPSHOT_REPOSITORY/$STAGING_IMAGE" "$RELEASE_REPOSITORY/$RELEASE_IMAGE"
-docker push "$RELEASE_REPOSITORY/$RELEASE_IMAGE"
\ No newline at end of file
+docker push "$RELEASE_REPOSITORY/$RELEASE_IMAGE"