Skip to content

[MONGOCRYPT-838] Upload build artifacts to a restricted bucket on release branch builds#1126

Merged
kevinAlbs merged 10 commits intomongodb:masterfrom
vector-of-bool:MONGOCRYPT-838-restricted-uploads.2
Mar 17, 2026
Merged

[MONGOCRYPT-838] Upload build artifacts to a restricted bucket on release branch builds#1126
kevinAlbs merged 10 commits intomongodb:masterfrom
vector-of-bool:MONGOCRYPT-838-restricted-uploads.2

Conversation

@vector-of-bool
Copy link
Copy Markdown
Contributor

@vector-of-bool vector-of-bool commented Feb 12, 2026

Let's try this again. Refer: MONGOCRYPT-838

Summary

This changeset does the following:

  1. All S3 put operations now use permissions: private and visibility: signed.
  2. On any build that isn't in libmongocrypt-release or any build that is a patch, artifacts are transmitted in the mciuploads bucket using a less-restricted role for that bucket.
  3. On libmongocrypt-release commit or tag builds, artifacts are transmitted and posted in the cnd-origin-libmongocrypt bucket using a restricted role.

This change replaces all references to the mciuploads bucket in the CI
configuration file with a template expansion that conditionally refers to an
alternate bucket in certain scenarios. This templating also sets the role_arn
for S3 operations based on the same conditions.
@vector-of-bool
Copy link
Copy Markdown
Contributor Author

Need to be addressed: Some scripts still download (via HTTP) from the mciuploads buckets directly, specifically those related to the Python release. I think those can be updated separately as those tasks run on their own schedule and won't need updating until the next release.

@kevinAlbs
Copy link
Copy Markdown
Collaborator

kevinAlbs commented Feb 13, 2026

Need to be addressed: Some scripts still download (via HTTP) from the mciuploads

I also expect the "publish packages" function also needs to update the URL. Possibly with an addition:

if "${project}" = 'libmongocrypt-release'; then
  package_url_prefix="https://downloads.mongodb.org"
else
  package_url_prefix="https://mciuploads.s3.amazonaws.com"
fi

That runs on every mainline commit. So I expect that would need to be updated before cherry-picking to avoid failures in the publish-packages tasks.

Copy link
Copy Markdown
Collaborator

@kevinAlbs kevinAlbs left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM with a comment removal.

Comment thread .evergreen/config.yml Outdated
Copy link
Copy Markdown
Collaborator

@kevinAlbs kevinAlbs left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

To test before merging, I temporarily set the libmongocrypt-release Evergreen project to test a branch (MONGOCRYPT-838) with that PR to test the upload to the restricted bucket. With the added commits, the new upload appears to work.

@vector-of-bool vector-of-bool marked this pull request as ready for review March 17, 2026 15:13
@vector-of-bool vector-of-bool requested a review from a team as a code owner March 17, 2026 15:13
@kevinAlbs kevinAlbs removed the request for review from eramongodb March 17, 2026 15:15
@kevinAlbs kevinAlbs merged commit 6571317 into mongodb:master Mar 17, 2026
64 of 66 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants