Skip to content

[8.6] Use S3 conditional writes to prevent overwriting published artifacts - #11592

Merged
oshadmi merged 1 commit into
8.6from
backport-agent/pr-11532-to-8.6
Nov 29, 2026
Merged

oshadmi merged 1 commit into
8.6from
backport-agent/pr-11532-to-8.6

Conversation

@redisearch-backport-pull-request

Copy link
Copy Markdown
Contributor

Backport of #11532 to 8.6.
Merge commit: 046c693486a4a3c157a0f685cd299e4c448f98b9

Describe the changes in the pull request

  1. Current: artifact uploads (aws s3 cp) and the release copy (copy_object) silently overwrite whatever is already at the target key in s3://redismodules.
  2. Change: upload with aws s3api put-object --if-none-match "*" and copy with IfNoneMatch="*", so S3 rejects the write if the object exists.
  3. Outcome: CI only. A published snapshot or release artifact can no longer be replaced by a later run; the job fails instead.

Which additional issues this PR fixes

  1. N/A

Main objects this PR modified

  1. sbin/upload-artifacts — conditional put, rejected uploads fail the job
  2. event-release.yml set-artifacts — conditional copy

Mark if applicable

  • This PR introduces API changes
  • This PR introduces serialization changes

Release Notes

  • This PR requires release notes
  • This PR does not require release notes

…11532)

sbin/upload-artifacts now uploads via `aws s3api put-object --if-none-match "*"`
instead of `aws s3 cp`, and the release workflow's copy_object passes
IfNoneMatch="*". Both fail loudly if an object already exists at the target key
instead of silently overwriting it. upload-artifacts also propagates a rejected
upload to the job exit status, which the `{ ...; } || ...` construct swallowed.

(cherry picked from commit 046c693)
@sonarqubecloud

Copy link
Copy Markdown

@redisearch-backport-pull-request
redisearch-backport-pull-request Bot added this pull request to the merge queue Sep 28, 2026
@github-merge-queue
github-merge-queue Bot removed this pull request from the merge queue due to failed status checks Sep 28, 2026
@AngelYanev
AngelYanev added this pull request to the merge queue Sep 30, 2026
@github-merge-queue
github-merge-queue Bot removed this pull request from the merge queue due to failed status checks Sep 30, 2026
@oshadmi
oshadmi merged commit 255120e into 8.6 Nov 29, 2026
35 checks passed
@oshadmi
oshadmi deleted the backport-agent/pr-11532-to-8.6 branch November 29, 2026 07:39
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

auto-backport This PR was automatically backported by an agent size:S

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants