Skip to content

Commit 2d6fbbf

Browse files
Merge branch 'master' into SA_refactor_feature_branch
2 parents 410ceab + a188f33 commit 2d6fbbf

File tree

2,300 files changed

+13703
-14611
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

2,300 files changed

+13703
-14611
lines changed

.github/workflows/code-health.yml

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -391,8 +391,15 @@ jobs:
391391
with:
392392
go-version-file: 'go.mod'
393393
- run: go install gotest.tools/gotestsum@latest
394+
- name: set Apix Bot token
395+
id: app-token
396+
uses: mongodb/apix-action/token@3024080388613583e3bd119bfb1ab4b4dbf43c42
397+
with:
398+
app-id: ${{ secrets.APIXBOT_APP_ID }}
399+
private-key: ${{ secrets.APIXBOT_APP_PEM }}
394400
- run: make e2e-test-snapshots
395401
env:
402+
GH_TOKEN: ${{ steps.app-token.outputs.token }}
396403
TEST_CMD: gotestsum --junitfile e2e-tests.xml --format standard-verbose --
397404
- name: Test Summary
398405
if: always()

.github/workflows/labeler.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -56,7 +56,7 @@ jobs:
5656
with:
5757
header: pr-title-slack-doc
5858
message: "APIx Bot :bowtie:: a message has been sent to Docs Slack channel :rocket:."
59-
- uses: slackapi/slack-github-action@b0fa283ad8fea605de13dc3f449259339835fc52
59+
- uses: slackapi/slack-github-action@91efab103c0de0a537f72a35f6b8cda0ee76bf0a
6060
if: env.review_needed == 'true' && steps.append_comment.outputs.previous_comment_id == ''
6161
with:
6262
webhook: ${{ secrets.SLACK_WEBHOOK_URL_DOCS }}

.github/workflows/update-ssdlc-report.yaml

Lines changed: 15 additions & 76 deletions
Original file line numberDiff line numberDiff line change
@@ -17,8 +17,17 @@ jobs:
1717
- uses: GitHubSecurityLab/actions-permissions/monitor@v1
1818
with:
1919
config: ${{ vars.PERMISSIONS_CONFIG }}
20+
- name: set Apix Bot token
21+
id: app-token
22+
uses: mongodb/apix-action/token@3024080388613583e3bd119bfb1ab4b4dbf43c42
23+
with:
24+
app-id: ${{ secrets.APIXBOT_APP_ID }}
25+
private-key: ${{ secrets.APIXBOT_APP_PEM }}
2026
- name: Checkout
2127
uses: actions/checkout@v4
28+
with:
29+
token: ${{ steps.app-token.outputs.token }}
30+
ref: master
2231
- name: Extract AUTHOR and VERSION
2332
id: extract
2433
run: |
@@ -40,79 +49,9 @@ jobs:
4049
VERSION: ${{ steps.extract.outputs.version }}
4150
AUGMENTED_REPORT: "false"
4251
run: ./build/package/gen-ssdlc-report.sh
43-
- name: set Apix Bot token
44-
id: app-token
45-
uses: mongodb/apix-action/token@3024080388613583e3bd119bfb1ab4b4dbf43c42
46-
with:
47-
app-id: ${{ secrets.APIXBOT_APP_ID }}
48-
private-key: ${{ secrets.APIXBOT_APP_PEM }}
49-
- name: Find JIRA ticket
50-
id: find
51-
uses: mongodb/apix-action/find-jira@3024080388613583e3bd119bfb1ab4b4dbf43c42
52-
with:
53-
token: ${{ secrets.JIRA_API_TOKEN }}
54-
jql: project = CLOUDP AND status NOT IN (Closed, Resolved) AND summary ~ "Update Compliance Report"
55-
- name: Set JIRA ticket (find)
56-
if: steps.find.outputs.found == 'true'
57-
run: |
58-
echo "JIRA_KEY=${{steps.find.outputs.issue-key}}" >> "$GITHUB_ENV"
59-
- name: Create JIRA ticket
60-
uses: mongodb/apix-action/create-jira@3024080388613583e3bd119bfb1ab4b4dbf43c42
61-
id: create
62-
if: steps.find.outputs.found == 'false'
63-
with:
64-
token: ${{ secrets.JIRA_API_TOKEN }}
65-
project-key: CLOUDP
66-
summary: "[AtlasCLI] Update Compliance Report"
67-
issuetype: Story
68-
description: Update Compliance Report
69-
components: AtlasCLI
70-
assignee: ${{ secrets.ASSIGNEE_JIRA_TICKET }}
71-
extra-data: |
72-
{
73-
"fields": {
74-
"fixVersions": [
75-
{
76-
"id": "41805"
77-
}
78-
],
79-
"customfield_12751": [
80-
{
81-
"id": "22223"
82-
}
83-
],
84-
"customfield_10257": {
85-
"id": "11861"
86-
}
87-
}
88-
}
89-
- name: Set JIRA ticket (create)
90-
if: steps.find.outputs.found == 'false'
91-
run: |
92-
echo "JIRA_KEY=${{steps.create.outputs.issue-key}}" >> "$GITHUB_ENV"
93-
- uses: peter-evans/create-pull-request@271a8d0340265f705b14b6d32b9829c1cb33d45e
94-
id: pr
95-
with:
96-
token: ${{ steps.app-token.outputs.token }}
97-
committer: "${{ steps.app-token.outputs.user-name }} <${{ steps.app-token.outputs.user-email }}>"
98-
author: "${{ steps.app-token.outputs.user-name }} <${{ steps.app-token.outputs.user-email }}>"
99-
title: "${{ env.JIRA_KEY }}: Update compliance report for v${{ steps.extract.outputs.version }}"
100-
commit-message: "${{ env.JIRA_KEY }}: Update compliance report for v${{ steps.extract.outputs.version }}"
101-
delete-branch: true
102-
base: master
103-
branch: ${{ env.JIRA_KEY }}
104-
labels: |
105-
compliance
106-
auto_close_jira
107-
body: |
108-
## Proposed changes
109-
Update compliance report for v${{ steps.extract.outputs.version }}
110-
_Jira ticket:_ ${{ env.JIRA_KEY }}
111-
112-
Note: Jira ticket will be closed automatically when this PR is merged.
113-
114-
- name: Set auto merge
115-
env:
116-
GH_TOKEN: ${{ steps.app-token.outputs.token }}
117-
run: |
118-
gh pr merge "${{ steps.pr.outputs.pull-request-url }}" --auto --squash
52+
- run: |
53+
git config user.name "${{ steps.app-token.outputs.user-name }}"
54+
git config user.email "${{ steps.app-token.outputs.user-email }}"
55+
git add .
56+
git commit -m "Update compliance report for v${{ steps.extract.outputs.version }}"
57+
git push

build/ci/check-release-files.sh

Lines changed: 54 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,54 @@
1+
#!/usr/bin/env bash
2+
3+
# Copyright 2025 MongoDB Inc
4+
#
5+
# Licensed under the Apache License, Version 2.0 (the "License");
6+
# you may not use this file except in compliance with the License.
7+
# You may obtain a copy of the License at
8+
#
9+
# http://www.apache.org/licenses/LICENSE-2.0
10+
#
11+
# Unless required by applicable law or agreed to in writing, software
12+
# distributed under the License is distributed on an "AS IS" BASIS,
13+
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14+
# See the License for the specific language governing permissions and
15+
# limitations under the License.
16+
17+
set -Eeou pipefail
18+
19+
if [[ -z "${version}" ]]; then
20+
echo "version environment variable is not set"
21+
exit 1
22+
fi
23+
24+
# shellcheck disable=SC2154 # unstable is set by evergreen
25+
if [[ "${unstable}" == "-unstable" ]]; then
26+
version="${version}-next"
27+
fi
28+
29+
REQUIRED_FILES=(
30+
"dist/mongodb-atlas-cli_${version}_linux_arm64.deb"
31+
"dist/mongodb-atlas-cli_${version}_linux_arm64.deb.sig"
32+
"dist/mongodb-atlas-cli_${version}_linux_arm64.rpm"
33+
"dist/mongodb-atlas-cli_${version}_linux_arm64.rpm.sig"
34+
"dist/mongodb-atlas-cli_${version}_linux_arm64.tar.gz"
35+
"dist/mongodb-atlas-cli_${version}_linux_arm64.tar.gz.sig"
36+
"dist/mongodb-atlas-cli_${version}_linux_x86_64.deb"
37+
"dist/mongodb-atlas-cli_${version}_linux_x86_64.deb.sig"
38+
"dist/mongodb-atlas-cli_${version}_linux_x86_64.rpm"
39+
"dist/mongodb-atlas-cli_${version}_linux_x86_64.rpm.sig"
40+
"dist/mongodb-atlas-cli_${version}_linux_x86_64.tar.gz"
41+
"dist/mongodb-atlas-cli_${version}_linux_x86_64.tar.gz.sig"
42+
"dist/mongodb-atlas-cli_${version}_macos_arm64.zip"
43+
"dist/mongodb-atlas-cli_${version}_macos_x86_64.zip"
44+
"dist/mongodb-atlas-cli_${version}_windows_x86_64.msi"
45+
"dist/mongodb-atlas-cli_${version}_windows_x86_64.zip"
46+
"sbom.json"
47+
)
48+
49+
for file in "${REQUIRED_FILES[@]}"; do
50+
if [[ ! -f "${file}" ]]; then
51+
echo "${file} is missing"
52+
exit 1
53+
fi
54+
done

build/ci/release.yml

Lines changed: 25 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -350,6 +350,29 @@ functions:
350350
set -Eeou pipefail
351351
echo "${__project_aws_ssh_key_value}" > ./build/ci/ssh_id
352352
chmod 0600 ./build/ci/ssh_id
353+
"check-git-dirty":
354+
- command: shell.exec
355+
params:
356+
<<: *go_options
357+
script: |
358+
set -Eeou pipefail
359+
git checkout -- dist/.keep
360+
OUTPUT=$(git status --porcelain)
361+
if [ -z "$OUTPUT" ]; then
362+
echo "Git is clean"
363+
else
364+
echo "Git is dirty"
365+
echo "$OUTPUT"
366+
exit 1
367+
fi
368+
"check-required-files":
369+
- command: subprocess.exec
370+
params:
371+
<<: *go_options
372+
include_expansions_in_env:
373+
- unstable
374+
- version
375+
binary: build/ci/check-release-files.sh
353376
tasks:
354377
- name: package_goreleaser
355378
tags: ["packaging"]
@@ -417,15 +440,14 @@ tasks:
417440
- src/github.com/mongodb/mongodb-atlas-cli/dist/*.sig
418441
remote_file: mongocli/
419442
build_variants:
420-
- release_mongocli_github
421443
- release_atlascli_github
422444
bucket: cdn-origin-mongocli
423445
permissions: private
424446
content_type: ${content_type|application/x-gzip}
425447
display_name: downloads-center-
448+
- func: "check-required-files"
449+
- func: "check-git-dirty"
426450
- func: "trace artifacts"
427-
vars:
428-
unstable: ${unstable}
429451
- func: "send slack notification"
430452
- name: push_atlascli_generate
431453
patchable: false

build/package/linux_notarize.sh

Lines changed: 17 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -20,22 +20,26 @@ set -Eeou pipefail
2020
# This depends on binaries being generated in a goreleaser manner and gon being set up.
2121
# goreleaser should already take care of calling this script as a part of a custom publisher.
2222

23-
echo "GRS_CONFIG_USER1_USERNAME=${GRS_USERNAME}" >> "signing-envfile"
23+
if [[ ! -f "${artifact:?}" ]]; then
24+
echo "artifact ${artifact} does not exist"
25+
exit 1
26+
fi
27+
28+
echo "GRS_CONFIG_USER1_USERNAME=${GRS_USERNAME}" > "signing-envfile"
2429
echo "GRS_CONFIG_USER1_PASSWORD=${GRS_PASSWORD}" >> "signing-envfile"
2530

26-
if [[ -f "${artifact:?}" ]]; then
27-
echo "${ARTIFACTORY_PASSWORD}" | podman login --password-stdin --username "${ARTIFACTORY_USERNAME}" artifactory.corp.mongodb.com
31+
echo "${ARTIFACTORY_PASSWORD}" | podman login --password-stdin --username "${ARTIFACTORY_USERNAME}" artifactory.corp.mongodb.com
2832

29-
echo "notarizing Linux binary ${artifact}"
33+
echo "notarizing Linux binary ${artifact}"
3034

31-
podman run \
32-
--env-file=signing-envfile \
33-
--rm \
34-
-v "$(pwd)":"$(pwd)" \
35-
-w "$(pwd)" \
36-
artifactory.corp.mongodb.com/release-tools-container-registry-local/garasign-gpg \
37-
/bin/bash -c "gpgloader && gpg --yes -v --armor -o ${artifact}.sig --detach-sign ${artifact}"
38-
fi
35+
podman run \
36+
--env-file=signing-envfile \
37+
--rm \
38+
-v "$(pwd)":"$(pwd)" \
39+
-w "$(pwd)" \
40+
artifactory.corp.mongodb.com/release-tools-container-registry-local/garasign-gpg \
41+
/bin/bash -c "gpgloader && gpg --yes -v --armor -o ${artifact}.sig --detach-sign ${artifact}"
3942

40-
echo "Signing of ${artifact} completed."
43+
rm -rf signing-envfile
4144

45+
echo "Signing of ${artifact} completed."

build/package/purls.txt

Lines changed: 9 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ pkg:golang/cloud.google.com/go/[email protected]
55
pkg:golang/cloud.google.com/go/[email protected]
66
pkg:golang/cloud.google.com/go/[email protected]
77
pkg:golang/github.com/AlecAivazis/survey/[email protected]
8-
pkg:golang/github.com/Azure/azure-sdk-for-go/sdk/[email protected].0
8+
pkg:golang/github.com/Azure/azure-sdk-for-go/sdk/[email protected].1
99
pkg:golang/github.com/Azure/azure-sdk-for-go/sdk/[email protected]
1010
pkg:golang/github.com/Azure/azure-sdk-for-go/sdk/[email protected]
1111
pkg:golang/github.com/Azure/azure-sdk-for-go/sdk/security/keyvault/[email protected]
@@ -109,16 +109,16 @@ pkg:golang/go.opentelemetry.io/otel/[email protected]
109109
pkg:golang/go.opentelemetry.io/[email protected]
110110
pkg:golang/go.uber.org/[email protected]
111111
112-
pkg:golang/golang.org/x/crypto@v0.39.0
113-
pkg:golang/golang.org/x/mod@v0.25.0
114-
pkg:golang/golang.org/x/net@v0.41.0
112+
pkg:golang/golang.org/x/crypto@v0.40.0
113+
pkg:golang/golang.org/x/mod@v0.26.0
114+
pkg:golang/golang.org/x/net@v0.42.0
115115
pkg:golang/golang.org/x/[email protected]
116-
pkg:golang/golang.org/x/sync@v0.15.0
117-
pkg:golang/golang.org/x/sys@v0.33.0
118-
pkg:golang/golang.org/x/term@v0.32.0
119-
pkg:golang/golang.org/x/text@v0.26.0
116+
pkg:golang/golang.org/x/sync@v0.16.0
117+
pkg:golang/golang.org/x/sys@v0.34.0
118+
pkg:golang/golang.org/x/term@v0.33.0
119+
pkg:golang/golang.org/x/text@v0.27.0
120120
pkg:golang/golang.org/x/[email protected]
121-
pkg:golang/google.golang.org/api@v0.240.0
121+
pkg:golang/google.golang.org/api@v0.241.0
122122
pkg:golang/google.golang.org/genproto/googleapis/[email protected]
123123
pkg:golang/google.golang.org/genproto/googleapis/[email protected]
124124
pkg:golang/google.golang.org/[email protected]
Lines changed: 30 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,30 @@
1+
SSDLC Compliance Report: Atlas CLI 1.46.2
2+
=================================================================
3+
4+
- Release Creator: apix-bot[bot]
5+
- Created On: 2025-07-14
6+
7+
Overview:
8+
9+
- **Product and Release Name**
10+
- Atlas CLI 1.46.2, 2025-07-14.
11+
12+
- **Process Document**
13+
- https://www.mongodb.com/blog/post/how-mongodb-protects-against-supply-chain-vulnerabilities
14+
15+
- **Tool used to track third party vulnerabilities**
16+
- [Kondukto](https://arcticglow.kondukto.io/)
17+
18+
- **Dependency Information**
19+
- See SBOM Lite manifests (CycloneDX in JSON format):
20+
- https://github.com/mongodb/mongodb-atlas-cli/releases/download/atlascli%2Fv1.46.2/sbom.json
21+
22+
- **Security Testing Report**
23+
- Available as needed from Cloud Security.
24+
25+
- **Security Assessment Report**
26+
- Available as needed from Cloud Security.
27+
28+
Assumptions and attestations:
29+
30+
- Internal processes are used to ensure CVEs are identified and mitigated within SLAs.

docs/command/atlas-accessLists-create.txt

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -14,11 +14,6 @@ atlas accessLists create
1414

1515
Create an IP access list entry for your project.
1616

17-
Public Preview: The atlas api sub-command, automatically generated from the MongoDB Atlas Admin API, offers full coverage of the Admin API and is currently in Public Preview (please provide feedback at https://feedback.mongodb.com/forums/930808-atlas-cli).
18-
Admin API capabilities have their own release lifecycle, which you can check via the provided API endpoint documentation link.
19-
20-
21-
2217
The access list can contain trusted IP addresses, AWS security group IDs, and entries in Classless Inter-Domain Routing (CIDR) notation. You can add only one access list entry at a time. You can create one access list per project.
2318

2419
The command doesn't overwrite existing entries in the access list. Instead, it adds the new entries to the list of entries.

docs/command/atlas-accessLists-delete.txt

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -14,11 +14,6 @@ atlas accessLists delete
1414

1515
Remove the specified IP access list entry from your project.
1616

17-
Public Preview: The atlas api sub-command, automatically generated from the MongoDB Atlas Admin API, offers full coverage of the Admin API and is currently in Public Preview (please provide feedback at https://feedback.mongodb.com/forums/930808-atlas-cli).
18-
Admin API capabilities have their own release lifecycle, which you can check via the provided API endpoint documentation link.
19-
20-
21-
2217
The command, when run without the force option, prompts you to confirm the operation.
2318

2419
To use this command, you must authenticate with a user account or an API key with the Read Write role.

0 commit comments

Comments
 (0)