X-Git-Url: https://gerrit.onap.org/r/gitweb?a=blobdiff_plain;f=deliveries%2Fos_docker_push.sh;h=1d1f3293fe3eeb69a463cd8c064cdba8dfadd103;hb=983c2d568a873060c046598daeebe481d043fb7a;hp=40d15cb57efd7d2eb84cb7bcdd8ba52a6ba51494;hpb=10c33cd35f772940a02cfdd72863a178776efb8d;p=portal.git diff --git a/deliveries/os_docker_push.sh b/deliveries/os_docker_push.sh old mode 100644 new mode 100755 index 40d15cb5..1d1f3293 --- a/deliveries/os_docker_push.sh +++ b/deliveries/os_docker_push.sh @@ -1,18 +1,26 @@ #!/bin/bash +# Builds and pushes SNAPSHOT versions of Portal images -./run.sh +# be verbose +set -x -REPO="nexus3.openecomp.org:10003" +# Establish environment variables +source $(dirname $0)/.env +if [ $1 ]; then + source $(dirname $0)/$1 +fi -APPS="${REPO}/openecomp/portalapps:1.0.0" -DB="${REPO}/openecomp/portaldb:1.0.0" +if [ -z "$PORTAL_VERSION" ]; then + echo "PORTAL_VERSION not set" + exit 1 +fi -# docker login nexus3.openecomp.org:10003 +TIMESTAMP=$(date +%C%y%m%dT%H%M%S) +# commenting the following two configurations as lf team preferred the uncommented format below +#export VERSION="${PORTAL_VERSION}-${TIMESTAMP}" +#export LATEST="latest" -# tag -docker tag ep:1610-1 ${APPS} -docker tag ecompdb:portal ${DB} +export VERSION="${PORTAL_VERSION}-STAGING-${TIMESTAMP}" +export LATEST="${PORTAL_VERSION}-STAGING-latest" -# push -docker push ${APPS} -docker push ${DB} \ No newline at end of file +./os_docker_base.sh $1