actions / actions/cache

Allow caching for deployment events or other events without GITHUB_REF

Open
#319 35 comments 78 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

area:scope enhancement
Dominant language
TypeScript
Stars
5.6k
Forks
1.6k
PR merge metrics
No merged PRs in 30d

Description

As suggested in #317 and #318, I would like to be able to use actions/cache for events where the GITHUB_REF environment variable is not necessarily defined.

For example, I currently have decoupled the creation and the processing of deployments.

  • one ore more workflows create deployment (with differing payloads) using the Deployments API
  • a workflow is triggered by a deployment event and process the actual deployment to different environments

Currently, even with #263, it is not possible to use caching for the deployment event (see @joshmgross' comments in #317). Consequently, deployments using a workflow setup describes as above either take a lot longer, or are not feasible.

It would be really nice to be able to use actions/cache with a setup as described!

Let me know if there is anything I can do to help push this feature through the door.

🌱

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by reviewing the existing actions/cache handling of GITHUB_REF and the discussion in issues #263, #317, and #318; the payload names no source files or tests. Done means caching works for deployment events and other events where GITHUB_REF is not defined, including the described deployment-triggered workflow setup.

Written by the indexing model from the issue text.

Assessment

Tech stack
github-actions
Domain
ci-cd
Issue type
Feature
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.