summaryrefslogtreecommitdiffstats
path: root/sms-service/bin/build_image.sh
diff options
context:
space:
mode:
authorKiran Kamineni <kiran.k.kamineni@intel.com>2018-03-22 14:16:40 -0700
committerGirish Havaldar <hg0071052@techmahindra.com>2018-03-23 15:37:09 +0000
commit7cdae555806b7fb642460845961295992c6f7f34 (patch)
tree9e51a41846a6876dda11a94e1b7629b5c43107d5 /sms-service/bin/build_image.sh
parenta02a75b47cd9850c3f9be17186a21316ac880184 (diff)
Updating with binary compile in the bash script
Adding build commands within the bash script This will then be called in the nightly docker push Issue-ID: AAF-100 Change-Id: Iab29de26c7f9feac1b3f76666f1674ad7a267da8 Signed-off-by: Kiran Kamineni <kiran.k.kamineni@intel.com>
Diffstat (limited to 'sms-service/bin/build_image.sh')
-rwxr-xr-xsms-service/bin/build_image.sh15
1 files changed, 14 insertions, 1 deletions
diff --git a/sms-service/bin/build_image.sh b/sms-service/bin/build_image.sh
index 3e29c0c..7a9ddba 100755
--- a/sms-service/bin/build_image.sh
+++ b/sms-service/bin/build_image.sh
@@ -20,6 +20,17 @@ if [ $HTTPS_PROXY ]; then
BUILD_ARGS+=" --build-arg HTTPS_PROXY=${HTTPS_PROXY}"
fi
+function generate_binary {
+ pushd ../src/sms
+ make build
+ popd
+ cp ../target/sms .
+}
+
+function remove_binary {
+ rm sms
+}
+
function build_image {
echo "Start build docker image: ${IMAGE_NAME}"
docker build ${BUILD_ARGS} -t ${IMAGE_NAME}:latest .
@@ -41,5 +52,7 @@ function push_image {
push_image_tag ${IMAGE_NAME}:${VERSION}-STAGING-${TIMESTAMP}
}
+generate_binary
build_image
-#push_image \ No newline at end of file
+push_image
+remove_binary \ No newline at end of file