summaryrefslogtreecommitdiffstats
path: root/sms-service/bin/build_image.sh
diff options
context:
space:
mode:
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