Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

specifies cache-dependency-path to prevent poisoning #960

Merged
merged 1 commit into from
Oct 28, 2022

Conversation

vroldanbet
Copy link
Contributor

@vroldanbet vroldanbet commented Oct 28, 2022

Closes #959

These modules have very little dependencies, and end up "winning" in the race to cache, poisoning the cache.

By introducing the path we can have the Github Action disambiguate the cache key name by path.

From the docs:

The action defaults to search for the dependency file - go.sum in the repository root, and uses its hash as a part of the cache key. Use cache-dependency-path input for cases when multiple dependency files are used, or they are located in different subdirectories.

these modules have very little dependencies,
and end up "winning" in the race to cache.

By introducing the path we can have the Github Action
disambiguate the cache key name by path.

From the docs:
The action defaults to search for the dependency file -
go.sum in the repository root, and uses its hash as a
part of the cache key. Use cache-dependency-path input for
cases when multiple dependency files are used, or they are
located in different subdirectories.
@vroldanbet vroldanbet requested a review from a team October 28, 2022 17:55
@github-actions github-actions bot added the area/tooling Affects the dev or user toolchain (e.g. tests, ci, build tools) label Oct 28, 2022
Copy link
Member

@josephschorr josephschorr left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@vroldanbet vroldanbet enabled auto-merge October 28, 2022 17:59
@vroldanbet vroldanbet merged commit ab0f43d into main Oct 28, 2022
@vroldanbet vroldanbet deleted the prevent-cache-poisoning branch October 28, 2022 18:01
@github-actions github-actions bot locked and limited conversation to collaborators Oct 28, 2022
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
area/tooling Affects the dev or user toolchain (e.g. tests, ci, build tools)
Projects
None yet
Development

Successfully merging this pull request may close these issues.

CI cache poisoning
2 participants