Improvements to skip "docs" and other non-docker directories

This commit is contained in:
Christopher Horrell 2016-09-29 09:16:18 -04:00
parent 86b033cf9f
commit 54ee1265cd
1 changed files with 5 additions and 3 deletions

View File

@ -25,9 +25,8 @@ fi
versions=( "${versions[@]%/}" )
for version in "${versions[@]}"; do
if [[ "$version" == "docs" ]]; then
continue
fi
# Skip "docs" and other non-docker directories
[ -f "$version/Dockerfile" ] || continue
tag=$(cat $version/Dockerfile | grep "ENV NODE_VERSION" | cut -d' ' -f3)
@ -50,6 +49,9 @@ for version in "${versions[@]}"; do
variants=$(ls -d $version/*/ | awk -F"/" '{print $2}')
for variant in $variants; do
# Skip non-docker directories
[ -f "$version/$variant/Dockerfile" ] || continue
info "Building $tag-$variant variant..."
docker build -t node:$tag-$variant $version/$variant