From e6a56003dc58370bc01d4c5f2f869294b948ba02 Mon Sep 17 00:00:00 2001 From: quebim Date: Wed, 30 Oct 2024 13:20:00 -0300 Subject: [PATCH] Update GHA S3 check block to validate on the existing s3 bucket --- .github/workflows/build.yml | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index c305b708e94a1..ffee7dbc1aa26 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -312,9 +312,8 @@ jobs: - name: Check if package exists on S3 if: ${{ inputs.upload }} run: | - src="artifacts/dist/${{ steps.package.outputs.name }}" dest="s3://packages-dev.internal.wazuh.com/development/wazuh/5.x/main/packages/" - if aws s3api head-object --bucket --key ; then + if aws s3api head-object --bucket "$dest" --key "${{ steps.package.outputs.name }}"; then echo "exists=true" >> $GITHUB_OUTPUT else echo "exists=false" >> $GITHUB_OUTPUT