Skip to content

Commit 1a2a600

Browse files
authored
Revert "DRIVERS-3030 Ensure mongosh download is properly working" (#541)
1 parent bde0dcb commit 1a2a600

File tree

3 files changed

+43
-75
lines changed

3 files changed

+43
-75
lines changed

.evergreen/config.yml

Lines changed: 41 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -512,18 +512,52 @@ functions:
512512
make test
513513
514514
"run mongodl test partial":
515-
- command: subprocess.exec
515+
- command: shell.exec
516516
type: test
517517
params:
518-
binary: bash
519-
args: [src/.evergreen/tests/test-mongodl.sh, partial]
518+
shell: bash
519+
script: |-
520+
set -o errexit
521+
cd ${DRIVERS_TOOLS}/.evergreen
522+
. find-python3.sh
523+
PYTHON=$(ensure_python3)
524+
echo "Using PYTHON: $PYTHON"
525+
$PYTHON mongodl.py --edition enterprise --version 7.0 --component archive-debug --no-download
526+
$PYTHON mongodl.py --edition enterprise --version 7.0 --component cryptd --test
527+
$PYTHON mongosh-dl.py --no-download
528+
$PYTHON mongosh-dl.py --version 2.1.1 --no-download
529+
$PYTHON mongosh-dl.py --version 2.1.1 --out $(pwd)
520530
521531
"run mongodl test full":
522-
- command: subprocess.exec
532+
- command: shell.exec
523533
type: test
524534
params:
525-
binary: bash
526-
args: [src/.evergreen/tests/test-mongodl.sh]
535+
shell: bash
536+
script: |-
537+
set -o errexit
538+
cd ${DRIVERS_TOOLS}/.evergreen
539+
. find-python3.sh
540+
PYTHON=$(ensure_python3 2>/dev/null)
541+
echo "Using PYTHON: $PYTHON"
542+
# Ensure that all distros are accounted for in DISTRO_ID_TO_TARGET
543+
export VALIDATE_DISTROS=1
544+
$PYTHON mongodl.py --list
545+
if [ "$OS" != "Windows_NT" ]; then
546+
$PYTHON mongodl.py --edition enterprise --version 7.0.1 --component archive-debug --test
547+
fi
548+
$PYTHON mongodl.py --edition enterprise --version 3.6 --component archive --test
549+
$PYTHON mongodl.py --edition enterprise --version 4.0 --component archive --test
550+
$PYTHON mongodl.py --edition enterprise --version 4.2 --component archive --test
551+
$PYTHON mongodl.py --edition enterprise --version 4.4 --component archive --test
552+
$PYTHON mongodl.py --edition enterprise --version 5.0 --component archive --test
553+
$PYTHON mongodl.py --edition enterprise --version 6.0 --component crypt_shared --test
554+
$PYTHON mongodl.py --edition enterprise --version 8.0 --component archive --test
555+
$PYTHON mongodl.py --edition enterprise --version rapid --component archive --test
556+
$PYTHON mongodl.py --edition enterprise --version latest --component archive --out $(pwd)
557+
$PYTHON mongodl.py --edition enterprise --version v6.0-perf --component cryptd --test
558+
$PYTHON mongodl.py --edition enterprise --version v8.0-perf --component cryptd --test
559+
$PYTHON mongosh-dl.py --no-download
560+
$PYTHON mongosh-dl.py --version 2.1.1 --out $(pwd)
527561
528562
"teardown assets":
529563
- command: subprocess.exec
@@ -1252,7 +1286,7 @@ axes:
12521286

12531287
- id: amazon-2023-x64
12541288
display_name: "Amazon Linux 2023 x64"
1255-
run_on: amazon2023.3-small
1289+
run_on: amazon2023.0-small
12561290

12571291
- id: macos-14-arm64
12581292
display_name: "macOS 14 arm64"

.evergreen/mongosh-dl.py

Lines changed: 2 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -65,21 +65,14 @@ def _download(out_dir: Path, version: str, target: str,
6565
elif arch == "aarch64":
6666
arch = "arm64"
6767
if target == "linux":
68-
suffix = '.tgz'
69-
if sys.platform == 'linux' and arch in ["x64", "arm64"]:
70-
openssl = subprocess.check_output(["openssl", "version"])
71-
if "3.0" in openssl.decode('utf-8'):
72-
suffix = "-openssl3.tgz"
73-
elif "1.1" in openssl.decode('utf-8'):
74-
suffix = "-openssl11.tgz"
68+
suffix = ".tgz"
7569
else:
7670
suffix = ".zip"
7771
dl_url = f"https://downloads.mongodb.com/compass/mongosh-{version}-{target}-{arch}{suffix}"
78-
print(dl_url)
7972

8073
if no_download:
74+
print(dl_url)
8175
return ExpandResult.Okay
82-
8376
req = urllib.request.Request(dl_url)
8477
resp = urllib.request.urlopen(req)
8578

.evergreen/tests/test-mongodl.sh

Lines changed: 0 additions & 59 deletions
This file was deleted.

0 commit comments

Comments
 (0)