You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Need a way for caching to be for entire repo; not scoped to per-branch builds #1175
We exclusively use git tags for mobile releases, and due to the nature of tags we never gain the performance of caching because each tag is treated as a separate branch even when the tag is within the same branch.
The ask is to have an option to disable scoping caching on a per-branch basis and have the cache be for the entire shared repository - the developer would have the power to cache bust by using the cache key alone without any extra rules with this feature.
Reacted by sidekick-eimantas, Herman S., Aaron Bernard, Martin Miglio, Eric Fenderbosch, Sunil, camnewnham, Iman Mahmoudinasab, Rei Koshka, Miro Stauder and 17 more
changed the title [-]No way to turn off caching scope based on branch[/-][+]Need a way for caching to be for entire repo; not scoped to per-branch builds[/+]on May 23, 2023
@ste00martin I also wondered about having "global" cache. I definitely love to see it, I always saw it as kind of strange. As far as I know it had some security implications.
Second that!
Almost all of my workflows triggers on push of tag, so there is no performance gain, even the most of tags belong to the same branch main
Actions cache is great feature, but ref scope is just really annoying thing now.
I don't understand why it was designed this way....there is a cache key.
If users wanted their caches scoped by branch, or tag, or commit hash, they would include that in the cache key.
Reacted by Rei Koshka, Miro Stauder, Yanlin, Stefan Martin, Zen Voich, Henry, Mike Perrone, Lubomir Georgiev (Любомир Георгиев), Ben Frankel, Un1q32 and 5 more
Can someone explain to me the security risk? I strictly only cache dependencies and the key is computed from the dependency information. All is deterministic. So I do not understand the security problem.
I am also looking forward to having a global cache not scoped per branch as we mostly run in releases/ branches and it never hits any branch as we never have a release from a master branch
Wait... is there really no way to use caches between branches?
I'm trying to cache build results of a 50min long C++ build that is triggered by a GitHub release - but since every GitHub release is tied to a different tag (which is a different branch), the entire build cache cannot be used anymore?
Activity
[-]No way to turn off caching based on branch[/-][+]No way to turn off caching scope based on branch[/+][-]No way to turn off caching scope based on branch[/-][+]Need a way for caching to be for entire repo; not scoped to per-branch builds[/+]smil2k commentedon May 24, 2023
@ste00martin I also wondered about having "global" cache. I definitely love to see it, I always saw it as kind of strange. As far as I know it had some security implications.
rei-koshka commentedon Aug 2, 2023
Second that!
Almost all of my workflows triggers on push of tag, so there is no performance gain, even the most of tags belong to the same branch
mainActions cache is great feature, but ref scope is just really annoying thing now.
pauldraper commentedon Aug 4, 2023
I don't understand why it was designed this way....there is a cache key.
If users wanted their caches scoped by branch, or tag, or commit hash, they would include that in the cache key.
stanislas commentedon Nov 12, 2023
Can someone explain to me the security risk? I strictly only cache dependencies and the key is computed from the dependency information. All is deterministic. So I do not understand the security problem.
Update: I understand now: #79 (comment)
github-actions commentedon May 31, 2024
This issue is stale because it has been open for 200 days with no activity. Leave a comment to avoid closing this issue in 5 days.
mjperrone commentedon May 31, 2024
I am still interested in support for something like this.
cgrente commentedon Aug 7, 2024
still interested by the support of cache between tags
grzegorzkrukowski commentedon Feb 14, 2025
I am also looking forward to having a global cache not scoped per branch as we mostly run in
releases/branches and it never hits any branch as we never have a release from amasterbranchmrousavy commentedon Feb 14, 2025
Wait... is there really no way to use caches between branches?
I'm trying to cache build results of a 50min long C++ build that is triggered by a GitHub release - but since every GitHub release is tied to a different tag (which is a different branch), the entire build cache cannot be used anymore?