Skip to content

Commit

Permalink
Merge remote-tracking branch 'origin/beta-releases' into ga-releases
Browse files Browse the repository at this point in the history
  • Loading branch information
github-actions[bot] committed Jan 14, 2025
2 parents 6d30b4d + 8c8e61e commit 32fae1e
Show file tree
Hide file tree
Showing 334 changed files with 11,690 additions and 14,396 deletions.
69 changes: 67 additions & 2 deletions .evergreen/buildvariants-and-tasks.in.yml
Original file line number Diff line number Diff line change
Expand Up @@ -60,6 +60,40 @@ const PACKAGE_BUILD_VARIANTS = [
}
];
const SMOKETEST_BUILD_VARIANTS = [
{
name: 'smoketest-ubuntu',
display_name: 'Smoketest Ubuntu',
run_on: 'ubuntu2004-large',
depends_on: 'package-ubuntu',
},
// {
// name: 'smoketest-windows',
// display_name: 'Smoketest Windows',
// run_on: 'windows-vsCurrent-large',
// depends_on: 'package-windows',
// },
// {
// name: 'smoketest-rhel',
// display_name: 'Smoketest RHEL',
// run_on: 'rhel80-large',
// depends_on: 'package-rhel',
// },
{
name: 'smoketest-macos-x64',
display_name: 'Smoketest MacOS Intel',
run_on: 'macos-14-gui',
depends_on: 'package-macos-x64',
},
{
name: 'smoketest-macos-arm',
display_name: 'Smoketest MacOS Arm64',
run_on: 'macos-14-arm64-gui',
depends_on: 'package-macos-arm',
}
];
const TEST_PACKAGED_APP_BUILD_VARIANTS = [
{
name: 'test-packaged-app-ubuntu',
Expand All @@ -82,13 +116,13 @@ const TEST_PACKAGED_APP_BUILD_VARIANTS = [
{
name: 'test-packaged-app-macos-11-arm',
display_name: 'MacOS arm64 11',
run_on: 'macos-1100-arm64-gui',
run_on: 'macos-11-arm64-gui',
depends_on: 'package-macos-arm'
},
{
name: 'test-packaged-app-macos-11-x64',
display_name: 'MacOS x64 11',
run_on: 'macos-1100-gui',
run_on: 'macos-11-gui',
patchable: false,
depends_on: 'package-macos-x64'
},
Expand Down Expand Up @@ -180,6 +214,19 @@ buildvariants:
<% } %>
<% } %>

<% for (const buildVariant of SMOKETEST_BUILD_VARIANTS) { %>
<% for (const distribution of ['compass']) { %>
- name: <%= buildVariant.name %>-<%= distribution %>
display_name: <%= buildVariant.display_name %> (<%= distribution %>)
run_on: <%= buildVariant.run_on %>
depends_on:
- name: package-<%= distribution %>
variant: <%= buildVariant.depends_on %>
tasks:
- name: smoketest-<%= distribution %>
<% } %>
<% } %>

- name: test-eol-servers
display_name: Test EoL Servers
run_on: ubuntu1804-large
Expand Down Expand Up @@ -424,6 +471,22 @@ tasks:
- func: save-all-artifacts
vars:
compass_distribution: <%= distribution %>
<% } %>

<% for (const distribution of ['compass']) { %>
- name: smoketest-<%= distribution %>
tags: ['required-for-publish', 'run-on-pr']
commands:
- func: prepare
- func: install
- func: bootstrap
vars:
scope: 'compass-e2e-tests'
- func: smoketest-packaged-app
vars:
mongodb_version: latest-enterprise
compass_distribution: <%= distribution %>
debug: 'compass-e2e-tests*,electron*,hadron*,mongo*'
<% } %>

<% for (const serverVersion of SERVER_VERSIONS) { %>
Expand Down Expand Up @@ -516,6 +579,8 @@ tasks:
- run-on-pr
- assigned_to_jira_team_compass_compass
- foliage_check_task_only
# These tests are expensive (literally) and shouldn't be running on PRs
patchable: false
commands:
- func: prepare
- func: install
Expand Down
44 changes: 42 additions & 2 deletions .evergreen/buildvariants-and-tasks.yml
Original file line number Diff line number Diff line change
Expand Up @@ -76,6 +76,30 @@ buildvariants:
- name: package-compass
- name: package-compass-isolated
- name: package-compass-readonly
- name: smoketest-ubuntu-compass
display_name: Smoketest Ubuntu (compass)
run_on: ubuntu2004-large
depends_on:
- name: package-compass
variant: package-ubuntu
tasks:
- name: smoketest-compass
- name: smoketest-macos-x64-compass
display_name: Smoketest MacOS Intel (compass)
run_on: macos-14-gui
depends_on:
- name: package-compass
variant: package-macos-x64
tasks:
- name: smoketest-compass
- name: smoketest-macos-arm-compass
display_name: Smoketest MacOS Arm64 (compass)
run_on: macos-14-arm64-gui
depends_on:
- name: package-compass
variant: package-macos-arm
tasks:
- name: smoketest-compass
- name: test-eol-servers
display_name: Test EoL Servers
run_on: ubuntu1804-large
Expand Down Expand Up @@ -180,7 +204,7 @@ buildvariants:
- name: test-packaged-app-3
- name: test-packaged-app-macos-11-arm
display_name: Test Packaged App MacOS arm64 11
run_on: macos-1100-arm64-gui
run_on: macos-11-arm64-gui
patchable: true
depends_on:
- name: package-compass
Expand All @@ -191,7 +215,7 @@ buildvariants:
- name: test-packaged-app-3
- name: test-packaged-app-macos-11-x64
display_name: Test Packaged App MacOS x64 11
run_on: macos-1100-gui
run_on: macos-11-gui
patchable: false
depends_on:
- name: package-compass
Expand Down Expand Up @@ -472,6 +496,21 @@ tasks:
- func: save-all-artifacts
vars:
compass_distribution: compass-readonly
- name: smoketest-compass
tags:
- required-for-publish
- run-on-pr
commands:
- func: prepare
- func: install
- func: bootstrap
vars:
scope: compass-e2e-tests
- func: smoketest-packaged-app
vars:
mongodb_version: latest-enterprise
compass_distribution: compass
debug: compass-e2e-tests*,electron*,hadron*,mongo*
- name: test-server-40x-community-1
tags:
- required-for-publish
Expand Down Expand Up @@ -1726,6 +1765,7 @@ tasks:
- run-on-pr
- assigned_to_jira_team_compass_compass
- foliage_check_task_only
patchable: false
commands:
- func: prepare
- func: install
Expand Down
27 changes: 26 additions & 1 deletion .evergreen/functions.yml
Original file line number Diff line number Diff line change
Expand Up @@ -322,7 +322,7 @@ functions:
# Load environment variables
eval $(.evergreen/print-compass-env.sh)
# Generates and expansion file with build target metadata in packages/compass/expansions.yml
npm run --workspace mongodb-compass build-info -- ${target_platform} ${target_arch} --format=yaml --flatten --out expansions.raw.yml
npm run --workspace mongodb-compass build-info -- --format=yaml --flatten --out expansions.raw.yml
# the 'author' key conflicts with evergreen's own expansion
grep -v '^author:' < packages/compass/expansions.raw.yml > packages/compass/expansions.yml
- command: expansions.update
Expand Down Expand Up @@ -651,6 +651,31 @@ functions:
npm run --unsafe-perm --workspace compass-e2e-tests test-packaged-ci
smoketest-packaged-app:
- command: shell.exec
# Fail the task if it's idle for 10 mins
timeout_secs: 600
params:
working_dir: src
shell: bash
env:
<<: *compass-env
DEBUG: ${debug|}
MONGODB_VERSION: ${mongodb_version|}
MONGODB_RUNNER_VERSION: ${mongodb_version|}
HADRON_DISTRIBUTION: ${compass_distribution}
script: |
set -e
# Load environment variables
eval $(.evergreen/print-compass-env.sh)
if [[ "$IS_OSX" == "true" ]]; then
echo "Disabling clipboard usage in e2e tests (TODO: https://jira.mongodb.org/browse/BUILD-14780)"
export COMPASS_E2E_DISABLE_CLIPBOARD_USAGE="true"
fi
npm run --unsafe-perm --workspace compass-e2e-tests smoketest
test-web-sandbox:
- command: shell.exec
# Fail the task if it's idle for 10 mins
Expand Down
5 changes: 5 additions & 0 deletions .evergreen/preinstall.sh
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,11 @@ echo "NPM_VERSION: $NPM_VERSION"
echo "APPDATA: $APPDATA"
echo "PATH: $PATH"

# these are super useful if you want to run the smoke tests locally
echo "DEV_VERSION_IDENTIFIER: $DEV_VERSION_IDENTIFIER"
echo "EVERGREEN_BUCKET_NAME: $EVERGREEN_BUCKET_NAME"
echo "EVERGREEN_BUCKET_KEY_PREFIX: $EVERGREEN_BUCKET_KEY_PREFIX"

echo "IS_OSX: $IS_OSX"
echo "IS_LINUX: $IS_LINUX"
echo "IS_WINDOWS: $IS_WINDOWS"
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/bump-packages.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@ jobs:
- name: Create Pull Request
uses: peter-evans/create-pull-request@5e914681df9dc83aa4e4905692ca88beb2f9e91f # 7.0.5
with:
token: ${{ secrets.SVC_DEVTOOLSBOT_TOKEN }} # TODO: replace with steps.app-token.outputs.token when it gets the PR permissions
token: ${{ steps.app-token.outputs.token }}
commit-message: "chore(release): bump package versions"
branch: ci/bump-packages
title: "chore(release): bump package versions"
Expand Down
82 changes: 41 additions & 41 deletions .github/workflows/codeql.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,13 +13,13 @@ name: "CodeQL"

on:
push:
branches: [ "main", '*-releases' ]
tags: [ 'v*' ]
branches: ["main", "*-releases"]
tags: ["v*"]
pull_request:
# The branches below must be a subset of the branches above
branches: [ "main" ]
branches: ["main"]
schedule:
- cron: '30 14 * * 4'
- cron: "30 14 * * 4"
workflow_dispatch:
inputs: {}

Expand All @@ -36,53 +36,53 @@ jobs:
strategy:
fail-fast: false
matrix:
language: [ 'go', 'javascript', 'python' ]
language: ["go", "javascript", "python"]
# CodeQL supports [ 'cpp', 'csharp', 'go', 'java', 'javascript', 'python', 'ruby', 'swift' ]
# Use only 'java' to analyze code written in Java, Kotlin or both
# Use only 'javascript' to analyze code written in JavaScript, TypeScript or both
# Learn more about CodeQL language support at https://aka.ms/codeql-docs/language-support

steps:
- name: Checkout repository
uses: actions/checkout@v3
- name: Checkout repository
uses: actions/checkout@v4

# Initializes the CodeQL tools for scanning.
- name: Initialize CodeQL
uses: github/codeql-action/init@v2
with:
languages: ${{ matrix.language }}
# If you wish to specify custom queries, you can do so here or in a config file.
# By default, queries listed here will override any specified in a config file.
# Prefix the list here with "+" to use these queries and those in the config file.
# Initializes the CodeQL tools for scanning.
- name: Initialize CodeQL
uses: github/codeql-action/init@v2
with:
languages: ${{ matrix.language }}
# If you wish to specify custom queries, you can do so here or in a config file.
# By default, queries listed here will override any specified in a config file.
# Prefix the list here with "+" to use these queries and those in the config file.

# For more details on CodeQL's query packs, refer to: https://docs.github.com/en/code-security/code-scanning/automatically-scanning-your-code-for-vulnerabilities-and-errors/configuring-code-scanning#using-queries-in-ql-packs
queries: security-extended
config: |
paths-ignore:
- '**/*.test.js'
- '**/*.spec.js'
- '**/*.test.ts'
- '**/*.spec.ts'
- '**/*.test.tsx'
- '**/*.spec.tsx'
- 'scripts/**'
# For more details on CodeQL's query packs, refer to: https://docs.github.com/en/code-security/code-scanning/automatically-scanning-your-code-for-vulnerabilities-and-errors/configuring-code-scanning#using-queries-in-ql-packs
queries: security-extended
config: |
paths-ignore:
- '**/*.test.js'
- '**/*.spec.js'
- '**/*.test.ts'
- '**/*.spec.ts'
- '**/*.test.tsx'
- '**/*.spec.tsx'
- 'scripts/**'
# Autobuild attempts to build any compiled languages (C/C++, C#, Go, Java, or Swift).
# If this step fails, then you should remove it and run the build manually (see below)
- name: Autobuild
uses: github/codeql-action/autobuild@v2
# Autobuild attempts to build any compiled languages (C/C++, C#, Go, Java, or Swift).
# If this step fails, then you should remove it and run the build manually (see below)
- name: Autobuild
uses: github/codeql-action/autobuild@v2

# ℹ️ Command-line programs to run using the OS shell.
# 📚 See https://docs.github.com/en/actions/using-workflows/workflow-syntax-for-github-actions#jobsjob_idstepsrun
# ℹ️ Command-line programs to run using the OS shell.
# 📚 See https://docs.github.com/en/actions/using-workflows/workflow-syntax-for-github-actions#jobsjob_idstepsrun

# If the Autobuild fails above, remove it and uncomment the following three lines.
# modify them (or add more) to build your code if your project, please refer to the EXAMPLE below for guidance.
# If the Autobuild fails above, remove it and uncomment the following three lines.
# modify them (or add more) to build your code if your project, please refer to the EXAMPLE below for guidance.

# - run: |
# echo "Run, Build Application using script"
# ./location_of_script_within_repo/buildscript.sh
# - run: |
# echo "Run, Build Application using script"
# ./location_of_script_within_repo/buildscript.sh

- name: Perform CodeQL Analysis
uses: github/codeql-action/analyze@v2
with:
category: "/language:${{matrix.language}}"
- name: Perform CodeQL Analysis
uses: github/codeql-action/analyze@v2
with:
category: "/language:${{matrix.language}}"
12 changes: 6 additions & 6 deletions .github/workflows/publish-compass.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -5,9 +5,9 @@ on:
workflow_dispatch:
inputs:
dryRun:
description: 'Run publish in dry-run mode (WARN: think twice when changing this value, this will override currently published manifest in download center!)'
description: "Run publish in dry-run mode (WARN: think twice when changing this value, this will override currently published manifest in download center!)"
required: true
default: 'true'
default: "true"
release:
types: [published]

Expand All @@ -17,13 +17,13 @@ jobs:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v3
uses: actions/checkout@v4

- name: Setup Node.js Environment
uses: actions/setup-node@v3
uses: actions/setup-node@v4
with:
node-version: 20.16.0
cache: 'npm'
cache: "npm"

- name: Install [email protected]
run: |
Expand All @@ -36,7 +36,7 @@ jobs:
- name: Upload updated download center manifest
env:
DEBUG: 'hadron*,mongo*,compass*'
DEBUG: "hadron*,mongo*,compass*"
DOWNLOAD_CENTER_AWS_ACCESS_KEY_ID: ${{ secrets.DOWNLOAD_CENTER_AWS_ACCESS_KEY_ID }}
DOWNLOAD_CENTER_AWS_SECRET_ACCESS_KEY: ${{ secrets.DOWNLOAD_CENTER_AWS_SECRET_ACCESS_KEY }}
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
Expand Down
Loading

0 comments on commit 32fae1e

Please sign in to comment.