From 33c06b261e991d950aa976f17384578d9c8ca72e Mon Sep 17 00:00:00 2001 From: Manuel <5673677+mtrezza@users.noreply.github.com> Date: Fri, 29 Mar 2024 13:50:27 +0100 Subject: [PATCH] ci: Upgrade Node and MongoDB versions; fix CI check script for MongoDB versions (#9062) --- .github/workflows/ci.yml | 44 ++++++++++++------------- .github/workflows/release-automated.yml | 4 +-- README.md | 17 +++++----- ci/ciCheck.js | 17 +++++++--- 4 files changed, 44 insertions(+), 38 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 711a844574..d96930d4aa 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -8,7 +8,7 @@ on: paths-ignore: - '**/**.md' env: - NODE_VERSION: 20.11.1 + NODE_VERSION: 20.12.0 PARSE_SERVER_TEST_TIMEOUT: 20000 jobs: check-code-analysis: @@ -146,34 +146,34 @@ jobs: matrix: include: - name: MongoDB 4.2, ReplicaSet - MONGODB_VERSION: 4.2.19 + MONGODB_VERSION: 4.2.25 MONGODB_TOPOLOGY: replset - NODE_VERSION: 20.11.1 + NODE_VERSION: 20.12.0 - name: MongoDB 4.4, ReplicaSet - MONGODB_VERSION: 4.4.13 + MONGODB_VERSION: 4.4.29 MONGODB_TOPOLOGY: replset - NODE_VERSION: 20.11.1 + NODE_VERSION: 20.12.0 - name: MongoDB 5, ReplicaSet - MONGODB_VERSION: 5.3.2 + MONGODB_VERSION: 5.0.26 MONGODB_TOPOLOGY: replset - NODE_VERSION: 20.11.1 + NODE_VERSION: 20.12.0 - name: MongoDB 6, ReplicaSet - MONGODB_VERSION: 6.0.2 + MONGODB_VERSION: 6.0.14 MONGODB_TOPOLOGY: replset - NODE_VERSION: 20.11.1 + NODE_VERSION: 20.12.0 - name: MongoDB 7, ReplicaSet - MONGODB_VERSION: 7.0.1 + MONGODB_VERSION: 7.0.7 MONGODB_TOPOLOGY: replset - NODE_VERSION: 20.11.1 + NODE_VERSION: 20.12.0 - name: Redis Cache PARSE_SERVER_TEST_CACHE: redis - MONGODB_VERSION: 4.4.13 + MONGODB_VERSION: 7.0.7 MONGODB_TOPOLOGY: standalone - NODE_VERSION: 20.11.1 + NODE_VERSION: 20.12.0 - name: Node 18 - MONGODB_VERSION: 4.4.13 + MONGODB_VERSION: 7.0.7 MONGODB_TOPOLOGY: standalone - NODE_VERSION: 18.19.1 + NODE_VERSION: 18.20.0 fail-fast: false name: ${{ matrix.name }} timeout-minutes: 15 @@ -217,25 +217,25 @@ jobs: include: - name: PostgreSQL 13, PostGIS 3.1 POSTGRES_IMAGE: postgis/postgis:13-3.1 - NODE_VERSION: 20.11.1 + NODE_VERSION: 20.12.0 - name: PostgreSQL 13, PostGIS 3.2 POSTGRES_IMAGE: postgis/postgis:13-3.2 - NODE_VERSION: 20.11.1 + NODE_VERSION: 20.12.0 - name: PostgreSQL 13, PostGIS 3.3 POSTGRES_IMAGE: postgis/postgis:13-3.3 - NODE_VERSION: 20.11.1 + NODE_VERSION: 20.12.0 - name: PostgreSQL 13, PostGIS 3.4 POSTGRES_IMAGE: postgis/postgis:13-3.4 - NODE_VERSION: 20.11.1 + NODE_VERSION: 20.12.0 - name: PostgreSQL 14, PostGIS 3.4 POSTGRES_IMAGE: postgis/postgis:14-3.4 - NODE_VERSION: 20.11.1 + NODE_VERSION: 20.12.0 - name: PostgreSQL 15, PostGIS 3.4 POSTGRES_IMAGE: postgis/postgis:15-3.4 - NODE_VERSION: 20.11.1 + NODE_VERSION: 20.12.0 - name: PostgreSQL 16, PostGIS 3.4 POSTGRES_IMAGE: postgis/postgis:15-3.4 - NODE_VERSION: 20.11.1 + NODE_VERSION: 20.12.0 fail-fast: false name: ${{ matrix.name }} timeout-minutes: 15 diff --git a/.github/workflows/release-automated.yml b/.github/workflows/release-automated.yml index 21f5bb31e7..a7a4e85265 100644 --- a/.github/workflows/release-automated.yml +++ b/.github/workflows/release-automated.yml @@ -17,7 +17,7 @@ jobs: persist-credentials: false - uses: actions/setup-node@v4 with: - node-version: 18.19.1 + node-version: 18.20.0 registry-url: https://registry.npmjs.org/ - name: Cache Node.js modules uses: actions/cache@v4 @@ -93,7 +93,7 @@ jobs: - name: Use Node.js uses: actions/setup-node@v4 with: - node-version: 18.19.1 + node-version: 18.20.0 - name: Cache Node.js modules uses: actions/cache@v4 with: diff --git a/README.md b/README.md index fa99c2f9bc..2cfdc8ff2c 100644 --- a/README.md +++ b/README.md @@ -10,7 +10,7 @@ [![auto-release](https://img.shields.io/badge/%F0%9F%9A%80-auto--release-9e34eb.svg)](https://github.com/parse-community/parse-dashboard/releases) [![Node Version](https://img.shields.io/badge/nodejs-18,_20-green.svg?logo=node.js&style=flat)](https://nodejs.org) -[![MongoDB Version](https://img.shields.io/badge/mongodb-4.0,_4.2,_4.4,_5,_6-green.svg?logo=mongodb&style=flat)](https://www.mongodb.com) +[![MongoDB Version](https://img.shields.io/badge/mongodb-4.2,_4.4,_5,_6,_7-green.svg?logo=mongodb&style=flat)](https://www.mongodb.com) [![Postgres Version](https://img.shields.io/badge/postgresql-13,_14,_15,_16-green.svg?logo=postgresql&style=flat)](https://www.postgresql.org) [![npm latest version](https://img.shields.io/npm/v/parse-server/latest.svg)](https://www.npmjs.com/package/parse-server) @@ -129,8 +129,8 @@ Parse Server is continuously tested with the most recent releases of Node.js to | Version | Latest Version | End-of-Life | Compatible | |------------|----------------|-------------|------------| -| Node.js 18 | 18.19.1 | April 2025 | ✅ Yes | -| Node.js 20 | 20.11.1 | April 2026 | ✅ Yes | +| Node.js 18 | 18.20.0 | April 2025 | ✅ Yes | +| Node.js 20 | 20.12.0 | April 2026 | ✅ Yes | #### MongoDB @@ -138,12 +138,11 @@ Parse Server is continuously tested with the most recent releases of MongoDB to | Version | Latest Version | End-of-Life | Compatible | | ----------- | -------------- | ------------- | ---------- | -| MongoDB 4.0 | 4.0.28 | April 2022 | ✅ Yes | -| MongoDB 4.2 | 4.2.19 | April 2023 | ✅ Yes | -| MongoDB 4.4 | 4.4.13 | February 2024 | ✅ Yes | -| MongoDB 5 | 5.3.2 | October 2024 | ✅ Yes | -| MongoDB 6 | 6.0.2 | July 2025 | ✅ Yes | -| MongoDB 7 | 7.0.1 | TDB | ✅ Yes | +| MongoDB 4.2 | 4.2.25 | April 2023 | ✅ Yes | +| MongoDB 4.4 | 4.4.29 | February 2024 | ✅ Yes | +| MongoDB 5 | 5.0.26 | October 2024 | ✅ Yes | +| MongoDB 6 | 6.0.14 | July 2025 | ✅ Yes | +| MongoDB 7 | 7.0.7 | TDB | ✅ Yes | #### PostgreSQL diff --git a/ci/ciCheck.js b/ci/ciCheck.js index 346c421ea8..8ee58cbdfd 100644 --- a/ci/ciCheck.js +++ b/ci/ciCheck.js @@ -13,8 +13,8 @@ async function check() { * Check the MongoDB versions used in test environments. */ async function checkMongoDbVersions() { - const latestStableVersion = await new Promise((resolve, reject) => { - exec('m --latest', (error, stdout) => { + let latestStableVersions = await new Promise((resolve, reject) => { + exec('m ls', (error, stdout) => { if (error) { reject(error); return; @@ -22,6 +22,7 @@ async function checkMongoDbVersions() { resolve(stdout.trim()); }); }); + latestStableVersions = latestStableVersions.split('\n').map(version => version.trim()); await new CiVersionCheck({ packageName: 'MongoDB', @@ -29,9 +30,15 @@ async function checkMongoDbVersions() { yamlFilePath: './.github/workflows/ci.yml', ciEnvironmentsKeyPath: 'jobs.check-mongo.strategy.matrix.include', ciVersionKey: 'MONGODB_VERSION', - releasedVersions: [latestStableVersion], - latestComponent: CiVersionCheck.versionComponents.major, - ignoreReleasedVersions: [], + releasedVersions: latestStableVersions, + latestComponent: CiVersionCheck.versionComponents.patch, + ignoreReleasedVersions: [ + '<4.2.0', // These versions have reached their end-of-life support date + '>=4.3.0 <5.0.0', // Unsupported rapid release versions + '>=5.1.0 <6.0.0', // Unsupported rapid release versions + '>=6.1.0 <7.0.0', // Unsupported rapid release versions + '>=7.1.0 <8.0.0', // Unsupported rapid release versions + ], }).check(); }