Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 7 additions & 1 deletion .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -63,6 +63,9 @@ jobs:
runs-on: ubuntu-latest
env:
BUNDLE_GEMFILE: ${{ github.workspace }}/${{ matrix.gemfile }}
# Every job resolves from scratch (Gemfile.lock is removed below), so one
# rubygems.org blip fails the whole job - give bundler extra retries.
BUNDLE_RETRY: "6"
steps:
- uses: actions/checkout@df4cb1c069e1874edd31b4311f1884172cec0e10 # v6.0.3
with:
Expand Down Expand Up @@ -102,4 +105,7 @@ jobs:
if: always()
run: |
df -h
sudo du -sh /mnt/docker
# /mnt/docker only exists if the Docker configure step ran; without the
# guard this always() step adds a second, misleading failure whenever an
# earlier step (e.g. bundle install) is what actually failed.
if [ -d /mnt/docker ]; then sudo du -sh /mnt/docker; fi
14 changes: 13 additions & 1 deletion test/integration/integration_test.rb
Original file line number Diff line number Diff line change
Expand Up @@ -193,9 +193,21 @@ def compose_up_with_retry
retry
end

# Base-image pulls go straight to Docker Hub from the host daemon, so a Hub
# blip fails the build for this test and every one after it ($IMAGES_BUILT
# never gets set). Retry with backoff to ride out transient Hub outages.
def build_images_once
return if $IMAGES_BUILT
docker_compose "build"
attempts = 0
begin
docker_compose "build"
rescue RuntimeError => e
attempts += 1
raise if attempts >= 3
puts "compose build failed (attempt #{attempts}/3), retrying in #{15 * attempts}s: #{e.message.lines.first&.strip}"
sleep 15 * attempts
retry
end
$IMAGES_BUILT = true
end

Expand Down