Skip to content

ci: skip redundant Docker builds in CI#158

Closed
jakebromberg wants to merge 1 commit intotask/reduce-ci-minutesfrom
ci/skip-redundant-build
Closed

ci: skip redundant Docker builds in CI#158
jakebromberg wants to merge 1 commit intotask/reduce-ci-minutesfrom
ci/skip-redundant-build

Conversation

@jakebromberg
Copy link
Member

Summary

  • Add --skip-build flag to scripts/ci-env.sh to skip npm run ci:build when Docker images are already built
  • Pass --skip-build from the workflow's "Set Up Test Environment" step, since docker/build-push-action already builds and tags the images
  • Local npm run ci:testmock continues to work unchanged (no flag passed)

Estimated savings

~1-2 minutes per integration test run (eliminates redundant Docker image rebuilds)

Test plan

  • CI integration tests pass with --skip-build (no Docker build output in "Set Up Test Environment" step)
  • Local npm run ci:testmock still builds images and runs tests correctly

In GitHub Actions, Docker images are already built by docker/build-push-action
steps before ci-env.sh runs. The ci:build call in ci-env.sh rebuilds them from
scratch, wasting ~2 minutes. Add a --skip-build flag to ci-env.sh and pass it
from the workflow's "Set Up Test Environment" step. Local ci:testmock continues
to work unchanged.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant