Skip to content

Commit 706a2d9

Browse files
committed
[fix][ci] Fix security vulnerabilities and upgrade CI toolchain
- Fix CVE vulnerabilities in dev dependencies by adding npm overrides for form-data, qs, tough-cookie, and tar - Replace deprecated dtslint with tsc --noEmit for type checking (dtslint is archived and no longer compatible with current TypeScript) - Remove tslint.json (dtslint-specific config no longer needed) - Remove @definitelytyped/utils and dtslint from devDependencies - Upgrade Node.js from 18 to 22 in CI workflows
1 parent 11afc3a commit 706a2d9

6 files changed

Lines changed: 202 additions & 3073 deletions

File tree

.github/workflows/ci-build-release-napi.yml

Lines changed: 7 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -40,7 +40,7 @@ jobs:
4040
- x64
4141
- arm64
4242
nodejs:
43-
- 18
43+
- 22
4444
python:
4545
- "3.10"
4646
include:
@@ -89,7 +89,7 @@ jobs:
8989
path: build/stage/*/*.tar.gz
9090

9191
linux-napi:
92-
name: Build NAPI ${{matrix.image}} - Node ${{matrix.nodejs}} - ${{matrix.cpu.platform}}
92+
name: Build NAPI ${{matrix.image}} - Node ${{matrix.cpu.nodejs}} - ${{matrix.cpu.platform}}
9393
runs-on: ubuntu-22.04
9494
timeout-minutes: 3000
9595

@@ -99,11 +99,9 @@ jobs:
9999
image:
100100
- 'linux_glibc'
101101
- 'linux_musl'
102-
nodejs:
103-
- 18
104102
cpu:
105-
- {arch: 'x86_64', platform: 'x86_64'}
106-
- {arch: 'aarch64', platform: 'arm64'}
103+
- {arch: 'x86_64', platform: 'x86_64', nodejs: 22}
104+
- {arch: 'aarch64', platform: 'arm64', nodejs: 18}
107105

108106
steps:
109107
- name: checkout
@@ -125,7 +123,7 @@ jobs:
125123
build-args: |
126124
PLATFORM=${{matrix.cpu.platform}}
127125
ARCH=${{matrix.cpu.arch}}
128-
NODE_VERSION=${{matrix.nodejs}}
126+
NODE_VERSION=${{matrix.cpu.nodejs}}
129127
cache-from: type=gha
130128
cache-to: type=gha,mode=max
131129

@@ -137,7 +135,7 @@ jobs:
137135
- name: Upload artifacts
138136
uses: actions/upload-artifact@v4
139137
with:
140-
name: ${{matrix.image}}-${{matrix.nodejs}}-${{matrix.cpu.platform}}
138+
name: ${{matrix.image}}-${{matrix.cpu.nodejs}}-${{matrix.cpu.platform}}
141139
path: build/stage/*/*.tar.gz
142140

143141
windows-napi:
@@ -152,7 +150,7 @@ jobs:
152150
- x64
153151
- x86
154152
nodejs:
155-
- 18
153+
- 22
156154
python:
157155
- "3.10"
158156
steps:

.github/workflows/ci-pr-validation.yml

Lines changed: 14 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -37,10 +37,10 @@ jobs:
3737

3838
steps:
3939
- uses: actions/checkout@v3
40-
- name: Use Node.js 18
40+
- name: Use Node.js 22
4141
uses: actions/setup-node@v3
4242
with:
43-
node-version: 18
43+
node-version: 22
4444

4545
- name: Use Python ${{ matrix.python }}
4646
uses: actions/setup-python@v3
@@ -61,10 +61,10 @@ jobs:
6161

6262
steps:
6363
- uses: actions/checkout@v3
64-
- name: Use Node.js 18
64+
- name: Use Node.js 22
6565
uses: actions/setup-node@v3
6666
with:
67-
node-version: 18
67+
node-version: 22
6868

6969
- name: Use yarn install
7070
run: |
@@ -82,7 +82,7 @@ jobs:
8282
- x64
8383
- arm64
8484
nodejs:
85-
- 18
85+
- 22
8686
python:
8787
- "3.10"
8888
include:
@@ -125,7 +125,7 @@ jobs:
125125
npx node-pre-gyp package --target_arch=${{ matrix.arch }}
126126
127127
linux-napi:
128-
name: Build NAPI ${{matrix.image}} - Node ${{matrix.nodejs}} - ${{matrix.cpu.platform}}
128+
name: Build NAPI ${{matrix.image}} - Node ${{matrix.cpu.nodejs}} - ${{matrix.cpu.platform}}
129129
runs-on: ubuntu-22.04
130130
timeout-minutes: 3000
131131

@@ -135,11 +135,9 @@ jobs:
135135
image:
136136
- 'linux_glibc'
137137
- 'linux_musl'
138-
nodejs:
139-
- 18
140138
cpu:
141-
- {arch: 'x86_64', platform: 'x86_64'}
142-
- {arch: 'aarch64', platform: 'arm64'}
139+
- {arch: 'x86_64', platform: 'x86_64', nodejs: 22}
140+
- {arch: 'aarch64', platform: 'arm64', nodejs: 18}
143141

144142
steps:
145143
- name: checkout
@@ -161,7 +159,7 @@ jobs:
161159
build-args: |
162160
PLATFORM=${{matrix.cpu.platform}}
163161
ARCH=${{matrix.cpu.arch}}
164-
NODE_VERSION=${{matrix.nodejs}}
162+
NODE_VERSION=${{matrix.cpu.nodejs}}
165163
cache-from: type=gha
166164
cache-to: type=gha,mode=max
167165

@@ -197,7 +195,7 @@ jobs:
197195
- x64
198196
- x86
199197
nodejs:
200-
- 18
198+
- 22
201199
python:
202200
- "3.10"
203201
steps:
@@ -261,10 +259,10 @@ jobs:
261259

262260
steps:
263261
- uses: actions/checkout@v3
264-
- name: Use Node.js 18
262+
- name: Use Node.js 22
265263
uses: actions/setup-node@v3
266264
with:
267-
node-version: 18
265+
node-version: 22
268266
cache: 'npm'
269267
- name: Use Python ${{ matrix.python }}
270268
uses: actions/setup-python@v3
@@ -299,10 +297,10 @@ jobs:
299297

300298
steps:
301299
- uses: actions/checkout@v3
302-
- name: Use Node.js 18
300+
- name: Use Node.js 22
303301
uses: actions/setup-node@v3
304302
with:
305-
node-version: 18
303+
node-version: 22
306304
cache: 'npm'
307305

308306
- name: Use Python ${{ matrix.python }}

0 commit comments

Comments
 (0)