Skip to content

Commit

Permalink
cache docker images to avoid rate limiting from initial kurtosis images
Browse files Browse the repository at this point in the history
  • Loading branch information
pk910 committed Jan 12, 2025
1 parent 30baa96 commit 5e13ebb
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 0 deletions.
8 changes: 8 additions & 0 deletions .github/workflows/_shared-run-test.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -39,6 +39,10 @@ on:
type: string
description: "The kurtosis network config to use (default: kurtosis-config/default.yaml)."
default: "kurtosis-config/default.yaml"
kurtosis_version:
type: string
description: "The latest version of the kurtosis cli (used as caching key)."
default: ""
kurtosis_branch:
type: string
description: "The branch name for the kurtosis ethereum package to use (default: )."
Expand Down Expand Up @@ -74,6 +78,10 @@ jobs:
steps:
- name: Checkout Repository
uses: actions/checkout@v4
- name: Cache Docker images.
uses: ScribeMD/[email protected]
with:
key: docker-${{ runner.os }}-${{ inputs.kurtosis_version }}
- name: "Install shell dependencies"
shell: bash
run: |
Expand Down
4 changes: 4 additions & 0 deletions .github/workflows/_shared-run.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -58,6 +58,7 @@ jobs:
name="$(echo "$testcfg" | jq -r .name)"
clients="$(echo "$testcfg" | jq -r .clients)"
kurtosis="$(echo "$testcfg" | jq -r .kurtosis)"
kurtosis_version=$(curl -s https://api.github.com/repos/kurtosis-tech/kurtosis/releases/latest | jq -r .tag_name)
kurtosis_branch="$(echo "$testcfg" | jq -r '.kurtosis_branch // ""')"
worker="$(echo "$testcfg" | jq -c .worker)"
backend="$(echo "$testcfg" | jq -r .backend)"
Expand All @@ -74,6 +75,8 @@ jobs:
echo "clients=$(echo "$clients")" >> $GITHUB_OUTPUT
echo "Kurtosis yaml: $kurtosis"
echo "kurtosis=$(echo "$kurtosis")" >> $GITHUB_OUTPUT
echo "Kurtosis version: $kurtosis_version"
echo "kurtosis_version=$(echo "$kurtosis_version")" >> $GITHUB_OUTPUT
echo "Kurtosis package branch: $kurtosis_branch"
echo "kurtosis_branch=$(echo "$kurtosis_branch")" >> $GITHUB_OUTPUT
echo "Worker: $worker"
Expand Down Expand Up @@ -137,6 +140,7 @@ jobs:
pairs: ${{ matrix.pairs }}
worker: ${{ needs.get_test.outputs.worker }}
kurtosis: ${{ needs.get_test.outputs.kurtosis }}
kurtosis_version: ${{ needs.get_test.outputs.kurtosis_version }}
kurtosis_branch: ${{ needs.get_test.outputs.kurtosis_branch }}
backend: ${{ needs.get_test.outputs.backend }}
kubeCluster: ${{ needs.get_test.outputs.kubernetes_cluster }}
Expand Down

0 comments on commit 5e13ebb

Please sign in to comment.