Skip to content

Commit

Permalink
Replace s3 validation to use S3 ls api
Browse files Browse the repository at this point in the history
  • Loading branch information
QU3B1M committed Oct 30, 2024
1 parent e6a5600 commit 5bbf692
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -313,7 +313,8 @@ jobs:
if: ${{ inputs.upload }}
run: |
dest="s3://packages-dev.internal.wazuh.com/development/wazuh/5.x/main/packages/"
if aws s3api head-object --bucket "$dest" --key "${{ steps.package.outputs.name }}"; then
s3uri="${dest}${{ steps.package.outputs.name }}"
if aws s3 ls "$s3uri" > /dev/null 2>&1; then
echo "exists=true" >> $GITHUB_OUTPUT
else
echo "exists=false" >> $GITHUB_OUTPUT
Expand Down

0 comments on commit 5bbf692

Please sign in to comment.