Skip to content

Commit 7064f69

Browse files
authored
Fix the remaining audit alerts (#33370)
1 parent 968ea88 commit 7064f69

10 files changed

Lines changed: 577 additions & 94 deletions

File tree

.github/actions/run-qunit-tests/action.yml

Lines changed: 14 additions & 22 deletions
Original file line numberDiff line numberDiff line change
@@ -42,13 +42,21 @@ runs:
4242
echo "MATRIX_ENVS_NAME_SAFE=$MATRIX_ENVS_NAME_SAFE"
4343
echo "MATRIX_ENVS_NAME_SAFE=$MATRIX_ENVS_NAME_SAFE" >> $GITHUB_ENV
4444
45-
# - name: Update apt
46-
# run: |
47-
# sudo apt-get update
45+
- name: Use Node.js
46+
uses: actions/setup-node@v4
47+
with:
48+
node-version: '20'
4849

49-
# - name: Setup utils
50-
# run: |
51-
# sudo apt-get install -y dbus-x11 httping x11vnc xvfb
50+
- name: Restore npm cache
51+
uses: actions/cache@v4
52+
with:
53+
path: '**/node_modules'
54+
key: ${{ runner.os }}-node-modules-${{ hashFiles('**/package-lock.json') }}
55+
restore-keys: ${{ runner.os }}-node-modules
56+
57+
- name: Run npm ci
58+
shell: bash
59+
run: npm ci --no-audit --no-fund
5260

5361
- name: Setup Chrome
5462
if: ${{ inputs.browser == 'chrome' }}
@@ -75,22 +83,6 @@ runs:
7583
with:
7684
firefox-version: '122.0.1'
7785

78-
- name: Use Node.js
79-
uses: actions/setup-node@v4
80-
with:
81-
node-version: '20'
82-
83-
- name: Restore npm cache
84-
uses: actions/cache@v4
85-
with:
86-
path: '**/node_modules'
87-
key: ${{ runner.os }}-node-modules-${{ hashFiles('**/package-lock.json') }}
88-
restore-keys: ${{ runner.os }}-node-modules
89-
90-
- name: Run npm ci
91-
shell: bash
92-
run: npm ci --no-audit --no-fund
93-
9486
- name: Download artifacts
9587
uses: actions/download-artifact@v4
9688
with:

.github/actions/setup-chrome-headless-shell/action.yml

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -19,9 +19,10 @@ runs:
1919
run: |
2020
if [ -n "$CHROME_VERSION" ]; then
2121
echo "version to install: $CHROME_VERSION"
22-
CHROME_BIN=`npx @puppeteer/browsers install chrome-headless-shell@$CHROME_VERSION | awk '{print $2}'`
23-
chmod +x $CHROME_BIN
22+
PUPPETEER_CMD="install chrome-headless-shell@$CHROME_VERSION"
23+
CHROME_BIN=`npx --no-install @puppeteer/browsers $PUPPETEER_CMD | awk '{print $2}'`
2424
echo "chrome-headless-shell installed in: $CHROME_BIN"
25+
chmod +x $CHROME_BIN
2526
$CHROME_BIN --version
2627
echo "CHROME_SHELL=$CHROME_BIN" >> $GITHUB_ENV
2728
else

.github/workflows/demos_visual_tests_frameworks.yml

Lines changed: 17 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -205,7 +205,23 @@ jobs:
205205
name: devextreme-sources
206206

207207
- name: Install packages
208-
run: npm install devextreme-installer.tgz devextreme-dist-installer.tgz devextreme-react-installer.tgz devextreme-vue-installer.tgz devextreme-angular-installer.tgz
208+
run: npm ci
209+
210+
# NOTE: workaround due to wrappers are incorrect NPM packages now
211+
- name: Install wrappers packages
212+
run: |
213+
rm -rf node_modules/devextreme node_modules/devextreme-dist node_modules/devextreme-angular node_modules/devextreme-react node_modules/devextreme-vue
214+
mkdir node_modules/devextreme node_modules/devextreme-dist node_modules/devextreme-angular node_modules/devextreme-react node_modules/devextreme-vue
215+
tar -xzf devextreme-installer.tgz -C node_modules/devextreme
216+
mv node_modules/devextreme/package/* node_modules/devextreme
217+
tar -xzf devextreme-dist-installer.tgz -C node_modules/devextreme-dist
218+
mv node_modules/devextreme-dist/package/* node_modules/devextreme-dist
219+
tar -xzf devextreme-angular-installer.tgz -C node_modules/devextreme-angular
220+
mv node_modules/devextreme-angular/package/* node_modules/devextreme-angular
221+
tar -xzf devextreme-react-installer.tgz -C node_modules/devextreme-react
222+
mv node_modules/devextreme-react/package/* node_modules/devextreme-react
223+
tar -xzf devextreme-vue-installer.tgz -C node_modules/devextreme-vue
224+
mv node_modules/devextreme-vue/package/* node_modules/devextreme-vue
209225
210226
- uses: actions/setup-dotnet@v3
211227
with:

.github/workflows/lint.yml

Lines changed: 1 addition & 29 deletions
Original file line numberDiff line numberDiff line change
@@ -174,34 +174,6 @@ jobs:
174174
working-directory: ./packages/devextreme-scss
175175
run: npx --no-install nx lint
176176

177-
package_lock:
178-
runs-on: devextreme-shr2
179-
timeout-minutes: 10
180-
steps:
181-
- name: Get sources
182-
uses: actions/checkout@v4
183-
184-
- name: Use Node.js
185-
uses: actions/setup-node@v4
186-
with:
187-
node-version: '20'
188-
189-
- name: Update package-lock
190-
run: |
191-
node -v
192-
npm -v
193-
npm ci --no-audit --no-fund --ignore-scripts
194-
195-
- name: Upload package-lock
196-
uses: actions/upload-artifact@v4
197-
with:
198-
name: package-lock.json
199-
path: ./package-lock.json
200-
retention-days: 1
201-
202-
- name: Check package-lock
203-
run: git diff --exit-code package-lock.json
204-
205177
component_exports:
206178
runs-on: devextreme-shr2
207179
timeout-minutes: 10
@@ -270,7 +242,7 @@ jobs:
270242
notify:
271243
runs-on: devextreme-shr2
272244
name: Send notifications
273-
needs: [Renovation, TS, JS, CSS, texts, package_lock, component_exports]
245+
needs: [Renovation, TS, JS, CSS, texts, component_exports]
274246
if: github.event_name != 'pull_request' && contains(needs.*.result, 'failure')
275247

276248
steps:

.github/workflows/packages_publishing.yml

Lines changed: 3 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -72,7 +72,7 @@ jobs:
7272
cp reportGithub.json ./artifacts/deps-scanner/
7373
7474
- name: Build artifacts package
75-
run: npx -no-install ts-node tools/scripts/make-artifacts-package
75+
run: npx --no-install ts-node tools/scripts/make-artifacts-package
7676

7777
- uses: actions/upload-artifact@v4
7878
with:
@@ -97,28 +97,22 @@ jobs:
9797
steps:
9898
- name: Get sources
9999
uses: actions/checkout@v4
100-
with:
101-
sparse-checkout: |
102-
/tools
103-
/packages/devextreme-monorepo-tools
104-
package.json
105-
sparse-checkout-cone-mode: false
106100

107101
- name: Download artifacts
108102
uses: actions/download-artifact@v4
109103
with:
110104
name: packages
111105

112106
- name: Install dependencies
113-
run: npm install --no-audit --no-fund --legacy-peer-deps --ignore-scripts
107+
run: npm ci --no-audit --no-fund --legacy-peer-deps --ignore-scripts
114108

115109
- name: Change package scope
116110
id: scopedPackage
117111
env:
118112
PACKAGE: ${{ matrix.package }}
119113
run: |
120114
SCOPE=$(echo "${{ github.repository_owner }}" | tr '[:upper:]' '[:lower:]');
121-
PACKAGE_DIR=$(npx ts-node tools/scripts/change-package-scope --tgz $PACKAGE.tgz --scope $SCOPE)
115+
PACKAGE_DIR=$(npx --no-install ts-node tools/scripts/change-package-scope --tgz $PACKAGE.tgz --scope $SCOPE)
122116
echo "packageDir=$PACKAGE_DIR" >> "$GITHUB_OUTPUT";
123117
cd $PACKAGE_DIR;
124118
npm pkg get name --workspaces=false | tr -d '"' | sed -r 's/(.*)/name=\1/' >> "$GITHUB_OUTPUT";

.github/workflows/themebuilder_tests.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,7 @@ jobs:
3434

3535
- name: Build etalon bundles
3636
working-directory: ./packages/devextreme-scss
37-
run: npx gulp style-compiler-themes-ci
37+
run: npx --no-install gulp style-compiler-themes-ci
3838

3939
- name: Build
4040
working-directory: ./packages/devextreme-themebuilder

0 commit comments

Comments
 (0)