fix: add content-md5 header for artifacts #14140
Open
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
This change will allow objects to be written to buckets with S3 Object Lock enabled.
I have manually fixed bits of the jsonschema and swagger, but I've been unable to build the Java client locally. It's not entirely clear to me that this PR needs to include those changes, but it seems like it does. If a kind soul can give me a tip on getting it to build, I'm happy to try again. (See this comment in the issue.)
Fixes #11182
Motivation
As described in 11182, being able to use an object-lock enabled S3 bucket is desirable for organizations wanted to protect assets from destruction.
Modifications
Added
sendContentMD5
setting to S3 artifact configuration, and use that setting to enable sending the MD5 via argoproj/pkg.Verification
I have built images using this code and enabled this setting and objects appear correctly in S3.
Here's the relevant part of the
workflow-controller-configmap
:Here's an example artifact: