Skip to main content

GitHub Actions Cache and Persistent Storage

Puzl Cloud provides two ways to persist data across your GitHub Actions runs:

  1. Actions Cache configuring via the puzl-cloud-cache action.
  2. Shared persistent mount points configuring in your runner settings.

Both live on the same underlying Flexible Persistent File Storage and shared among the workflow jobs within the same GitHubActionsIntegration, but differ in usage patterns and safety characteristics.

Use cache for typical dependency or build caches, especially on public repos.

  • Isolation: Each workflow run gets its cache scope by repo and branch, or by pull request, following the safety official GitHub practices.
  • Security: 100% safe for public repositories - external PRs cannot mutate cache on your branches.
  • Speed: Artifacts in /cache are tar-packed on save and unpacked on restore.
  • Data rotation: Caches expire after 30 days by default; configurable in your GitHubActionsIntegration settings.
name: Caching Primes
on: push
jobs:
build:
runs-on: puzl-ubuntu-latest

steps:
- uses: actions/checkout@v3

- name: Cache Primes
id: cache-primes
uses: puzl-cloud/github-actions-cache@v3
with:
path: prime-numbers
key: primes

- name: Generate Prime Numbers
if: steps.cache-primes.outputs.cache-hit != 'true'
run: /generate-primes.sh -d prime-numbers

- name: Use Prime Numbers
run: /primes.sh -d prime-numbers

For the latest documentation and details, see Puzl’s GitHub Actions cache on the Marketplace.

Use shared mounts when you need faster I/O, or to share large datasets/images/tool caches among your workflow jobs.

  • Isolation: Multiple workflow jobs, running in the same GitHubActionsIntegration, may mount the same paths to collaborate.
  • Security: Because mount points expose raw file access to all workflow runs, do not use them to run the public workflows.
  • Speed: Data lives on a mounted filesystem - no packing/unpacking overhead.
  • Data rotation: No automatic cleanup; data persists until you or your workflows delete it manually.
Notice

When running workflows from a public GitHub repository, use a dedicated runner and avoid sharedPersistentMountPoints to prevent public pull requests from mutating your shared data.

  1. Navigate to the GitHub Runners section in the Puzl Cloud Console.
  2. Find the necessary runner and go to Runner Settings.
  3. Enter the required destinations in Shared Persistent Mount Points input.