Fixes
This commit is contained in:
23
build.sh
23
build.sh
@@ -2,12 +2,25 @@
|
||||
|
||||
TAG="1.5-$(date +%Y%m%d)"
|
||||
|
||||
find . -name Dockerfile | while read i; do
|
||||
dir=$(dirname $i)
|
||||
pushd ${dir} >/dev/null
|
||||
image="genunix/mailu-$(basename $dir):${TAG}"
|
||||
build() {
|
||||
image=$1
|
||||
echo "[INFO] Building ${image}"
|
||||
docker build -t ${image} .
|
||||
docker push ${image}
|
||||
}
|
||||
|
||||
if [ -z "$1" ]; then
|
||||
find . -name Dockerfile | while read i; do
|
||||
dir=$(dirname $i)
|
||||
pushd ${dir} >/dev/null
|
||||
image="genunix/mailu-$(basename $dir):${TAG}"
|
||||
build ${image}
|
||||
popd >/dev/null
|
||||
done
|
||||
else
|
||||
dir=$(basename $1)
|
||||
image="genunix/mailu-$(basename $dir):${TAG}"
|
||||
pushd "$1" >/dev/null
|
||||
build "$image"
|
||||
popd >/dev/null
|
||||
done
|
||||
fi
|
||||
|
||||
Reference in New Issue
Block a user