stacks-blockchain-api icon indicating copy to clipboard operation
stacks-blockchain-api copied to clipboard

Speed up CI docker build with caching

Open zone117x opened this issue 2 years ago • 0 comments

Initial attempt in PR https://github.com/hirosystems/stacks-blockchain-api/pull/901

Currently the CI docker build step takes 15-20 minutes. Most PRs only modify the typescript source, which means most of the time only the npm run build step should be required to run without caching, which takes less than a minute.

The other docker file commands could leverage the caching feature provided by the docker/build-push-action action. For example here are some lengthy steps that could easily be cached:

  • apk add ...,
  • npm install ...
  • Building the stacks-node from source

zone117x avatar Apr 20 '23 12:04 zone117x