From 0d1ce128e20c002d97a1ed6bfe6775a07af0bb94 Mon Sep 17 00:00:00 2001 From: Stefan Agner Date: Mon, 12 Aug 2024 14:47:42 +0200 Subject: [PATCH] Do not pull the latest version of builder when testing When testing, pulling the latest version makes the whole test kinda pointless, as the last version currently published gets tested instead of the just built one. Add a new argument so we can still reuse the same builder action, but skip pulling to reuse the freshly built builder. --- .github/workflows/test.yml | 1 + action.yml | 5 +++++ 2 files changed, 6 insertions(+) diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index 5d815bb..3963451 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -46,3 +46,4 @@ jobs: --${{ matrix.architecture }} \ --target /data \ --generic ${{ github.sha }} + no-pull: true diff --git a/action.yml b/action.yml index 7b257ee..c39a99a 100644 --- a/action.yml +++ b/action.yml @@ -5,6 +5,10 @@ inputs: description: "Arguments passed to the builder" required: true default: "--help" + no-pull: + description: "Do not pull the latest version of builder (for testing)" + required: false + default: false runs: using: "composite" steps: @@ -23,6 +27,7 @@ runs: echo "version=${input}" >> "$GITHUB_OUTPUT" - shell: bash + if: ${{ inputs.no-pull == true }} run: | docker pull ghcr.io/home-assistant/amd64-builder:${{ steps.version.outputs.version }} cosign verify \