question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

feature request: local cache store for self-hosted runners

See original GitHub issue

because i, as well as many others, are having issues with the caching service, a nice feature for self-hosted runners would be to have a cache local to the self-hosted runner, perhaps configurable by the self-hosted runner.

currently for me, it’s faster to not cache and just run npm ci than to load/save cache on self-hosted runners.

Issue Analytics

  • State:closed
  • Created 3 years ago
  • Reactions:9
  • Comments:7 (2 by maintainers)

github_iconTop GitHub Comments

7reactions
joshuapintercommented, Mar 7, 2021

I would love to see this as well, primarily for node_modules via yarn. We’re using a farm of self-hosted runners and using actions/cache is the same, if not slower, than just installing all the dependencies again from a blank slate, depending on the utilization of the network, etc.

We have to use our own tasks/steps to essentially do what actions/cache does but with a local directory. Just would be nice to not have to re-invent the wheel here and, instead, specify a cache “location” or “path” to use instead of using the remote cache on GitHub/Azure.

Here’s a quick benchmark to show you the performance hit self-hosted runners have with using the default remote cache:

Remote Cache Using github/actions.

Screenshot 2021-03-07 at 10 24 34

2m48s

And that’s WITH a cache hit.

Local Cache.

Cache Miss

Screenshot 2021-03-07 at 10 25 43

1m42s

Cache Hit

Screenshot 2021-03-07 at 10 44 44

~0m01s

Anyway, just would be nice to not have to do this manually and get all the nice features of actions/cache for self-hosted runners.

2reactions
jonathanongcommented, Jun 15, 2020

It’d be nice to not have to build out a bespoke cache system to run on the self-hosted runner

I think that’s the main point. I could set up my own caching system, but then it would be a custom action. Ideally, it’s the same actions API, but with a different “backend”.

Another feature I’d like is to avoid slow cache uploads/downloads, which are much slower if your self-hosted runner doesn’t have great internet speeds, especially upload speeds.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Caching on self-hosted runners · Issue #2271 · github/docs
At the moment actions/cache will only store caches on GitHub itself; this is true whether your runner is self-hosted or GitHub-hosted.
Read more >
Speed up job execution - GitLab Docs
You can improve performance of your jobs by caching your images and dependencies. Use a proxy for containers. You can speed up the...
Read more >
GitHub Self-Hosted Runners on ECS | by Jean Baudin - Medium
Using containers, our idea was to have a fully isolated ephemeral worker for our jobs that developers could use “on demand” based on...
Read more >
Caches | Bitbucket Cloud - Atlassian Support
What is dependency caching? Most builds start by running commands that download dependencies from the internet, which can take a lot of time...
Read more >
Pipeline caching - Azure - Microsoft Learn
Workspace is the local path on the agent running your pipeline where all ... the cache identified by the key is requested from...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found