Add multi-architecture Docker image build

* Adds a shell script with functions to install multi-architecture docker
  support, as well as build, deploy, and test the shellcheck docker images for
  the same set of architectures for which binaries were already built and
  deployed as tarballs.
* Hooks up the multi-architecture docker build, deploy, and test to the existing
  Travis CI/CD pipeline. It is organized as a separate stage which only runs if
  all previous steps in the already existing test stage succeed.
This commit is contained in:
Artur Klauser
2019-12-27 07:49:06 +01:00
parent ff5f29f661
commit 499e0ceaba
5 changed files with 141 additions and 26 deletions

View File

@@ -19,12 +19,6 @@ build_linux() {
do
cp "shellcheck" "deploy/shellcheck-$tag.linux-x86_64";
done
# Linux Alpine based Docker image
name="$DOCKER_BASE-alpine"
DOCKER_BUILDS="$DOCKER_BUILDS $name"
docker build -f Dockerfile -t "$name:current" --target alpine .
docker run "$name:current" sh -c 'shellcheck --version'
}
build_aarch64() {