Skip to content

Commit

Permalink
Parallelise cache pulling for builds
Browse files Browse the repository at this point in the history
Change-type: patch
  • Loading branch information
Pagan Gazzard committed Mar 28, 2019
1 parent 8983121 commit 9af416c
Showing 1 changed file with 7 additions and 6 deletions.
13 changes: 7 additions & 6 deletions automation/build.sh
Original file line number Diff line number Diff line change
Expand Up @@ -67,12 +67,13 @@ function tryPullForCache() {

# Attempt to pull images for cache
# Only if the pull succeeds we add a --cache-from option
tryPullForCache $TARGET_CACHE
tryPullForCache $TARGET_CACHE_MASTER
tryPullForCache $NODE_CACHE
tryPullForCache $NODE_CACHE_MASTER
tryPullForCache $NODE_BUILD_CACHE
tryPullForCache $NODE_BUILD_CACHE_MASTER
tryPullForCache $TARGET_CACHE &
tryPullForCache $TARGET_CACHE_MASTER &
tryPullForCache $NODE_CACHE &
tryPullForCache $NODE_CACHE_MASTER &
tryPullForCache $NODE_BUILD_CACHE &
tryPullForCache $NODE_BUILD_CACHE_MASTER &
wait

export DOCKER_BUILD_OPTIONS=${CACHE_FROM}
export ARCH
Expand Down

0 comments on commit 9af416c

Please sign in to comment.