Commit f0862dd4 authored by Richard Mortier's avatar Richard Mortier
Browse files

Merge branch 'use-dabuild_docker' into 'master'

dabuild: doh! actually use the indicated `$DABUILD_DOCKER` command

See merge request !58
parents ec283280 1456d68e
Pipeline #6097 passed with stages
in 14 minutes and 50 seconds
...@@ -45,6 +45,7 @@ case "$DABUILD_DOCKER" in ...@@ -45,6 +45,7 @@ case "$DABUILD_DOCKER" in
"Expected one of: docker|podman" "Expected one of: docker|podman"
;; ;;
esac esac
_DOCKER=$DABUILD_DOCKER
## use branch to figure out most appropriate alpine version ## use branch to figure out most appropriate alpine version
if [ "$DABUILD_VERSION" ]; then if [ "$DABUILD_VERSION" ]; then
...@@ -96,12 +97,12 @@ if [ "$DABUILD_CACHE" = "true" ]; then ...@@ -96,12 +97,12 @@ if [ "$DABUILD_CACHE" = "true" ]; then
vol=abuild-$ABUILD_VERSION-$DABUILD_ARCH-${v//\//_} vol=abuild-$ABUILD_VERSION-$DABUILD_ARCH-${v//\//_}
if [ "$DABUILD_CLEAN" = "true" ]; then if [ "$DABUILD_CLEAN" = "true" ]; then
## clean the cache if requested ## clean the cache if requested
docker rm -f $(docker ps -qaf "volume=$vol") >/dev/null 2>&1 || true $_DOCKER rm -f $($_DOCKER ps -qaf "volume=$vol") >/dev/null 2>&1 || true
docker volume rm $vol >/dev/null $_DOCKER volume rm $vol >/dev/null
fi fi
if docker volume ls -f 'name=$v' | grep $v >/dev/null ; then if $_DOCKER volume ls -f 'name=$v' | grep $v >/dev/null ; then
docker volume create $vol >/dev/null $_DOCKER volume create $vol >/dev/null
fi fi
ABUILD_VOLUMES="$ABUILD_VOLUMES -v $vol:/$v" ABUILD_VOLUMES="$ABUILD_VOLUMES -v $vol:/$v"
done done
...@@ -113,7 +114,7 @@ if [ "$DABUILD_RM" = "false" ]; then ...@@ -113,7 +114,7 @@ if [ "$DABUILD_RM" = "false" ]; then
fi fi
## go! ## go!
docker run --tty --interactive \ $_DOCKER run --tty --interactive \
$ABUILD_RM \ $ABUILD_RM \
$ABUILD_VOLUMES \ $ABUILD_VOLUMES \
-e DABUILD_DEBUG \ -e DABUILD_DEBUG \
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment