Ways to speed up local CI execution

I’m new to circleci and CI/CD in general. I use the local cli a lot to test jobs locally before pushing and triggering the pipeline to prevent common issues. However, an issue I’m facing is I’d always need to install extra dependencies to the base docker images to perform common tasks, the issue is that every time these dependencies will be downloaded again, only the base image gets downloaded and cached in my local environment. One thing I though of is to create and bake custom docker images (that has git installed and other util packages) and push them to any container registry and use them right away, but this becomes tedious as jobs are increased I find myself needing a lot of these custom baked images.

I was wondering if someone had similar issues? how did you approach them? what common things you do to speed up and automate local ci execution?

Are you looking for a method to cache dependencies when running CircleCI jobs locally? If so, there is actually an open issue on Github about this.

This comment and the following comment talk about a workaround where you can pass a volume mount, much in the same way you would with docker:

If you have any other thoughts or ideas, you might consider posting there as well.

This topic was automatically closed 10 days after the last reply. New replies are no longer allowed.