-
Notifications
You must be signed in to change notification settings - Fork 1.8k
docs: add documentation for running aws integ tests locally #4830
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
base: main
Are you sure you want to change the base?
Conversation
| set -euxo pipefail # Exit on error, undefined variable, and fail on pipe errors | ||
|
|
||
| # NOTE: This script assumes that you've created an AWS SSO session already, as outlined in | ||
| # ./test/readme.md, section `AWS Profile`, and you have an AWS profile |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
| # ./test/readme.md, section `AWS Profile`, and you have an AWS profile | |
| # ../test/readme.md, section `AWS Profile`, and you have an AWS profile |
|
|
||
| Setup an AWS_PROFILE locally to be able to use AWS and to run AWS tests locally. | ||
|
|
||
| 1. Get SSO sign-in info from AWS |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Are these steps just a duplicate of the docs here? https://wiki.corp.mongodb.com/spaces/DRIVERS/pages/239737385/Using+AWS+Secrets+Manager+to+Store+Testing+Secrets
If so, I'd suggest just linking these docs instead
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Actually, we do link to these docs (indirectly) in the secrets section of the readme
| source $DRIVERS_TOOLS/.evergreen/init-node-and-npm-env.sh | ||
|
|
||
| # clear AWS_PROFILE, so it doesn't interfere with env-creds | ||
| unset AWS_PROFILE |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is this environment variable used by any AWS auth variants in CI?
aWs there a particular reason this change was needed? iirc the AWS credential provider SDK fetches credentials from the environment first. So it's unclear how having the AWS_PROFILE set would interfere with AWS environment variable credential fetching.
| @@ -0,0 +1,33 @@ | |||
| #!/usr/bin/env bash | |||
| set -euxo pipefail # Exit on error, undefined variable, and fail on pipe errors | |||
|
|
|||
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Generally, if we add a script that we plan to use for local testing, we also ensure that it is the same script used to run tests in CI. This ensures the script is always up-to-date.
- Is there something this script does that isn't captured by our testing readme's instructions?
- Do you think it's worth refactoring CI to use this script?
Description
Summary of Changes
Add documentation explaining how to run AWS integration tests locally.
Double check the following
npm run check:lint)type(NODE-xxxx)[!]: descriptionfeat(NODE-1234)!: rewriting everything in coffeescript