File tree Expand file tree Collapse file tree 6 files changed +28
-15
lines changed Expand file tree Collapse file tree 6 files changed +28
-15
lines changed Original file line number Diff line number Diff line change @@ -2126,7 +2126,8 @@ tasks:
2126
2126
script : |
2127
2127
${PREPARE_SHELL}
2128
2128
export PYTHON_BINARY=/opt/mongodbtoolchain/v4/bin/python3
2129
- export LIBMONGOCRYPT_URL=https://s3.amazonaws.com/${bucket_name}/libmongocrypt/debian10/master/latest/libmongocrypt.tar.gz
2129
+ export LIBMONGOCRYPT_URL=https://s3.amazonaws.com/mciuploads/libmongocrypt/debian11/master/latest/libmongocrypt.tar.gz
2130
+ SKIP_SERVERS=1 bash ./.evergreen/setup-encryption.sh
2130
2131
SUCCESS=false TEST_FLE_GCP_AUTO=1 ./.evergreen/hatch.sh test:test-eg
2131
2132
2132
2133
- name : testazurekms-task
@@ -3144,7 +3145,7 @@ buildvariants:
3144
3145
- name : testgcpkms-variant
3145
3146
display_name : " GCP KMS"
3146
3147
run_on :
3147
- - debian10 -small
3148
+ - debian11 -small
3148
3149
tasks :
3149
3150
- name : testgcpkms_task_group
3150
3151
batchtime : 20160 # Use a batchtime of 14 days as suggested by the CSFLE test README
Original file line number Diff line number Diff line change 1
1
#! /bin/bash
2
2
set -o errexit # Exit the script with error if any of the commands fail
3
-
3
+ HERE= $( dirname ${BASH_SOURCE :- $0 } )
4
4
. $DRIVERS_TOOLS /.evergreen/csfle/azurekms/setup-secrets.sh
5
+ export LIBMONGOCRYPT_URL=https://s3.amazonaws.com/mciuploads/libmongocrypt/debian11/master/latest/libmongocrypt.tar.gz
6
+ SKIP_SERVERS=1 bash $HERE /setup-encryption.sh
5
7
PYTHON_BINARY=/opt/mongodbtoolchain/v4/bin/python3 \
6
8
KEY_NAME=" ${AZUREKMS_KEYNAME} " \
7
9
KEY_VAULT_ENDPOINT=" ${AZUREKMS_KEYVAULTENDPOINT} " \
8
- LIBMONGOCRYPT_URL=https://s3.amazonaws.com/mciuploads/libmongocrypt/debian10/master/latest/libmongocrypt.tar.gz \
9
10
SUCCESS=false TEST_FLE_AZURE_AUTO=1 \
10
- ./.evergreen/hatch.sh test:test-eg
11
+ $HERE /hatch.sh test:test-eg
12
+ bash $HERE /teardown-encryption.sh
Original file line number Diff line number Diff line change 1
1
#! /bin/bash
2
2
set -o errexit # Exit the script with error if any of the commands fail
3
-
3
+ HERE= $( dirname ${BASH_SOURCE :- $0 } )
4
4
source ${DRIVERS_TOOLS} /.evergreen/csfle/azurekms/secrets-export.sh
5
5
echo " Copying files ... begin"
6
6
export AZUREKMS_RESOURCEGROUP=${AZUREKMS_RESOURCEGROUP}
7
7
export AZUREKMS_VMNAME=${AZUREKMS_VMNAME}
8
8
export AZUREKMS_PRIVATEKEYPATH=/tmp/testazurekms_privatekey
9
+ export LIBMONGOCRYPT_URL=https://s3.amazonaws.com/mciuploads/libmongocrypt/debian11/master/latest/libmongocrypt.tar.gz
10
+ SKIP_SERVERS=1 bash $HERE /setup-encryption.sh
9
11
tar czf /tmp/mongo-python-driver.tgz .
10
12
# shellcheck disable=SC2088
11
13
AZUREKMS_SRC=" /tmp/mongo-python-driver.tgz" AZUREKMS_DST=" ~/" \
@@ -16,6 +18,7 @@ AZUREKMS_CMD="tar xf mongo-python-driver.tgz" \
16
18
$DRIVERS_TOOLS /.evergreen/csfle/azurekms/run-command.sh
17
19
echo " Untarring file ... end"
18
20
echo " Running test ... begin"
19
- AZUREKMS_CMD=" KEY_NAME=\" $AZUREKMS_KEYNAME \" KEY_VAULT_ENDPOINT=\" $AZUREKMS_KEYVAULTENDPOINT \" LIBMONGOCRYPT_URL=https://s3.amazonaws.com/mciuploads/libmongocrypt/debian10/master/latest/libmongocrypt.tar.gz SUCCESS=true TEST_FLE_AZURE_AUTO=1 ./.evergreen/hatch.sh test:test-eg" \
21
+ AZUREKMS_CMD=" KEY_NAME=\" $AZUREKMS_KEYNAME \" KEY_VAULT_ENDPOINT=\" $AZUREKMS_KEYVAULTENDPOINT \" SUCCESS=true TEST_FLE_AZURE_AUTO=1 ./.evergreen/hatch.sh test:test-eg" \
20
22
$DRIVERS_TOOLS /.evergreen/csfle/azurekms/run-command.sh
21
23
echo " Running test ... end"
24
+ bash $HERE /teardown-encryption.sh
Original file line number Diff line number Diff line change 1
1
#! /bin/bash
2
2
set -o errexit # Exit the script with error if any of the commands fail
3
+ HERE=$( dirname ${BASH_SOURCE:- $0 } )
3
4
4
5
source ${DRIVERS_TOOLS} /.evergreen/csfle/gcpkms/secrets-export.sh
5
6
echo " Copying files ... begin"
6
7
export GCPKMS_GCLOUD=${GCPKMS_GCLOUD}
7
8
export GCPKMS_PROJECT=${GCPKMS_PROJECT}
8
9
export GCPKMS_ZONE=${GCPKMS_ZONE}
9
10
export GCPKMS_INSTANCENAME=${GCPKMS_INSTANCENAME}
11
+ export LIBMONGOCRYPT_URL=https://s3.amazonaws.com/mciuploads/libmongocrypt/debian11/master/latest/libmongocrypt.tar.gz
12
+ SKIP_SERVERS=1 bash $HERE /setup-encryption.sh
10
13
tar czf /tmp/mongo-python-driver.tgz .
11
14
GCPKMS_SRC=/tmp/mongo-python-driver.tgz GCPKMS_DST=$GCPKMS_INSTANCENAME : $DRIVERS_TOOLS /.evergreen/csfle/gcpkms/copy-file.sh
12
15
echo " Copying files ... end"
13
16
echo " Untarring file ... begin"
14
17
GCPKMS_CMD=" tar xf mongo-python-driver.tgz" $DRIVERS_TOOLS /.evergreen/csfle/gcpkms/run-command.sh
15
18
echo " Untarring file ... end"
16
19
echo " Running test ... begin"
17
- GCPKMS_CMD=" SUCCESS=true TEST_FLE_GCP_AUTO=1 LIBMONGOCRYPT_URL=https://s3.amazonaws.com/mciuploads/libmongocrypt/debian10/master/latest/libmongocrypt.tar.gz ./.evergreen/hatch.sh test:test-eg" $DRIVERS_TOOLS /.evergreen/csfle/gcpkms/run-command.sh
20
+ GCPKMS_CMD=" SUCCESS=true TEST_FLE_GCP_AUTO=1 ./.evergreen/hatch.sh test:test-eg" $DRIVERS_TOOLS /.evergreen/csfle/gcpkms/run-command.sh
18
21
echo " Running test ... end"
22
+ bash $HERE /teardown-encryption.sh
Original file line number Diff line number Diff line change @@ -121,14 +121,14 @@ if [ -n "$TEST_PYOPENSSL" ]; then
121
121
fi
122
122
123
123
if [ -n " $TEST_ENCRYPTION " ] || [ -n " $TEST_FLE_AZURE_AUTO " ] || [ -n " $TEST_FLE_GCP_AUTO " ]; then
124
-
125
- python -m pip install ' .[encryption]'
126
-
127
- # Setup encryption if necessary.
124
+ # Check for libmongocrypt checkout.
128
125
if [ ! -d " libmongocrypt" ]; then
129
- bash ./.evergreen/setup-encryption.sh
126
+ echo " Run encryption setup first!"
127
+ exit 1
130
128
fi
131
129
130
+ python -m pip install ' .[encryption]'
131
+
132
132
# Use the nocrypto build to avoid dependency issues with older windows/python versions.
133
133
BASE=$( pwd) /libmongocrypt/nocrypto
134
134
if [ -f " ${BASE} /lib/libmongocrypt.so" ]; then
Original file line number Diff line number Diff line change @@ -4,6 +4,7 @@ set -o xtrace
4
4
5
5
if [ -z " ${DRIVERS_TOOLS} " ]; then
6
6
echo " Missing environment variable DRIVERS_TOOLS"
7
+ exit 1
7
8
fi
8
9
9
10
TARGET=" "
@@ -50,5 +51,7 @@ tar xzf libmongocrypt.tar.gz -C ./libmongocrypt
50
51
ls -la libmongocrypt
51
52
ls -la libmongocrypt/nocrypto
52
53
53
- bash ${DRIVERS_TOOLS} /.evergreen/csfle/setup-secrets.sh
54
- bash ${DRIVERS_TOOLS} /.evergreen/csfle/start-servers.sh
54
+ if [ -z " ${SKIP_SERVERS:- } " ]; then
55
+ bash ${DRIVERS_TOOLS} /.evergreen/csfle/setup-secrets.sh
56
+ bash ${DRIVERS_TOOLS} /.evergreen/csfle/start-servers.sh
57
+ fi
You can’t perform that action at this time.
0 commit comments