######################################## # Evergreen Template for MongoDB Drivers ######################################## # When a task that used to pass starts to fail # Go through all versions that may have been skipped to detect # when the task started failing stepback: true # Mark a failure as a system/bootstrap failure (purple box) rather then a task # failure by default. # Actual testing tasks are marked with `type: test` command_type: setup # Fail builds when pre tasks fail. pre_error_fails_task: true # Protect the CI from long or indefinite runtimes. exec_timeout_secs: 3600 # What to do when evergreen hits the timeout (`post:` tasks are run automatically) timeout: - command: subprocess.exec params: binary: bash args: [ls, -la] functions: setup-system: # Executes clone and applies the submitted patch, if any - command: git.get_project type: system params: directory: src/go.mongodb.org/mongo-driver - command: shell.exec params: working_dir: "src/go.mongodb.org/mongo-driver" script: | git submodule update --init # Make an env.sh and evergreen expansion file with dynamic values - command: subprocess.exec params: binary: bash working_dir: src/go.mongodb.org/mongo-driver env: GOROOT: ${GO_DIST} IS_PATCH: ${is_patch} VERSION_ID: ${version_id} # Define an alias for the task runner script. TASK_RUNNER_ALIAS: &task-runner src/go.mongodb.org/mongo-driver/.evergreen/run-task.sh args: [.evergreen/setup-system.sh] - command: expansions.update params: file: src/go.mongodb.org/mongo-driver/expansion.yml - command: subprocess.exec params: binary: bash include_expansions_in_env: ["PROJECT_DIRECTORY"] args: - "${DRIVERS_TOOLS}/.evergreen/setup.sh" handle-test-artifacts: - command: gotest.parse_files params: optional_output: "true" files: - "src/go.mongodb.org/mongo-driver/*.suite" - command: ec2.assume_role params: role_arn: ${assume_role_arn} - command: s3.put params: aws_key: ${AWS_ACCESS_KEY_ID} aws_secret: ${AWS_SECRET_ACCESS_KEY} aws_session_token: ${AWS_SESSION_TOKEN} local_file: ${DRIVERS_TOOLS}/.evergreen/test_logs.tar.gz remote_file: ${build_variant}/${revision}/${version_id}/${build_id}/logs/${task_id}-${execution}-drivers-tools-logs.tar.gz bucket: ${aws_bucket} permissions: public-read content_type: ${content_type|application/x-gzip} display_name: "drivers-tools-logs.tar.gz" - command: s3.put params: aws_key: ${AWS_ACCESS_KEY_ID} aws_secret: ${AWS_SECRET_ACCESS_KEY} aws_session_token: ${AWS_SESSION_TOKEN} optional: true local_file: ${PROJECT_DIRECTORY}/fuzz.tgz remote_file: ${build_variant}/${revision}/${version_id}/${build_id}/${task_id}-${execution}-fuzz.tgz bucket: ${aws_bucket} permissions: public-read content_type: application/x-gzip display_name: "fuzz.tgz" - command: subprocess.exec params: binary: bash args: [*task-runner, evg-gather-test-suites] - command: s3.put params: aws_key: ${AWS_ACCESS_KEY_ID} aws_secret: ${AWS_SECRET_ACCESS_KEY} aws_session_token: ${AWS_SESSION_TOKEN} local_file: src/go.mongodb.org/mongo-driver/test_suite.tgz optional: true remote_file: ${build_variant}/${revision}/${version_id}/${build_id}/logs/${task_id}-${execution}-test_suite.tgz bucket: ${aws_bucket} permissions: public-read content_type: ${content_type|text/plain} display_name: test_suite.tgz bootstrap-mongohoused: - command: ec2.assume_role params: role_arn: ${aws_test_secrets_role} - command: subprocess.exec params: binary: bash add_expansions_to_env: true args: - ${DRIVERS_TOOLS}/.evergreen/atlas_data_lake/pull-mongohouse-image.sh - command: subprocess.exec params: binary: bash args: - ${DRIVERS_TOOLS}/.evergreen/atlas_data_lake/run-mongohouse-image.sh bootstrap-mongo-orchestration: - command: subprocess.exec params: binary: bash env: MONGODB_VERSION: ${VERSION} include_expansions_in_env: [TOPOLOGY, AUTH, SSL, ORCHESTRATION_FILE, REQUIRE_API_VERSION, LOAD_BALANCER] args: ["${DRIVERS_TOOLS}/.evergreen/run-orchestration.sh"] - command: expansions.update params: file: mo-expansion.yml ocsp-bootstrap-mongo-orchestration: - command: subprocess.exec params: binary: bash env: MONGODB_VERSION: ${VERSION} include_expansions_in_env: [TOPOLOGY, AUTH, SSL, ORCHESTRATION_FILE] args: ["${DRIVERS_TOOLS}/.evergreen/run-orchestration.sh"] - command: expansions.update params: file: mo-expansion.yml teardown: - command: subprocess.exec params: binary: bash args: # Ensure the instance profile is reassigned for aws tests. - ${DRIVERS_TOOLS}/.evergreen/auth_aws/teardown.sh - command: subprocess.exec params: binary: bash args: - ${DRIVERS_TOOLS}/.evergreen/csfle/teardown.sh - command: subprocess.exec params: binary: bash args: - ${DRIVERS_TOOLS}/.evergreen/ocsp/teardown.sh - command: subprocess.exec params: binary: bash args: - ${DRIVERS_TOOLS}/.evergreen/teardown.sh assume-test-secrets-ec2-role: - command: ec2.assume_role params: role_arn: ${aws_test_secrets_role} duration_seconds: 1800 run-oidc-auth-test-with-test-credentials: - command: subprocess.exec type: test params: binary: bash env: OIDC: oidc include_expansions_in_env: [DRIVERS_TOOLS, AWS_ACCESS_KEY_ID, AWS_SECRET_ACCESS_KEY, AWS_SESSION_TOKEN] args: [*task-runner, test-oidc] run-tests: - command: subprocess.exec params: binary: bash env: GO_BUILD_TAGS: "cse,mongointernal" include_expansions_in_env: ["TOPOLOGY", "AUTH", "SSL", "SKIP_CSOT_TESTS", "MONGODB_URI", "CRYPT_SHARED_LIB_PATH", "SKIP_CRYPT_SHARED_LIB", "RACE", "MONGO_GO_DRIVER_COMPRESSOR", "REQUIRE_API_VERSION", "LOAD_BALANCER"] args: [*task-runner, setup-test] - command: subprocess.exec type: test retry_on_failure: true params: binary: bash args: [*task-runner, "${DEFAULT_TASK}"] create-api-report: - command: subprocess.exec type: test params: binary: bash add_expansions_to_env: true env: BASE_SHA: "${revision}" HEAD_SHA: "${github_commit}" args: [*task-runner, api-report] "backport pr": - command: subprocess.exec type: test params: binary: bash env: COMMIT: "${github_commit}" PR_TASK: backport-pr args: [*task-runner, pr-task] send-perf-data: # Here we begin to generate the request to send the data to SPS - command: shell.exec params: script: | # We use the requester expansion to determine whether the data is from a mainline evergreen run or not if [ "${requester}" == "commit" ]; then is_mainline=true else is_mainline=false fi # We parse the username out of the order_id as patches append that in and SPS does not need that information parsed_order_id=$(echo "${revision_order_id}" | awk -F'_' '{print $NF}') # Submit the performance data to the SPS endpoint response=$(curl -s -w "\nHTTP_STATUS:%{http_code}" -X 'POST' \ "https://performance-monitoring-api.corp.mongodb.com/raw_perf_results/cedar_report?project=${project_id}&version=${version_id}&variant=${build_variant}&order=$parsed_order_id&task_name=${task_name}&task_id=${task_id}&execution=${execution}&mainline=$is_mainline" \ -H 'accept: application/json' \ -H 'Content-Type: application/json' \ -d @src/go.mongodb.org/mongo-driver/perf.json) http_status=$(echo "$response" | grep "HTTP_STATUS" | awk -F':' '{print $2}') response_body=$(echo "$response" | sed '/HTTP_STATUS/d') # We want to throw an error if the data was not successfully submitted if [ "$http_status" -ne 200 ]; then echo "Error: Received HTTP status $http_status" echo "Response Body: $response_body" exit 1 fi echo "Response Body: $response_body" echo "HTTP Status: $http_status" send-perf-pr-comment: - command: subprocess.exec type: test params: binary: bash add_expansions_to_env: true env: VERSION_ID: ${version_id} BASE_SHA: "${revision}" HEAD_SHA: "${github_commit}" include_expansions_in_env: [PERF_URI_PRIVATE_ENDPOINT] args: [*task-runner, perf-pr-comment] run-enterprise-auth-tests: - command: ec2.assume_role params: role_arn: "${aws_test_secrets_role}" - command: subprocess.exec params: binary: bash include_expansions_in_env: [AWS_ACCESS_KEY_ID, AWS_SECRET_ACCESS_KEY, AWS_SESSION_TOKEN] env: TEST_ENTERPRISE_AUTH: plain args: [*task-runner, setup-test] - command: subprocess.exec type: test retry_on_failure: true params: binary: bash args: [*task-runner, --silent, evg-test-enterprise-auth] run-enterprise-gssapi-auth-tests: - command: ec2.assume_role params: role_arn: "${aws_test_secrets_role}" - command: subprocess.exec params: binary: bash include_expansions_in_env: [AWS_ACCESS_KEY_ID, AWS_SECRET_ACCESS_KEY, AWS_SESSION_TOKEN] env: TEST_ENTERPRISE_AUTH: gssapi args: [*task-runner, setup-test] - command: subprocess.exec type: test retry_on_failure: true params: binary: bash args: [*task-runner, --silent, evg-test-enterprise-auth] run-atlas-test: - command: ec2.assume_role params: role_arn: "${aws_test_secrets_role}" - command: subprocess.exec params: binary: bash include_expansions_in_env: [AWS_ACCESS_KEY_ID, AWS_SECRET_ACCESS_KEY, AWS_SESSION_TOKEN] env: TEST_ATLAS_CONNECT: "1" args: [*task-runner, setup-test] - command: subprocess.exec type: test retry_on_failure: true params: binary: bash args: [*task-runner, test-atlas-connect] run-ocsp-test: - command: subprocess.exec params: binary: bash env: TOPOLOGY: server AUTH: auth SSL: ssl include_expansions_in_env: [OCSP_ALGORITHM, MONGODB_URI] args: [*task-runner, setup-test] - command: subprocess.exec type: test retry_on_failure: true params: binary: bash include_expansions_in_env: [OCSP_TLS_SHOULD_SUCCEED] args: [*task-runner, evg-test-ocsp] run-versioned-api-test: - command: subprocess.exec params: binary: bash env: GO_BUILD_TAGS: cse include_expansions_in_env: [AUTH, SSL, MONGODB_URI, TOPOLOGY, MONGO_GO_DRIVER_COMPRESSOR, REQUIRE_API_VERSION, SKIP_CRYPT_SHARED_LIB, CRYPT_SHARED_LIB_PATH] args: [*task-runner, setup-test] - command: subprocess.exec type: test retry_on_failure: true params: binary: bash args: [*task-runner, evg-test-versioned-api] run-load-balancer-tests: - command: subprocess.exec params: binary: bash include_expansions_in_env: [SINGLE_MONGOS_LB_URI, MULTI_MONGOS_LB_URI, AUTH, SSL, MONGO_GO_DRIVER_COMPRESSOR] env: LOAD_BALANCER: "true" args: [*task-runner, setup-test] - command: subprocess.exec type: test retry_on_failure: true params: binary: bash args: [*task-runner, evg-test-load-balancers] run-docker-test: - command: subprocess.exec type: test params: binary: "bash" env: TASKFILE_TARGET: test-short args: [*task-runner, run-docker] - command: subprocess.exec type: test params: binary: "bash" env: TOPOLOGY: sharded_cluster TASKFILE_TARGET: test-short args: [*task-runner, run-docker] run-goleak-test: - command: subprocess.exec type: test params: binary: "bash" include_expansions_in_env: ["MONGODB_URI"] args: [*task-runner, test-goleak] "run oidc k8s test": - command: subprocess.exec type: test params: binary: bash include_expansions_in_env: [AWS_ACCESS_KEY_ID, AWS_SECRET_ACCESS_KEY, AWS_SESSION_TOKEN, VARIANT, DRIVERS_TOOLS] env: OIDC_ENV: k8s args: [*task-runner, test-oidc-remote] run-ocsp-server: - command: subprocess.exec params: binary: bash background: true include_expansions_in_env: [SERVER_TYPE, OCSP_ALGORITHM] args: - ${DRIVERS_TOOLS}/.evergreen/ocsp/setup.sh run-load-balancer: - command: subprocess.exec params: binary: "bash" include_expansions_in_env: ["MONGODB-AWS", "MONGODB_URI"] args: ["${DRIVERS_TOOLS}/.evergreen/run-load-balancer.sh", start] - command: expansions.update params: file: lb-expansion.yml run-search-index-tests: - command: subprocess.exec type: test params: binary: "bash" env: SEARCH_INDEX_URI: "${SEARCH_INDEX_URI}" args: [*task-runner, evg-test-search-index] add-aws-auth-variables-to-file: - command: ec2.assume_role params: role_arn: ${aws_test_secrets_role} - command: subprocess.exec type: test params: include_expansions_in_env: ["AWS_ACCESS_KEY_ID", "AWS_SECRET_ACCESS_KEY", "AWS_SESSION_TOKEN"] binary: "bash" args: - ${DRIVERS_TOOLS}/.evergreen/auth_aws/setup-secrets.sh run-aws-auth-test-with-regular-aws-credentials: - command: subprocess.exec type: test params: binary: "bash" env: AWS_TEST: regular args: [*task-runner, evg-test-aws] run-aws-auth-test-with-assume-role-credentials: - command: subprocess.exec type: test params: binary: "bash" env: AWS_TEST: assume-role args: [*task-runner, evg-test-aws] run-aws-auth-test-with-aws-EC2-credentials: - command: subprocess.exec type: test params: binary: bash include_expansions_in_env: [SKIP_EC2_AUTH_TEST] env: AWS_TEST: ec2 args: [*task-runner, evg-test-aws] run-aws-auth-test-with-aws-credentials-as-environment-variables: - command: subprocess.exec type: test params: binary: "bash" env: AWS_TEST: env-creds args: [*task-runner, evg-test-aws] run-aws-auth-test-with-aws-credentials-and-session-token-as-environment-variables: - command: subprocess.exec type: test params: binary: "bash" env: AWS_TEST: session-creds args: [*task-runner, evg-test-aws] run-aws-ECS-auth-test: - command: subprocess.exec type: test params: binary: "bash" include_expansions_in_env: [SKIP_ECS_AUTH_TEST] args: [*task-runner, evg-test-aws-ecs] run-aws-auth-test-with-aws-web-identity-credentials: - command: subprocess.exec type: test params: binary: bash include_expansions_in_env: [SKIP_WEB_IDENTITY_AUTH_TEST] env: AWS_TEST: web-identity args: [*task-runner, evg-test-aws] - command: subprocess.exec type: test params: binary: bash env: AWS_ROLE_SESSION_NAME: test AWS_TEST: web-identity include_expansions_in_env: [SKIP_WEB_IDENTITY_AUTH_TEST] args: [*task-runner, evg-test-aws] start-cse-servers: - command: ec2.assume_role params: role_arn: ${aws_test_secrets_role} - command: subprocess.exec params: working_dir: src/go.mongodb.org/mongo-driver binary: bash background: true include_expansions_in_env: ["AWS_ACCESS_KEY_ID", "AWS_SECRET_ACCESS_KEY", "AWS_SESSION_TOKEN", "DRIVERS_TOOLS"] # This cannot use task because it will hang on Windows. args: [etc/setup-encryption.sh] - command: subprocess.exec params: binary: bash args: ["${DRIVERS_TOOLS}/.evergreen/csfle/await-servers.sh"] run-kmip-tests: - command: subprocess.exec params: binary: "bash" env: GO_BUILD_TAGS: cse include_expansions_in_env: [AUTH, SSL, MONGODB_URI, TOPOLOGY, MONGO_GO_DRIVER_COMPRESSOR] args: [*task-runner, setup-test] - command: subprocess.exec type: test retry_on_failure: true params: binary: "bash" env: KMS_MOCK_SERVERS_RUNNING: "true" args: [*task-runner, evg-test-kmip] run-client-side-encryption-test: - command: subprocess.exec params: binary: "bash" env: GO_BUILD_TAGS: cse include_expansions_in_env: [AUTH, SSL, MONGODB_URI, TOPOLOGY, MONGO_GO_DRIVER_COMPRESSOR, CRYPT_SHARED_LIB_PATH] args: [*task-runner, setup-test] - command: subprocess.exec type: test retry_on_failure: true params: binary: "bash" env: KMS_MOCK_SERVERS_RUNNING: "true" KMS_FAILPOINT_CA_FILE: "${DRIVERS_TOOLS}/.evergreen/x509gen/ca.pem" KMS_FAILPOINT_SERVER_RUNNING: "true" args: [*task-runner, evg-test-client-side-encryption] run-fuzz-tests: - command: subprocess.exec type: test params: binary: "bash" args: [*task-runner, run-fuzz] pre: - func: setup-system post: - func: teardown - func: handle-test-artifacts tasks: - name: static-analysis tags: ["static-analysis"] commands: - command: subprocess.exec params: binary: bash args: [*task-runner, check-fmt, check-license, check-modules, lint] - name: govulncheck tags: ["static-analysis"] commands: - command: subprocess.exec type: test params: binary: bash args: [*task-runner, govulncheck] - name: pull-request-helpers allowed_requesters: ["patch", "github_pr"] commands: - func: assume-test-secrets-ec2-role - func: "create-api-report" - name: backport-pr allowed_requesters: ["commit"] commands: - func: "backport pr" - name: perf tags: ["performance"] exec_timeout_secs: 7200 commands: - func: bootstrap-mongo-orchestration vars: VERSION: "v6.0-perf" TOPOLOGY: "server" AUTH: "noauth" SSL: "nossl" SKIP_LEGACY_SHELL: "true" - command: subprocess.exec params: binary: bash args: [*task-runner, driver-benchmark] - func: assume-test-secrets-ec2-role - func: send-perf-data - func: send-perf-pr-comment - name: test-standalone-noauth-nossl tags: ["test", "standalone"] commands: - func: bootstrap-mongo-orchestration vars: TOPOLOGY: "server" AUTH: "noauth" SSL: "nossl" - func: start-cse-servers - func: run-tests vars: TOPOLOGY: "server" AUTH: "noauth" SSL: "nossl" - name: test-standalone-noauth-nossl-snappy-compression tags: ["test", "standalone", "compression", "snappy"] commands: - func: bootstrap-mongo-orchestration vars: TOPOLOGY: "server" AUTH: "noauth" SSL: "nossl" - func: start-cse-servers - func: run-tests vars: TOPOLOGY: "server" AUTH: "noauth" SSL: "nossl" MONGO_GO_DRIVER_COMPRESSOR: "snappy" - name: test-standalone-noauth-nossl-zlib-compression tags: ["test", "standalone", "compression", "zlib"] commands: - func: bootstrap-mongo-orchestration vars: TOPOLOGY: "server" AUTH: "noauth" SSL: "nossl" - func: start-cse-servers - func: run-tests vars: TOPOLOGY: "server" AUTH: "noauth" SSL: "nossl" MONGO_GO_DRIVER_COMPRESSOR: "zlib" - name: test-standalone-noauth-nossl-zstd-compression tags: ["test", "standalone", "compression", "zstd"] commands: - func: bootstrap-mongo-orchestration vars: TOPOLOGY: "server" AUTH: "noauth" SSL: "nossl" - func: start-cse-servers - func: run-tests vars: TOPOLOGY: "server" AUTH: "noauth" SSL: "nossl" MONGO_GO_DRIVER_COMPRESSOR: "zstd" - name: test-standalone-auth-ssl tags: ["test", "standalone", "authssl"] commands: - func: bootstrap-mongo-orchestration vars: TOPOLOGY: "server" AUTH: "auth" SSL: "ssl" - func: start-cse-servers - func: run-tests vars: TOPOLOGY: "server" AUTH: "auth" SSL: "ssl" - name: test-standalone-auth-nossl tags: ["test", "standalone", "authssl"] commands: - func: bootstrap-mongo-orchestration vars: TOPOLOGY: "server" AUTH: "auth" SSL: "nossl" - func: start-cse-servers - func: run-tests vars: TOPOLOGY: "server" AUTH: "auth" SSL: "nossl" - name: test-standalone-auth-ssl-snappy-compression tags: ["test", "standalone", "authssl", "compression", "snappy"] commands: - func: bootstrap-mongo-orchestration vars: TOPOLOGY: "server" AUTH: "auth" SSL: "ssl" - func: start-cse-servers - func: run-tests vars: TOPOLOGY: "server" AUTH: "auth" SSL: "ssl" MONGO_GO_DRIVER_COMPRESSOR: "snappy" - name: test-standalone-auth-ssl-zlib-compression tags: ["test", "standalone", "authssl", "compression", "zlib"] commands: - func: bootstrap-mongo-orchestration vars: TOPOLOGY: "server" AUTH: "auth" SSL: "ssl" - func: start-cse-servers - func: run-tests vars: TOPOLOGY: "server" AUTH: "auth" SSL: "ssl" MONGO_GO_DRIVER_COMPRESSOR: "zlib" - name: test-standalone-auth-ssl-zstd-compression tags: ["test", "standalone", "authssl", "compression", "zstd"] commands: - func: bootstrap-mongo-orchestration vars: TOPOLOGY: "server" AUTH: "auth" SSL: "ssl" - func: start-cse-servers - func: run-tests vars: TOPOLOGY: "server" AUTH: "auth" SSL: "ssl" MONGO_GO_DRIVER_COMPRESSOR: "zstd" - name: test-ocsp-rsa-valid-cert-server-staples tags: ["ocsp", "ocsp-rsa", "ocsp-staple"] commands: - func: run-ocsp-server vars: OCSP_ALGORITHM: "rsa" SERVER_TYPE: valid - func: ocsp-bootstrap-mongo-orchestration vars: ORCHESTRATION_FILE: "rsa-basic-tls-ocsp-mustStaple.json" - func: run-ocsp-test vars: OCSP_ALGORITHM: "rsa" OCSP_TLS_SHOULD_SUCCEED: "true" - name: test-ocsp-rsa-invalid-cert-server-staples tags: ["ocsp", "ocsp-rsa", "ocsp-staple"] commands: - func: run-ocsp-server vars: OCSP_ALGORITHM: "rsa" SERVER_TYPE: revoked - func: ocsp-bootstrap-mongo-orchestration vars: ORCHESTRATION_FILE: "rsa-basic-tls-ocsp-mustStaple.json" - func: run-ocsp-test vars: OCSP_ALGORITHM: "rsa" OCSP_TLS_SHOULD_SUCCEED: "false" - name: test-ocsp-rsa-valid-cert-server-does-not-staple tags: ["ocsp", "ocsp-rsa"] commands: - func: run-ocsp-server vars: OCSP_ALGORITHM: "rsa" SERVER_TYPE: valid - func: ocsp-bootstrap-mongo-orchestration vars: ORCHESTRATION_FILE: "rsa-basic-tls-ocsp-disableStapling.json" - func: run-ocsp-test vars: OCSP_ALGORITHM: "rsa" OCSP_TLS_SHOULD_SUCCEED: "true" - name: test-ocsp-rsa-invalid-cert-server-does-not-staple tags: ["ocsp", "ocsp-rsa"] commands: - func: run-ocsp-server vars: OCSP_ALGORITHM: "rsa" SERVER_TYPE: revoked - func: ocsp-bootstrap-mongo-orchestration vars: ORCHESTRATION_FILE: "rsa-basic-tls-ocsp-disableStapling.json" - func: run-ocsp-test vars: OCSP_ALGORITHM: "rsa" OCSP_TLS_SHOULD_SUCCEED: "false" - name: test-ocsp-rsa-soft-fail tags: ["ocsp", "ocsp-rsa"] commands: - func: ocsp-bootstrap-mongo-orchestration vars: ORCHESTRATION_FILE: "rsa-basic-tls-ocsp-disableStapling.json" - func: run-ocsp-test vars: OCSP_ALGORITHM: "rsa" OCSP_TLS_SHOULD_SUCCEED: "true" - name: test-ocsp-rsa-malicious-invalid-cert-mustStaple-server-does-not-staple tags: ["ocsp", "ocsp-rsa"] commands: - func: run-ocsp-server vars: OCSP_ALGORITHM: "rsa" SERVER_TYPE: revoked - func: ocsp-bootstrap-mongo-orchestration vars: ORCHESTRATION_FILE: "rsa-basic-tls-ocsp-mustStaple-disableStapling.json" - func: run-ocsp-test vars: OCSP_ALGORITHM: "rsa" OCSP_TLS_SHOULD_SUCCEED: "false" - name: test-ocsp-rsa-malicious-no-responder-mustStaple-server-does-not-staple tags: ["ocsp", "ocsp-rsa"] commands: - func: ocsp-bootstrap-mongo-orchestration vars: ORCHESTRATION_FILE: "rsa-basic-tls-ocsp-mustStaple-disableStapling.json" - func: run-ocsp-test vars: OCSP_ALGORITHM: "rsa" OCSP_TLS_SHOULD_SUCCEED: "false" - name: test-ocsp-rsa-delegate-valid-cert-server-staples tags: ["ocsp", "ocsp-rsa", "ocsp-staple"] commands: - func: run-ocsp-server vars: OCSP_ALGORITHM: "rsa" SERVER_TYPE: valid-delegate - func: ocsp-bootstrap-mongo-orchestration vars: ORCHESTRATION_FILE: "rsa-basic-tls-ocsp-mustStaple.json" - func: run-ocsp-test vars: OCSP_ALGORITHM: "rsa" OCSP_TLS_SHOULD_SUCCEED: "true" - name: test-ocsp-rsa-delegate-invalid-cert-server-staples tags: ["ocsp", "ocsp-rsa", "ocsp-staple"] commands: - func: run-ocsp-server vars: OCSP_ALGORITHM: "rsa" SERVER_TYPE: revoked-delegate - func: ocsp-bootstrap-mongo-orchestration vars: ORCHESTRATION_FILE: "rsa-basic-tls-ocsp-mustStaple.json" - func: run-ocsp-test vars: OCSP_ALGORITHM: "rsa" OCSP_TLS_SHOULD_SUCCEED: "false" - name: test-ocsp-rsa-delegate-valid-cert-server-does-not-staple tags: ["ocsp", "ocsp-rsa"] commands: - func: run-ocsp-server vars: OCSP_ALGORITHM: "rsa" SERVER_TYPE: valid-delegate - func: ocsp-bootstrap-mongo-orchestration vars: ORCHESTRATION_FILE: "rsa-basic-tls-ocsp-disableStapling.json" - func: run-ocsp-test vars: OCSP_ALGORITHM: "rsa" OCSP_TLS_SHOULD_SUCCEED: "true" - name: test-ocsp-rsa-delegate-invalid-cert-server-does-not-staple tags: ["ocsp", "ocsp-rsa"] commands: - func: run-ocsp-server vars: OCSP_ALGORITHM: "rsa" SERVER_TYPE: revoked-delegate - func: ocsp-bootstrap-mongo-orchestration vars: ORCHESTRATION_FILE: "rsa-basic-tls-ocsp-disableStapling.json" - func: run-ocsp-test vars: OCSP_ALGORITHM: "rsa" OCSP_TLS_SHOULD_SUCCEED: "false" - name: test-ocsp-rsa-delegate-malicious-invalid-cert-mustStaple-server-does-not-staple tags: ["ocsp", "ocsp-rsa"] commands: - func: run-ocsp-server vars: OCSP_ALGORITHM: "rsa" SERVER_TYPE: revoked-delegate - func: ocsp-bootstrap-mongo-orchestration vars: ORCHESTRATION_FILE: "rsa-basic-tls-ocsp-mustStaple-disableStapling.json" - func: run-ocsp-test vars: OCSP_ALGORITHM: "rsa" OCSP_TLS_SHOULD_SUCCEED: "false" - name: test-ocsp-ecdsa-valid-cert-server-staples tags: ["ocsp", "ocsp-ecdsa", "ocsp-staple"] commands: - func: run-ocsp-server vars: OCSP_ALGORITHM: "ecdsa" SERVER_TYPE: valid - func: ocsp-bootstrap-mongo-orchestration vars: ORCHESTRATION_FILE: "ecdsa-basic-tls-ocsp-mustStaple.json" - func: run-ocsp-test vars: OCSP_ALGORITHM: "ecdsa" OCSP_TLS_SHOULD_SUCCEED: "true" - name: test-ocsp-ecdsa-invalid-cert-server-staples tags: ["ocsp", "ocsp-ecdsa", "ocsp-staple"] commands: - func: run-ocsp-server vars: OCSP_ALGORITHM: "ecdsa" SERVER_TYPE: revoked - func: ocsp-bootstrap-mongo-orchestration vars: ORCHESTRATION_FILE: "ecdsa-basic-tls-ocsp-mustStaple.json" - func: run-ocsp-test vars: OCSP_ALGORITHM: "ecdsa" OCSP_TLS_SHOULD_SUCCEED: "false" - name: test-ocsp-ecdsa-valid-cert-server-does-not-staple tags: ["ocsp", "ocsp-ecdsa"] commands: - func: run-ocsp-server vars: OCSP_ALGORITHM: "ecdsa" SERVER_TYPE: valid - func: ocsp-bootstrap-mongo-orchestration vars: ORCHESTRATION_FILE: "ecdsa-basic-tls-ocsp-disableStapling.json" - func: run-ocsp-test vars: OCSP_ALGORITHM: "ecdsa" OCSP_TLS_SHOULD_SUCCEED: "true" - name: test-ocsp-ecdsa-invalid-cert-server-does-not-staple tags: ["ocsp", "ocsp-ecdsa"] commands: - func: run-ocsp-server vars: OCSP_ALGORITHM: "ecdsa" SERVER_TYPE: revoked - func: ocsp-bootstrap-mongo-orchestration vars: ORCHESTRATION_FILE: "ecdsa-basic-tls-ocsp-disableStapling.json" - func: run-ocsp-test vars: OCSP_ALGORITHM: "ecdsa" OCSP_TLS_SHOULD_SUCCEED: "false" - name: test-ocsp-ecdsa-soft-fail tags: ["ocsp", "ocsp-ecdsa"] commands: - func: ocsp-bootstrap-mongo-orchestration vars: ORCHESTRATION_FILE: "ecdsa-basic-tls-ocsp-disableStapling.json" - func: run-ocsp-test vars: OCSP_ALGORITHM: "ecdsa" OCSP_TLS_SHOULD_SUCCEED: "true" - name: test-ocsp-ecdsa-malicious-invalid-cert-mustStaple-server-does-not-staple tags: ["ocsp", "ocsp-ecdsa"] commands: - func: run-ocsp-server vars: OCSP_ALGORITHM: "ecdsa" SERVER_TYPE: revoked - func: ocsp-bootstrap-mongo-orchestration vars: ORCHESTRATION_FILE: "ecdsa-basic-tls-ocsp-mustStaple-disableStapling.json" - func: run-ocsp-test vars: OCSP_ALGORITHM: "ecdsa" OCSP_TLS_SHOULD_SUCCEED: "false" - name: test-ocsp-ecdsa-malicious-no-responder-mustStaple-server-does-not-staple tags: ["ocsp", "ocsp-ecdsa"] commands: - func: ocsp-bootstrap-mongo-orchestration vars: ORCHESTRATION_FILE: "ecdsa-basic-tls-ocsp-mustStaple-disableStapling.json" - func: run-ocsp-test vars: OCSP_ALGORITHM: "ecdsa" OCSP_TLS_SHOULD_SUCCEED: "false" - name: test-ocsp-ecdsa-delegate-valid-cert-server-staples tags: ["ocsp", "ocsp-ecdsa", "ocsp-staple"] commands: - func: run-ocsp-server vars: OCSP_ALGORITHM: "ecdsa" SERVER_TYPE: valid-delegate - func: ocsp-bootstrap-mongo-orchestration vars: ORCHESTRATION_FILE: "ecdsa-basic-tls-ocsp-mustStaple.json" - func: run-ocsp-test vars: OCSP_ALGORITHM: "ecdsa" OCSP_TLS_SHOULD_SUCCEED: "true" - name: test-ocsp-ecdsa-delegate-invalid-cert-server-staples tags: ["ocsp", "ocsp-ecdsa", "ocsp-staple"] commands: - func: run-ocsp-server vars: OCSP_ALGORITHM: "ecdsa" SERVER_TYPE: revoked-delegate - func: ocsp-bootstrap-mongo-orchestration vars: ORCHESTRATION_FILE: "ecdsa-basic-tls-ocsp-mustStaple.json" - func: run-ocsp-test vars: OCSP_ALGORITHM: "ecdsa" OCSP_TLS_SHOULD_SUCCEED: "false" - name: test-ocsp-ecdsa-delegate-valid-cert-server-does-not-staple tags: ["ocsp", "ocsp-ecdsa"] commands: - func: run-ocsp-server vars: OCSP_ALGORITHM: "ecdsa" SERVER_TYPE: valid-delegate - func: ocsp-bootstrap-mongo-orchestration vars: ORCHESTRATION_FILE: "ecdsa-basic-tls-ocsp-disableStapling.json" - func: run-ocsp-test vars: OCSP_ALGORITHM: "ecdsa" OCSP_TLS_SHOULD_SUCCEED: "true" - name: test-ocsp-ecdsa-delegate-invalid-cert-server-does-not-staple tags: ["ocsp", "ocsp-ecdsa"] commands: - func: run-ocsp-server vars: OCSP_ALGORITHM: "ecdsa" SERVER_TYPE: revoked-delegate - func: ocsp-bootstrap-mongo-orchestration vars: ORCHESTRATION_FILE: "ecdsa-basic-tls-ocsp-disableStapling.json" - func: run-ocsp-test vars: OCSP_ALGORITHM: "ecdsa" OCSP_TLS_SHOULD_SUCCEED: "false" - name: test-ocsp-ecdsa-delegate-malicious-invalid-cert-mustStaple-server-does-not-staple tags: ["ocsp", "ocsp-ecdsa"] commands: - func: run-ocsp-server vars: OCSP_ALGORITHM: "ecdsa" SERVER_TYPE: revoked-delegate - func: ocsp-bootstrap-mongo-orchestration vars: ORCHESTRATION_FILE: "ecdsa-basic-tls-ocsp-mustStaple-disableStapling.json" - func: run-ocsp-test vars: OCSP_ALGORITHM: "ecdsa" OCSP_TLS_SHOULD_SUCCEED: "false" - name: test-docker-runner commands: - func: bootstrap-mongo-orchestration - func: run-docker-test - name: test-goroutine-leaks-replicaset tags: ["goleak"] commands: - func: bootstrap-mongo-orchestration vars: TOPOLOGY: "replica_set" AUTH: "noauth" SSL: "nossl" - func: run-goleak-test - name: test-goroutine-leaks-sharded tags: ["goleak"] commands: - func: bootstrap-mongo-orchestration vars: TOPOLOGY: "sharded_cluster" AUTH: "noauth" SSL: "nossl" - func: run-goleak-test - name: test-load-balancer-noauth-nossl tags: ["load-balancer"] commands: - func: bootstrap-mongo-orchestration vars: TOPOLOGY: "sharded_cluster" AUTH: "noauth" SSL: "nossl" LOAD_BALANCER: "true" - func: run-load-balancer - func: run-load-balancer-tests vars: AUTH: "noauth" SSL: "nossl" - name: test-load-balancer-auth-ssl tags: ["load-balancer"] commands: - func: bootstrap-mongo-orchestration vars: TOPOLOGY: "sharded_cluster" AUTH: "auth" SSL: "ssl" LOAD_BALANCER: "true" - func: run-load-balancer - func: run-load-balancer-tests vars: AUTH: "auth" SSL: "ssl" - name: test-race tags: ["race"] commands: - func: bootstrap-mongo-orchestration vars: TOPOLOGY: "replica_set" AUTH: "noauth" SSL: "nossl" - func: start-cse-servers - func: run-tests vars: TOPOLOGY: "replica_set" AUTH: "noauth" SSL: "nossl" RACE: "-race" - name: test-replicaset-noauth-nossl tags: ["test", "replicaset"] commands: - func: bootstrap-mongo-orchestration vars: TOPOLOGY: "replica_set" AUTH: "noauth" SSL: "nossl" - func: start-cse-servers - func: run-tests vars: TOPOLOGY: "replica_set" AUTH: "noauth" SSL: "nossl" - name: test-replicaset-auth-ssl tags: ["test", "replicaset", "authssl"] commands: - func: bootstrap-mongo-orchestration vars: TOPOLOGY: "replica_set" AUTH: "auth" SSL: "ssl" - func: start-cse-servers - func: run-tests vars: TOPOLOGY: "replica_set" AUTH: "auth" SSL: "ssl" - name: test-replicaset-auth-ssl-mongocryptd tags: ["test", "replicaset", "authssl", "mongocryptd"] commands: - func: bootstrap-mongo-orchestration vars: TOPOLOGY: "replica_set" AUTH: "auth" SSL: "ssl" - func: start-cse-servers - func: run-tests vars: TOPOLOGY: "replica_set" AUTH: "auth" SSL: "ssl" # Don't use the crypt_shared library, which should cause all of the tests to fall # back to using mongocryptd instead of crypt_shared. SKIP_CRYPT_SHARED_LIB: "true" - name: test-replicaset-auth-nossl tags: ["test", "replicaset", "authssl"] commands: - func: bootstrap-mongo-orchestration vars: TOPOLOGY: "replica_set" AUTH: "auth" SSL: "nossl" - func: start-cse-servers - func: run-tests vars: TOPOLOGY: "replica_set" AUTH: "auth" SSL: "nossl" - name: test-sharded-noauth-nossl tags: ["test", "sharded"] commands: - func: bootstrap-mongo-orchestration vars: TOPOLOGY: "sharded_cluster" AUTH: "noauth" SSL: "nossl" - func: start-cse-servers - func: run-tests vars: TOPOLOGY: "sharded_cluster" AUTH: "noauth" SSL: "nossl" - name: test-sharded-noauth-nossl-snappy-compression tags: ["test", "sharded", "compression", "snappy"] commands: - func: bootstrap-mongo-orchestration vars: TOPOLOGY: "sharded_cluster" AUTH: "noauth" SSL: "nossl" - func: start-cse-servers - func: run-tests vars: TOPOLOGY: "sharded_cluster" AUTH: "noauth" SSL: "nossl" MONGO_GO_DRIVER_COMPRESSOR: "snappy" - name: test-sharded-noauth-nossl-zlib-compression tags: ["test", "sharded", "compression", "zlib"] commands: - func: bootstrap-mongo-orchestration vars: TOPOLOGY: "sharded_cluster" AUTH: "noauth" SSL: "nossl" - func: start-cse-servers - func: run-tests vars: TOPOLOGY: "sharded_cluster" AUTH: "noauth" SSL: "nossl" MONGO_GO_DRIVER_COMPRESSOR: "zlib" - name: test-sharded-noauth-nossl-zstd-compression tags: ["test", "sharded", "compression", "zstd"] commands: - func: bootstrap-mongo-orchestration vars: TOPOLOGY: "sharded_cluster" AUTH: "noauth" SSL: "nossl" - func: start-cse-servers - func: run-tests vars: TOPOLOGY: "sharded_cluster" AUTH: "noauth" SSL: "nossl" MONGO_GO_DRIVER_COMPRESSOR: "zstd" - name: test-sharded-auth-ssl tags: ["test", "sharded", "authssl"] commands: - func: bootstrap-mongo-orchestration vars: TOPOLOGY: "sharded_cluster" AUTH: "auth" SSL: "ssl" - func: start-cse-servers - func: run-tests vars: TOPOLOGY: "sharded_cluster" AUTH: "auth" SSL: "ssl" - name: test-sharded-auth-ssl-snappy-compression tags: ["test", "sharded", "authssl", "compression", "snappy"] commands: - func: bootstrap-mongo-orchestration vars: TOPOLOGY: "sharded_cluster" AUTH: "auth" SSL: "ssl" - func: start-cse-servers - func: run-tests vars: TOPOLOGY: "sharded_cluster" AUTH: "auth" SSL: "ssl" MONGO_GO_DRIVER_COMPRESSOR: "snappy" - name: test-sharded-auth-ssl-zlib-compression tags: ["test", "sharded", "authssl", "compression", "zlib"] commands: - func: bootstrap-mongo-orchestration vars: TOPOLOGY: "sharded_cluster" AUTH: "auth" SSL: "ssl" - func: start-cse-servers - func: run-tests vars: TOPOLOGY: "sharded_cluster" AUTH: "auth" SSL: "ssl" MONGO_GO_DRIVER_COMPRESSOR: "zlib" - name: test-sharded-auth-ssl-zstd-compression tags: ["test", "sharded", "authssl", "compression", "zstd"] commands: - func: bootstrap-mongo-orchestration vars: TOPOLOGY: "sharded_cluster" AUTH: "auth" SSL: "ssl" - func: start-cse-servers - func: run-tests vars: TOPOLOGY: "sharded_cluster" AUTH: "auth" SSL: "ssl" MONGO_GO_DRIVER_COMPRESSOR: "zstd" - name: test-sharded-auth-nossl tags: ["test", "sharded", "authssl"] commands: - func: bootstrap-mongo-orchestration vars: TOPOLOGY: "sharded_cluster" AUTH: "auth" SSL: "nossl" - func: start-cse-servers - func: run-tests vars: TOPOLOGY: "sharded_cluster" AUTH: "auth" SSL: "nossl" - name: test-enterprise-auth-plain tags: ["test", "enterprise-auth"] commands: - func: run-enterprise-auth-tests - name: test-enterprise-auth-gssapi tags: ["test", "enterprise-auth"] commands: - func: run-enterprise-gssapi-auth-tests vars: MONGO_GO_DRIVER_COMPRESSOR: "snappy" # Build the compilecheck submodule with all supported versions of Go >= # the minimum supported version. - name: go-build tags: ["compile-check"] commands: - command: subprocess.exec params: binary: bash args: [*task-runner, build-compile-check-all] # Build with the same Go version that we're using for tests. - name: build tags: ["compile-check"] commands: - command: subprocess.exec params: binary: bash # Set the GO_VERSION to empty string to use the Go installation in the # PATH. env: GO_VERSION: "" args: [*task-runner, build] - name: "atlas-test" commands: - func: "run-atlas-test" - name: "aws-auth-test" commands: - func: bootstrap-mongo-orchestration vars: AUTH: "auth" ORCHESTRATION_FILE: "auth-aws.json" TOPOLOGY: "server" - func: add-aws-auth-variables-to-file - func: run-aws-auth-test-with-regular-aws-credentials - func: run-aws-auth-test-with-assume-role-credentials - func: run-aws-auth-test-with-aws-credentials-as-environment-variables - func: run-aws-auth-test-with-aws-credentials-and-session-token-as-environment-variables - func: run-aws-auth-test-with-aws-EC2-credentials - func: run-aws-ECS-auth-test - func: run-aws-auth-test-with-aws-web-identity-credentials - name: "test-standalone-versioned-api" tags: ["versioned-api"] commands: - func: bootstrap-mongo-orchestration vars: TOPOLOGY: "server" AUTH: "auth" SSL: "nossl" REQUIRE_API_VERSION: true - func: start-cse-servers - func: run-versioned-api-test vars: TOPOLOGY: "server" AUTH: "auth" SSL: "nossl" REQUIRE_API_VERSION: true - name: "test-sharded-versioned-api" tags: ["versioned-api"] commands: - func: bootstrap-mongo-orchestration vars: TOPOLOGY: "sharded_cluster" AUTH: "auth" SSL: "nossl" REQUIRE_API_VERSION: true - func: start-cse-servers - func: run-versioned-api-test vars: TOPOLOGY: "sharded_cluster" AUTH: "auth" SSL: "nossl" REQUIRE_API_VERSION: true - name: "test-standalone-versioned-api-test-commands" tags: ["versioned-api"] commands: - func: bootstrap-mongo-orchestration vars: TOPOLOGY: "server" AUTH: "noauth" SSL: "nossl" ORCHESTRATION_FILE: "versioned-api-testing.json" - func: start-cse-servers - func: run-versioned-api-test vars: TOPOLOGY: "server" AUTH: "noauth" SSL: "nossl" - name: "test-kms-kmip" tags: ["kms-kmip"] commands: - func: bootstrap-mongo-orchestration vars: TOPOLOGY: "server" AUTH: "noauth" SSL: "nossl" - func: start-cse-servers - func: run-kmip-tests vars: TOPOLOGY: "server" AUTH: "noauth" SSL: "nossl" - name: "test-client-side-encryption" tags: ["client-side-encryption-test"] commands: - func: bootstrap-mongo-orchestration vars: TOPOLOGY: "replica_set" AUTH: "noauth" SSL: "nossl" - func: start-cse-servers - func: run-client-side-encryption-test vars: TOPOLOGY: "replica_set" AUTH: "noauth" SSL: "nossl" - name: "testgcpkms-task" commands: - command: subprocess.exec type: test params: binary: bash args: [*task-runner, test-gcpkms] - name: "testgcpkms-fail-task" # testgcpkms-fail-task runs in a non-GCE environment. # It is expected to fail to obtain GCE credentials. commands: - command: subprocess.exec type: test params: binary: bash env: EXPECT_ERROR: "1" args: [*task-runner, test-gcpkms] - name: "testawskms-task" commands: - func: assume-test-secrets-ec2-role - command: subprocess.exec type: test params: binary: "bash" add_expansions_to_env: true args: [*task-runner, test-awskms] - name: "testawskms-fail-task" # testawskms-fail-task runs without environment variables. # It is expected to fail to obtain credentials. commands: - func: assume-test-secrets-ec2-role - command: subprocess.exec type: test params: binary: "bash" add_expansions_to_env: true env: EXPECT_ERROR: 'status=400' args: [*task-runner, test-awskms] - name: "testazurekms-task" commands: - command: subprocess.exec type: test params: binary: bash add_expansions_to_env: true args: [*task-runner, test-azurekms] - name: "testazurekms-fail-task" # testazurekms-fail-task runs without environment variables. # It is expected to fail to obtain credentials. commands: - func: assume-test-secrets-ec2-role - command: subprocess.exec type: test params: binary: bash add_expansions_to_env: true env: EXPECT_ERROR: "1" args: [*task-runner, test-azurekms] - name: "test-fuzz" commands: - func: bootstrap-mongo-orchestration - func: run-fuzz-tests - name: "test-aws-lambda-deployed" commands: - command: subprocess.exec type: test params: binary: bash add_expansions_to_env: true env: TEST_LAMBDA_DIRECTORY: ${PROJECT_DIRECTORY}/internal/cmd/faas/awslambda LAMBDA_STACK_NAME: dbx-go-lambda AWS_REGION: us-east-1 args: [*task-runner, evg-test-deployed-lambda-aws] - name: "oidc-auth-test" commands: - func: "run-oidc-auth-test-with-test-credentials" - name: "oidc-auth-test-azure" commands: - command: subprocess.exec type: test params: binary: bash env: OIDC_ENV: azure args: [*task-runner, test-oidc-remote] - name: "oidc-auth-test-gcp" commands: - command: subprocess.exec type: test params: binary: bash env: OIDC_ENV: gcp args: [*task-runner, test-oidc-remote] - name: "oidc-auth-test-k8s" commands: - func: assume-test-secrets-ec2-role - func: "run oidc k8s test" vars: VARIANT: eks - func: "run oidc k8s test" vars: VARIANT: gke - func: "run oidc k8s test" vars: VARIANT: aks - name: "test-search-index" commands: - func: "bootstrap-mongo-orchestration" vars: VERSION: "latest" TOPOLOGY: "replica_set" - func: "run-search-index-tests" axes: - id: version display_name: MongoDB Version values: - id: "8.0" display_name: "8.0" variables: VERSION: "8.0" - id: "7.0" display_name: "7.0" variables: VERSION: "7.0" - id: "6.0" display_name: "6.0" variables: VERSION: "6.0" - id: "5.0" display_name: "5.0" variables: VERSION: "5.0" - id: "4.4" display_name: "4.4" variables: VERSION: "4.4" - id: "4.2" display_name: "4.2" variables: VERSION: "4.2" - id: "rapid" display_name: "rapid" variables: VERSION: "rapid" - id: "latest" display_name: "latest" variables: VERSION: "latest" # OSes that require >= 3.2 for SSL - id: os-ssl-32 display_name: OS values: - id: "windows-64" display_name: "Windows 64-bit" run_on: - windows-2022-latest-small variables: GCC_PATH: "/cygdrive/c/ProgramData/chocolatey/lib/mingw/tools/install/mingw64/bin" GO_DIST: "C:\\golang\\go1.25" VENV_BIN_DIR: "Scripts" DEFAULT_TASK: evg-test # CSOT tests are unreliable on our slow Windows hosts. SKIP_CSOT_TESTS: true - id: "rhel87-64" display_name: "RHEL 8.7" run_on: rhel8.7-large variables: GO_DIST: "/opt/golang/go1.25" DEFAULT_TASK: evg-test - id: "macos" display_name: "MacOS 14.0" run_on: macos-14 batchtime: 1440 # Run at most once per 24 hours. variables: GO_DIST: "/opt/golang/go1.25" DEFAULT_TASK: evg-test-load-balancers # CSOT tests are unreliable on our slow macOS hosts. SKIP_CSOT_TESTS: true # OSes that require >= 4.0 for SSL - id: os-ssl-40 display_name: OS values: - id: "windows-64" display_name: "Windows 64-bit" run_on: - windows-2022-latest-small variables: GCC_PATH: "/cygdrive/c/ProgramData/chocolatey/lib/mingw/tools/install/mingw64/bin" GO_DIST: "C:\\golang\\go1.25" VENV_BIN_DIR: "Scripts" DEFAULT_TASK: evg-test # CSOT tests are unreliable on our slow Windows hosts. SKIP_CSOT_TESTS: true - id: "rhel87-64" display_name: "RHEL 8.7" run_on: rhel8.7-large variables: GO_DIST: "/opt/golang/go1.25" DEFAULT_TASK: evg-test - id: "macos" display_name: "MacOS 14.0" run_on: macos-14 batchtime: 1440 # Run at most once per 24 hours. variables: GO_DIST: "/opt/golang/go1.25" DEFAULT_TASK: evg-test-load-balancers # CSOT tests are unreliable on our slow macOS hosts. SKIP_CSOT_TESTS: true - id: ocsp-rhel-87 display_name: OS values: - id: "rhel87" display_name: "RHEL 8.7" run_on: rhel8.7-large variables: GO_DIST: "/opt/golang/go1.25" DEFAULT_TASK: evg-test - id: os-aws-auth display_name: OS values: - id: "windows-64-2022-latest-small" display_name: "Windows 64-bit" run_on: - windows-2022-latest-small variables: GCC_PATH: "/cygdrive/c/ProgramData/chocolatey/lib/mingw/tools/install/mingw64/bin" GO_DIST: "C:\\golang\\go1.25" SKIP_ECS_AUTH_TEST: true DEFAULT_TASK: evg-test # CSOT tests are unreliable on our slow Windows hosts. SKIP_CSOT_TESTS: true - id: "ubuntu2004-64" display_name: "Ubuntu 20.04" run_on: ubuntu2004-test variables: GO_DIST: "/opt/golang/go1.25" DEFAULT_TASK: evg-test - id: "macos" display_name: "MacOS 14.0" run_on: macos-14 batchtime: 1440 # Run at most once per 24 hours. variables: GO_DIST: "/opt/golang/go1.25" SKIP_ECS_AUTH_TEST: true SKIP_EC2_AUTH_TEST: true SKIP_WEB_IDENTITY_AUTH_TEST: true DEFAULT_TASK: evg-test-load-balancers # CSOT tests are unreliable on our slow macOS hosts. SKIP_CSOT_TESTS: true - id: os-faas-80 display_name: OS values: - id: "rhel87-large" display_name: "RHEL 8.7" run_on: rhel8.7-large variables: GO_DIST: "/opt/golang/go1.25" task_groups: - name: testgcpkms_task_group setup_group_can_fail_task: true setup_group_timeout_secs: 1800 # 30 minutes setup_group: - func: setup-system - func: assume-test-secrets-ec2-role - command: subprocess.exec params: binary: "bash" add_expansions_to_env: true args: - ${DRIVERS_TOOLS}/.evergreen/csfle/gcpkms/setup.sh teardown_group: - command: subprocess.exec params: binary: "bash" args: - ${DRIVERS_TOOLS}/.evergreen/csfle/gcpkms/teardown.sh - func: teardown - func: handle-test-artifacts tasks: - testgcpkms-task - name: testazurekms_task_group setup_group_can_fail_task: true teardown_task_can_fail_task: true setup_group_timeout_secs: 1800 # 30 minutes setup_group: - func: setup-system - func: assume-test-secrets-ec2-role - command: subprocess.exec params: binary: bash add_expansions_to_env: true env: AZUREKMS_VMNAME_PREFIX: GODRIVER args: - ${DRIVERS_TOOLS}/.evergreen/csfle/azurekms/setup.sh teardown_group: - command: subprocess.exec params: binary: "bash" args: - ${DRIVERS_TOOLS}/.evergreen/csfle/azurekms/teardown.sh - func: teardown - func: handle-test-artifacts tasks: - testazurekms-task - name: testoidc_task_group setup_group_can_fail_task: true setup_group_timeout_secs: 1800 # TODO(DRIVERS-3141): Uncomment the following line once the teardown bug is # fixed. See DRIVERS-3141 for more context. # # teardown_task_can_fail_task: true teardown_group_timeout_secs: 180 # 3 minutes (max allowed time) setup_group: - func: setup-system - func: assume-test-secrets-ec2-role - command: subprocess.exec params: binary: bash include_expansions_in_env: ["AWS_ACCESS_KEY_ID", "AWS_SECRET_ACCESS_KEY", "AWS_SESSION_TOKEN"] env: MONGODB_VERSION: "8.0" args: - ${DRIVERS_TOOLS}/.evergreen/auth_oidc/setup.sh teardown_task: - command: subprocess.exec params: binary: bash args: - ${DRIVERS_TOOLS}/.evergreen/auth_oidc/teardown.sh - func: teardown - func: handle-test-artifacts tasks: - oidc-auth-test - name: testazureoidc_task_group setup_group_can_fail_task: true setup_group_timeout_secs: 1800 teardown_task_can_fail_task: true teardown_group_timeout_secs: 180 # 3 minutes (max allowed time) setup_group: - func: setup-system - func: assume-test-secrets-ec2-role - command: subprocess.exec params: binary: bash add_expansions_to_env: true env: AZUREOIDC_VMNAME_PREFIX: "GO_DRIVER" args: - ${DRIVERS_TOOLS}/.evergreen/auth_oidc/azure/setup.sh teardown_task: - command: subprocess.exec params: binary: bash args: - ${DRIVERS_TOOLS}/.evergreen/auth_oidc/azure/teardown.sh - func: teardown - func: handle-test-artifacts tasks: - oidc-auth-test-azure - name: testgcpoidc_task_group setup_group_can_fail_task: true setup_group_timeout_secs: 1800 teardown_task_can_fail_task: true teardown_group_timeout_secs: 180 # 3 minutes (max allowed time) setup_group: - func: setup-system - func: assume-test-secrets-ec2-role - command: subprocess.exec params: binary: bash add_expansions_to_env: true env: AZUREOIDC_VMNAME_PREFIX: "GO_DRIVER" args: - ${DRIVERS_TOOLS}/.evergreen/auth_oidc/gcp/setup.sh teardown_task: - command: subprocess.exec params: binary: bash args: - ${DRIVERS_TOOLS}/.evergreen/auth_oidc/gcp/teardown.sh - func: teardown - func: handle-test-artifacts tasks: - oidc-auth-test-gcp - name: testk8soidc_task_group setup_group_can_fail_task: true setup_group_timeout_secs: 1800 teardown_task_can_fail_task: true teardown_group_timeout_secs: 180 # 3 minutes (max allowed time) setup_group: - func: setup-system - func: assume-test-secrets-ec2-role - command: subprocess.exec params: binary: bash include_expansions_in_env: ["AWS_ACCESS_KEY_ID", "AWS_SECRET_ACCESS_KEY", "AWS_SESSION_TOKEN"] args: - ${DRIVERS_TOOLS}/.evergreen/auth_oidc/k8s/setup.sh teardown_group: - command: subprocess.exec params: binary: bash args: - ${DRIVERS_TOOLS}/.evergreen/auth_oidc/k8s/teardown.sh - func: teardown - func: handle-test-artifacts tasks: - oidc-auth-test-k8s - name: test-aws-lambda-task-group setup_group: - func: setup-system - func: assume-test-secrets-ec2-role - command: subprocess.exec params: working_dir: src/go.mongodb.org/mongo-driver binary: bash include_expansions_in_env: [AWS_ACCESS_KEY_ID, AWS_SECRET_ACCESS_KEY, AWS_SESSION_TOKEN] env: MONGODB_VERSION: ${VERSION} LAMBDA_STACK_NAME: dbx-go-lambda args: - ${DRIVERS_TOOLS}/.evergreen/atlas/setup.sh teardown_group: - command: subprocess.exec params: working_dir: src/go.mongodb.org/mongo-driver binary: bash add_expansions_to_env: true env: LAMBDA_STACK_NAME: dbx-go-lambda AWS_REGION: us-east-1 args: - ${DRIVERS_TOOLS}/.evergreen/atlas/teardown.sh - func: teardown - func: handle-test-artifacts setup_group_can_fail_task: true setup_group_timeout_secs: 1800 tasks: - test-aws-lambda-deployed - name: test-search-index-task-group setup_group: - func: setup-system - func: assume-test-secrets-ec2-role - command: subprocess.exec params: working_dir: src/go.mongodb.org/mongo-driver binary: bash include_expansions_in_env: [AWS_ACCESS_KEY_ID, AWS_SECRET_ACCESS_KEY, AWS_SESSION_TOKEN, MONGODB_URI] env: MONGODB_VERSION: ${VERSION} LAMBDA_STACK_NAME: dbx-go-lambda args: - ${DRIVERS_TOOLS}/.evergreen/atlas/setup.sh - command: expansions.update params: file: src/go.mongodb.org/mongo-driver/atlas-expansion.yml - command: shell.exec params: working_dir: src/go.mongodb.org/mongo-driver shell: bash script: |- echo "SEARCH_INDEX_URI: ${MONGODB_URI}" > atlas-expansion.yml - command: expansions.update params: file: src/go.mongodb.org/mongo-driver/atlas-expansion.yml teardown_group: - command: subprocess.exec params: working_dir: src/go.mongodb.org/mongo-driver binary: bash args: - ${DRIVERS_TOOLS}/.evergreen/atlas/teardown.sh - func: teardown - func: handle-test-artifacts setup_group_can_fail_task: true setup_group_timeout_secs: 1800 tasks: - test-search-index buildvariants: - name: static-analysis tags: ["pullrequest"] display_name: "Static Analysis" run_on: - rhel8.7-small expansions: # Keep this in sync with go version used in etc/golangci-lint.sh GO_DIST: "/opt/golang/go1.25" tasks: - name: ".static-analysis" - name: pull-request-helpers tags: ["pullrequest"] display_name: "Pull Request Helpers" run_on: - rhel8.7-small expansions: GO_DIST: "/opt/golang/go1.25" tasks: - name: "pull-request-helpers" - name: perf tags: ["pullrequest"] display_name: "Performance" run_on: rhel90-dbx-perf-large expansions: GO_DIST: "/opt/golang/go1.25" tasks: - name: ".performance" - name: build-check tags: ["pullrequest"] display_name: "Compile Only Checks" run_on: - ubuntu2204-small expansions: GO_DIST: "/opt/golang/go1.25" tasks: - name: ".compile-check" - name: backport-pr display_name: "Backport PR" run_on: - rhel8.7-small expansions: GO_DIST: "/opt/golang/go1.25" tasks: - name: "backport-pr" - name: atlas-test tags: ["pullrequest"] display_name: "Atlas test" run_on: - rhel8.7-large expansions: GO_DIST: "/opt/golang/go1.25" tasks: - name: "atlas-test" - name: docker-runner-test tags: ["pullrequest"] display_name: "Docker Runner Test" run_on: - ubuntu2204-large expansions: GO_DIST: "/opt/golang/go1.25" tasks: - name: "test-docker-runner" - name: goroutine-leaks-test tags: ["pullrequest"] display_name: "Goroutine Leaks Test" run_on: - ubuntu2204-large expansions: GO_DIST: "/opt/golang/go1.25" tasks: - name: ".goleak" - matrix_name: "tests-rhel-44-plus-zlib-zstd-support" tags: ["pullrequest"] matrix_spec: {version: ["4.2", "4.4", "5.0", "6.0", "7.0", "8.0"], os-ssl-40: ["rhel87-64"]} display_name: "${version} ${os-ssl-40}" tasks: - name: ".test !.enterprise-auth !.snappy" - matrix_name: "tests-windows-42-plus-zlib-zstd-support" matrix_spec: {version: ["4.2", "4.4", "5.0", "6.0", "7.0"], os-ssl-40: ["windows-64"]} display_name: "${version} ${os-ssl-40}" tasks: - name: ".test !.enterprise-auth !.snappy" - matrix_name: "tests-windows-80-zlib-zstd-support" tags: ["pullrequest"] matrix_spec: {version: ["8.0"], os-ssl-40: ["windows-64"]} display_name: "${version} ${os-ssl-40}" tasks: - name: ".test !.enterprise-auth !.snappy" - matrix_name: "tests-latest-zlib-zstd-support" matrix_spec: {version: ["latest"], os-ssl-40: ["windows-64", "rhel87-64"]} display_name: "${version} ${os-ssl-40}" tasks: - name: ".test !.enterprise-auth !.snappy" - matrix_name: "enterprise-auth-tests" matrix_spec: {os-ssl-32: "*"} display_name: "Enterprise Auth - ${os-ssl-32}" tasks: - name: ".test .enterprise-auth" - matrix_name: "aws-auth-test" matrix_spec: {version: ["4.4", "5.0", "6.0", "7.0", "8.0", "latest"], os-aws-auth: "*"} display_name: "MONGODB-AWS Auth ${version} ${os-aws-auth}" tasks: - name: "aws-auth-test" - matrix_name: "ocsp-test" matrix_spec: {version: ["4.4", "5.0", "6.0", "7.0", "8.0", "latest"], ocsp-rhel-87: ["rhel87"]} display_name: "OCSP ${version} ${ocsp-rhel-87}" batchtime: 20160 # Use a batchtime of 14 days as suggested by the OCSP test README tasks: - name: ".ocsp" - matrix_name: "ocsp-test-windows" matrix_spec: {version: ["4.4", "5.0", "6.0", "7.0", "8.0", "latest"], os-ssl-40: ["windows-64"]} display_name: "OCSP ${version} ${os-ssl-40}" batchtime: 20160 # Use a batchtime of 14 days as suggested by the OCSP test README tasks: # Windows MongoDB servers do not staple OCSP responses and only support RSA. - name: ".ocsp-rsa !.ocsp-staple" - matrix_name: "ocsp-test-macos" matrix_spec: {version: ["4.4", "5.0", "6.0", "7.0", "8.0", "latest"], os-ssl-40: ["macos"]} display_name: "OCSP ${version} ${os-ssl-40}" batchtime: 20160 # Use a batchtime of 14 days as suggested by the OCSP test README tasks: # macos MongoDB servers do not staple OCSP responses and only support RSA. - name: ".ocsp-rsa !.ocsp-staple" - matrix_name: "race-test" tags: ["pullrequest"] matrix_spec: {version: ["7.0"], os-ssl-40: ["rhel87-64"]} display_name: "Race Detector Test" tasks: - name: ".race" - matrix_name: "versioned-api-test" tags: ["pullrequest"] matrix_spec: {version: ["5.0", "6.0", "7.0", "8.0"], os-ssl-40: ["windows-64", "rhel87-64"]} display_name: "API Version ${version} ${os-ssl-40}" tasks: - name: ".versioned-api" - matrix_name: "versioned-api-latest-test" matrix_spec: {version: ["latest"], os-ssl-40: ["windows-64", "rhel87-64"]} display_name: "API Version ${version} ${os-ssl-40}" tasks: - name: ".versioned-api" - matrix_name: "client-side-encryption-test" matrix_spec: {version: ["latest"], os-ssl-40: ["rhel87-64"]} display_name: "Client Side Encryption Tests ${os-ssl-40}" tasks: - name: ".client-side-encryption-test" - matrix_name: "load-balancer-test" tags: ["pullrequest"] matrix_spec: {version: ["5.0", "6.0", "7.0", "8.0"], os-ssl-40: ["rhel87-64"]} display_name: "Load Balancer Support ${version} ${os-ssl-40}" tasks: - name: ".load-balancer" - matrix_name: "load-balancer-latest-test" matrix_spec: {version: ["latest"], os-ssl-40: ["rhel87-64"]} display_name: "Load Balancer Support ${version} ${os-ssl-40}" tasks: - name: ".load-balancer" - matrix_name: "kms-kmip-test" matrix_spec: {version: ["7.0"], os-ssl-40: ["rhel87-64"]} display_name: "KMS KMIP ${os-ssl-40}" tasks: - name: ".kms-kmip" - matrix_name: "fuzz-test" matrix_spec: {version: ["5.0"], os-ssl-40: ["rhel87-64"]} display_name: "Fuzz ${version} ${os-ssl-40}" tasks: - name: "test-fuzz" batchtime: 1440 # Run at most once per 24 hours. - matrix_name: "faas-test" matrix_spec: {version: ["7.0"], os-faas-80: ["rhel87-large"]} display_name: "FaaS ${version} ${os-faas-80}" tasks: - test-aws-lambda-task-group - matrix_name: "searchindex-test" matrix_spec: {version: ["7.0"], os-faas-80: ["rhel87-large"]} display_name: "Search Index ${version} ${os-faas-80}" tasks: - test-search-index-task-group - name: testgcpkms-variant display_name: "GCP KMS" run_on: - rhel8.7-small expansions: GO_DIST: "/opt/golang/go1.25" tasks: - name: testgcpkms_task_group batchtime: 20160 # Use a batchtime of 14 days as suggested by the CSFLE test README - testgcpkms-fail-task - name: testawskms-variant display_name: "AWS KMS" run_on: - rhel8.7-small expansions: GO_DIST: "/opt/golang/go1.25" tasks: - testawskms-task - testawskms-fail-task - name: testazurekms-variant display_name: "AZURE KMS" run_on: - rhel8.7-small expansions: GO_DIST: "/opt/golang/go1.25" tasks: - name: testazurekms_task_group batchtime: 20160 # Use a batchtime of 14 days as suggested by the CSFLE test README - testazurekms-fail-task - name: testoidc-variant display_name: "OIDC" run_on: - ubuntu2204-small expansions: GO_DIST: "/opt/golang/go1.25" tasks: - name: testoidc_task_group - name: testazureoidc_task_group - name: testgcpoidc_task_group - name: testk8soidc_task_group