Skip to content

CXX-3287 assume role before pull-mongohouse-image.sh #1413

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Jun 3, 2025
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
28 changes: 16 additions & 12 deletions .evergreen/config_generator/components/mongohouse.py
Original file line number Diff line number Diff line change
Expand Up @@ -17,18 +17,22 @@

class BuildMongohouse(Function):
name = 'build_mongohouse'
commands = bash_exec(
command_type=EvgCommandType.SETUP,
script='''\
if [ ! -d "drivers-evergreen-tools" ]; then
git clone https://github.com/mongodb-labs/drivers-evergreen-tools.git
fi
cd drivers-evergreen-tools
export DRIVERS_TOOLS=$(pwd)

.evergreen/atlas_data_lake/pull-mongohouse-image.sh
'''
)
commands = [
ec2_assume_role (role_arn='${aws_test_secrets_role}'),
bash_exec(
include_expansions_in_env=["AWS_ACCESS_KEY_ID", "AWS_SECRET_ACCESS_KEY", "AWS_SESSION_TOKEN"],
command_type=EvgCommandType.SETUP,
script='''\
if [ ! -d "drivers-evergreen-tools" ]; then
git clone https://github.com/mongodb-labs/drivers-evergreen-tools.git
fi
cd drivers-evergreen-tools
export DRIVERS_TOOLS=$(pwd)

.evergreen/atlas_data_lake/pull-mongohouse-image.sh
'''
)
]


class RunMongohouse(Function):
Expand Down
33 changes: 20 additions & 13 deletions .evergreen/generated_configs/functions.yml
Original file line number Diff line number Diff line change
Expand Up @@ -201,20 +201,27 @@ functions:
permissions: public-read
remote_file: mongo-cxx-driver/${branch_name}/${revision}/${version_id}/${build_id}/${execution}/rpm-packages.tar.gz
build_mongohouse:
command: subprocess.exec
type: setup
params:
binary: bash
args:
- -c
- |
if [ ! -d "drivers-evergreen-tools" ]; then
git clone https://github.com/mongodb-labs/drivers-evergreen-tools.git
fi
cd drivers-evergreen-tools
export DRIVERS_TOOLS=$(pwd)
- command: ec2.assume_role
params:
role_arn: ${aws_test_secrets_role}
- command: subprocess.exec
type: setup
params:
binary: bash
include_expansions_in_env:
- AWS_ACCESS_KEY_ID
- AWS_SECRET_ACCESS_KEY
- AWS_SESSION_TOKEN
args:
- -c
- |
if [ ! -d "drivers-evergreen-tools" ]; then
git clone https://github.com/mongodb-labs/drivers-evergreen-tools.git
fi
cd drivers-evergreen-tools
export DRIVERS_TOOLS=$(pwd)

.evergreen/atlas_data_lake/pull-mongohouse-image.sh
.evergreen/atlas_data_lake/pull-mongohouse-image.sh
check augmented sbom:
- command: ec2.assume_role
type: setup
Expand Down