From 998162392b9ae6a2ef10474a5a29808e50cc0a3b Mon Sep 17 00:00:00 2001 From: Carl Tashian Date: Tue, 18 Aug 2020 16:48:12 -0700 Subject: [PATCH] Attempt at parallelism --- .travis.yml | 31 ++++++++++++++++++------------- make/docker.mk | 10 ++++------ 2 files changed, 22 insertions(+), 19 deletions(-) diff --git a/.travis.yml b/.travis.yml index c0cd4e7a..8d313010 100644 --- a/.travis.yml +++ b/.travis.yml @@ -1,27 +1,32 @@ language: go dist: focal services: -- docker + - docker go: -- 1.14.x + - 1.14.x addons: apt: packages: - - debhelper - - fakeroot - - bash-completion - - libpcsclite-dev + - debhelper + - fakeroot + - bash-completion + - libpcsclite-dev env: global: - - V=1 + - V=1 before_script: -- make bootstrap -script: -- make -- make artifacts + - make bootstrap +jobs: + include: + - script: make lint + - script: make test + - stage: build + script: + - make build + - make artifacts after_success: -- bash <(curl -s https://codecov.io/bash) -t "$CODECOV_TOKEN" || echo "Codecov did - not collect coverage reports" + - bash <(curl -s https://codecov.io/bash) -t "$CODECOV_TOKEN" || echo "Codecov did + not collect coverage reports" notifications: email: false deploy: diff --git a/make/docker.mk b/make/docker.mk index 7efc4a60..b1df244b 100644 --- a/make/docker.mk +++ b/make/docker.mk @@ -6,9 +6,6 @@ # binary is copied to a new image that is optimized for size. ######################################### -# Testing: output images to out/ with -o out, like this: -# docker buildx build . --progress plain -t step-ca:master -f docker/Dockerfile --platform linux/amd64,linux/arm/v7,linux/386,linux/arm64 -o out - ifeq (, $(shell which docker)) DOCKER_CLIENT_OS := linux else @@ -33,7 +30,7 @@ endif # Called directly instead of via `docker buildx` because # Travis runs a pre-19.03 Docker that doesn't support plugin discovery - $$HOME/.docker/cli-plugins/docker-buildx create --use --name mybuilder --platform="$(DOCKER_PLATFORMS)" || true + docker buildx create --use --name mybuilder --platform="$(DOCKER_PLATFORMS)" || true .PHONY: docker-prepare @@ -58,11 +55,12 @@ docker-login: define DOCKER_BUILDX # $(1) -- Image Tag # $(2) -- Push (empty is no push | --push will push to dockerhub) - $$HOME/.docker/cli-plugins/docker-buildx build . --progress plain -t $(DOCKER_IMAGE_NAME):$(1) -f docker/Dockerfile.step-ca --platform="$(DOCKER_PLATFORMS)" $(2) + docker buildx build . --progress plain -t $(DOCKER_IMAGE_NAME):$(1) -f docker/Dockerfile.step-ca --platform="$(DOCKER_PLATFORMS)" $(2) endef # For non-master builds don't build the docker containers. -docker-branch: +docker-branch: docker-prepare + $(call DOCKER_BUILDX,$(VERSION),) # For master builds don't build the docker containers. docker-master: