docker-filebin/local_build.sh

28 lines
585 B
Bash
Raw Normal View History

2022-01-18 22:31:56 +00:00
#!/usr/bin/env bash
set -e;
if [[ -v FB_VERSION ]]; then
echo "Processing with version ${FB_VERSION}"
else
echo "Set FB_VERSION before calling this script"
exit 1;
fi
BUILD_DIR="fb_src"
2022-01-18 22:31:56 +00:00
if [[ ! -d "${BUILD_DIR}" ]]; then
mkdir -p "${BUILD_DIR}";
echo "Created ${BUILD_DIR}"
else
rm -rf "${BUILD_DIR}";
mkdir -p "${BUILD_DIR}";
echo "Re-created ${BUILD_DIR}"
fi
git clone --branch ${FB_VERSION} https://github.com/Bluewind/filebin --depth=1 "${BUILD_DIR}";
sudo docker build --no-cache -t varakh/filebin:${FB_VERSION} -t varakh/filebin:latest .;