File tree 2 files changed +14
-3
lines changed
2 files changed +14
-3
lines changed Original file line number Diff line number Diff line change @@ -3965,6 +3965,7 @@ functions:
3965
3965
PACKAGE_VARIANT : ${package_variant}
3966
3966
MACOS_NOTARY_KEY : ${macos_notary_key}
3967
3967
MACOS_NOTARY_SECRET : ${macos_notary_secret}
3968
+ REQUESTER : ${requester}
3968
3969
verify_artifact :
3969
3970
- command : expansions.write
3970
3971
type : setup
Original file line number Diff line number Diff line change @@ -6,6 +6,11 @@ export NODE_JS_VERSION=${NODE_JS_VERSION}
6
6
export ARTIFACT_URL_FILE=" $PWD /../artifact-url.txt"
7
7
8
8
source .evergreen/setup-env.sh
9
+ notarymode=" notarizeAndSign"
10
+
11
+ if [ " $REQUESTER " == " github_pr" ]; then
12
+ notarymode=" sign"
13
+ fi
9
14
10
15
(mkdir -p dist/ && cd dist/ && bash " $BASEDIR /retry-with-backoff.sh" curl -sSfLO --url " $( cat " $ARTIFACT_URL_FILE " ) " )
11
16
ls -lh dist/
@@ -24,15 +29,20 @@ if [ "$(uname)" == Darwin ]; then
24
29
# notarize the client
25
30
./darwin_amd64/macnotary \
26
31
-f " $FILE " \
27
- -m notarizeAndSign -u https://dev.macos-notary.build.10gen.cc/api \
32
+ -m $notarymode -u https://dev.macos-notary.build.10gen.cc/api \
28
33
-b com.mongodb.mongosh \
29
34
-e config/macos-entitlements.xml \
30
35
-o " $FILE -signed.zip"
31
36
mv -v " $FILE -signed.zip" " $FILE "
32
37
33
- # Verify signing
38
+ # Verify signing and notarization
34
39
unzip " $FILE "
35
- spctl -a -vvv -t install mongosh-* /bin/mongosh
40
+ if [ " $notarymode " == " sign" ]; then
41
+ codesign --verify --deep --strict --verbose=2 mongosh-* /bin/mongosh
42
+ else
43
+ spctl -a -vvv -t install mongosh-* /bin/mongosh
44
+ fi
45
+
36
46
else
37
47
npm run evergreen-release sign
38
48
fi
You can’t perform that action at this time.
0 commit comments