From 9a74616cb5ea7ea818f0726423950b8fc30ffb5d Mon Sep 17 00:00:00 2001 From: Hanno Becker Date: Sun, 8 Sep 2024 05:28:58 +0100 Subject: [PATCH] Clear nix-installer cache before running EC2 bench workflow --- .github/workflows/bench_ec2_reusable.yml | 11 +++++++++++ 1 file changed, 11 insertions(+) diff --git a/.github/workflows/bench_ec2_reusable.yml b/.github/workflows/bench_ec2_reusable.yml index 6f935b6c8..83d1727f1 100644 --- a/.github/workflows/bench_ec2_reusable.yml +++ b/.github/workflows/bench_ec2_reusable.yml @@ -44,6 +44,17 @@ jobs: label: ${{ steps.start-ec2-runner.outputs.label }} ec2-instance-id: ${{ steps.start-ec2-runner.outputs.ec2-instance-id }} steps: + - name: Clear nix-installer action cache + run: | + cache_keys=$(gh cache list -R ${{ env.REPO }} -k determinatesystem-nix-installer-aarch64-linux | cut -f 1) + echo "Deleting nix-installer caches..." + for key in $cache_keys + do + gh cache -R ${{ env.REPO }} delete $key + done + env: + GH_TOKEN: ${{ github.token }} + REPO: ${{ github.repository }} - name: Configure AWS credentials uses: aws-actions/configure-aws-credentials@v4 with: