@@ -520,6 +520,18 @@ functions:
520520 args :
521521 - .evergreen/run-mongodb-oidc-test.sh
522522
523+ " run oidc k8s auth test " :
524+ - command : subprocess.exec
525+ type : test
526+ params :
527+ binary : bash
528+ working_dir : src
529+ env :
530+ OIDC_ENV : k8s
531+ include_expansions_in_env : ["DRIVERS_TOOLS", "AWS_ACCESS_KEY_ID", "AWS_SECRET_ACCESS_KEY", "AWS_SESSION_TOKEN", "K8S_VARIANT"]
532+ args :
533+ - ${PROJECT_DIRECTORY}/.evergreen/run-mongodb-oidc-remote-test.sh
534+
523535 " run aws auth test with aws credentials as environment variables " :
524536 - command : shell.exec
525537 type : test
@@ -873,6 +885,32 @@ task_groups:
873885 tasks :
874886 - oidc-auth-test-gcp
875887
888+ - name : testk8soidc_task_group
889+ setup_group :
890+ - func : fetch source
891+ - func : prepare resources
892+ - func : fix absolute paths
893+ - func : make files executable
894+ - command : ec2.assume_role
895+ params :
896+ role_arn : ${aws_test_secrets_role}
897+ duration_seconds : 1800
898+ - command : subprocess.exec
899+ params :
900+ binary : bash
901+ args :
902+ - ${DRIVERS_TOOLS}/.evergreen/auth_oidc/k8s/setup.sh
903+ teardown_task :
904+ - command : subprocess.exec
905+ params :
906+ binary : bash
907+ args :
908+ - ${DRIVERS_TOOLS}/.evergreen/auth_oidc/k8s/teardown.sh
909+ setup_group_can_fail_task : true
910+ setup_group_timeout_secs : 1800
911+ tasks :
912+ - oidc-auth-test-k8s
913+
876914 - name : testoidc_task_group
877915 setup_group :
878916 - func : fetch source
@@ -1548,40 +1586,41 @@ tasks:
15481586
15491587 - name : " oidc-auth-test-azure"
15501588 commands :
1551- - command : shell .exec
1589+ - command : subprocess .exec
15521590 type : test
15531591 params :
1554- shell : bash
1555- script : |-
1556- set -o errexit
1557- . src/.evergreen/scripts/env.sh
1558- cd src
1559- git add .
1560- git commit -m "add files"
1561- export AZUREOIDC_DRIVERS_TAR_FILE=/tmp/mongo-python-driver.tgz
1562- git archive -o $AZUREOIDC_DRIVERS_TAR_FILE HEAD
1563- export AZUREOIDC_TEST_CMD="OIDC_ENV=azure ./.evergreen/run-mongodb-oidc-test.sh"
1564- bash $DRIVERS_TOOLS/.evergreen/auth_oidc/azure/run-driver-test.sh
1592+ binary : bash
1593+ working_dir : src
1594+ env :
1595+ OIDC_ENV : azure
1596+ include_expansions_in_env : ["DRIVERS_TOOLS"]
1597+ args :
1598+ - ${PROJECT_DIRECTORY}/.evergreen/run-mongodb-oidc-remote-test.sh
15651599
15661600 - name : " oidc-auth-test-gcp"
15671601 commands :
1568- - command : shell .exec
1602+ - command : subprocess .exec
15691603 type : test
15701604 params :
1571- shell : bash
1572- script : |-
1573- set -o errexit
1574- . src/.evergreen/scripts/env.sh
1575- cd src
1576- git add .
1577- git commit -m "add files"
1578- export GCPOIDC_DRIVERS_TAR_FILE=/tmp/mongo-python-driver.tgz
1579- git archive -o $GCPOIDC_DRIVERS_TAR_FILE HEAD
1580- # Define the command to run on the VM.
1581- # Ensure that we source the environment file created for us, set up any other variables we need,
1582- # and then run our test suite on the vm.
1583- export GCPOIDC_TEST_CMD="OIDC_ENV=gcp ./.evergreen/run-mongodb-oidc-test.sh"
1584- bash $DRIVERS_TOOLS/.evergreen/auth_oidc/gcp/run-driver-test.sh
1605+ binary : bash
1606+ working_dir : src
1607+ env :
1608+ OIDC_ENV : gcp
1609+ include_expansions_in_env : ["DRIVERS_TOOLS"]
1610+ args :
1611+ - ${PROJECT_DIRECTORY}/.evergreen/run-mongodb-oidc-remote-test.sh
1612+
1613+ - name : " oidc-auth-test-k8s"
1614+ commands :
1615+ - func : " run oidc k8s auth test"
1616+ vars :
1617+ K8S_VARIANT : eks
1618+ - func : " run oidc k8s auth test"
1619+ vars :
1620+ K8S_VARIANT : gke
1621+ - func : " run oidc k8s auth test"
1622+ vars :
1623+ K8S_VARIANT : aks
15851624# }}}
15861625 - name : " coverage-report"
15871626 tags : ["coverage"]
@@ -1740,20 +1779,6 @@ buildvariants:
17401779 tasks :
17411780 - name : " coverage-report"
17421781
1743- - name : testazureoidc-variant
1744- display_name : " OIDC Auth Azure"
1745- run_on : ubuntu2204-small
1746- tasks :
1747- - name : testazureoidc_task_group
1748- batchtime : 20160 # Use a batchtime of 14 days as suggested by the CSFLE test README
1749-
1750- - name : testgcpoidc-variant
1751- display_name : " OIDC Auth GCP"
1752- run_on : ubuntu2204-small
1753- tasks :
1754- - name : testgcpoidc_task_group
1755- batchtime : 20160 # Use a batchtime of 14 days as suggested by the CSFLE test README
1756-
17571782- name : testgcpkms-variant
17581783 display_name : " GCP KMS"
17591784 run_on :
0 commit comments