mirror of
https://github.com/chatopera/cosin.git
synced 2025-08-01 16:38:02 +08:00
https://github.com/cskefu/cskefu/issues/775 deploy before build image
Signed-off-by: Hai Liang Wang <hai@chatopera.com>
This commit is contained in:
parent
07ecf9acd5
commit
42267f0ff2
@ -18,3 +18,11 @@ export DATE_WITH_TIME=`date "+%Y%m%d-%H%M%S"` #add %3N as we want millisecond to
|
|||||||
[ -z "${BASH_SOURCE[0]}" -o "${BASH_SOURCE[0]}" = "$0" ] || return
|
[ -z "${BASH_SOURCE[0]}" -o "${BASH_SOURCE[0]}" = "$0" ] || return
|
||||||
cd $baseDir/..
|
cd $baseDir/..
|
||||||
mvn -DskipTests clean package deploy
|
mvn -DskipTests clean package deploy
|
||||||
|
|
||||||
|
if [ $? -eq 0 ]; then
|
||||||
|
echo "Deploy success."
|
||||||
|
exit 0
|
||||||
|
else
|
||||||
|
echo "Error happens during deployment."
|
||||||
|
exit 1
|
||||||
|
fi
|
@ -23,9 +23,17 @@ TIMESTAMP=`date "+%Y%m%d.%H%M%S"`
|
|||||||
PACKAGE_VERSION=`git rev-parse --short HEAD`
|
PACKAGE_VERSION=`git rev-parse --short HEAD`
|
||||||
APPLICATION_CUSTOMER_ENTITY=${APPLICATION_CUSTOMER_ENTITY:-"OpenSource Community"}
|
APPLICATION_CUSTOMER_ENTITY=${APPLICATION_CUSTOMER_ENTITY:-"OpenSource Community"}
|
||||||
|
|
||||||
|
$baseDir/../../bin/deploy.sh
|
||||||
|
|
||||||
|
if [ ! $? -eq 0 ]; then
|
||||||
|
echo "Error on deploy"
|
||||||
|
exit 1
|
||||||
|
fi
|
||||||
|
|
||||||
$baseDir/package.sh
|
$baseDir/package.sh
|
||||||
|
|
||||||
if [ ! $? -eq 0 ]; then
|
if [ ! $? -eq 0 ]; then
|
||||||
|
echo "Error happens on package."
|
||||||
exit 1
|
exit 1
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user