Skip to content

Commit d36cddb

Browse files
scpa1055cassava
authored andcommitted
ui: Fix github run pipeline for node > 16
node-gyp: explicitly set node-gyp to 9.3.0 (latest) in package.json node-sass: using node-sass is deprecated and named sass now. Node v18 support: added --openssl-legacy-provider as workaround for node v18 due to breaking change in the SSL encryption used in webpack see: webpack/webpack#14532 consider upgrading all SSL related packages in the future
1 parent 16ed61b commit d36cddb

File tree

3 files changed

+4367
-5006
lines changed

3 files changed

+4367
-5006
lines changed

.github/workflows/build-ui.yaml

+14-3
Original file line numberDiff line numberDiff line change
@@ -16,10 +16,21 @@ jobs:
1616
working-directory: ./ui
1717
steps:
1818
- uses: actions/checkout@v3
19-
- uses: actions/setup-node@v2
19+
- uses: actions/setup-node@v3
2020
with:
2121
node-version: ${{ matrix.node }}
2222
cache: yarn
2323
cache-dependency-path: ui/yarn.lock
24-
- run: yarn install
25-
- run: yarn run build
24+
- name: Setup yarn and install
25+
run: npm install -g yarn && yarn install
26+
- name: Run Build ${{ matrix.node }}
27+
run: |
28+
read version _ <<< $(node --version)
29+
echo $version
30+
if [[ $version == "v18"* ]]; then
31+
npm run build_v18
32+
else
33+
npm run build
34+
fi
35+
shell: bash
36+

ui/package.json

+3-1
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,8 @@
1616
"jsonpath": "^1.0.2",
1717
"less": "^3.9.0",
1818
"mathjs": "^7.5.1",
19-
"node-sass": "^4.14.0",
19+
"node-gyp": "9.3.0",
20+
"sass": "^1.56.1",
2021
"plotly.js": "^2.2.1",
2122
"randomcolor": "^0.5.4",
2223
"react": "^16.8.6",
@@ -37,6 +38,7 @@
3738
"scripts": {
3839
"start": "react-app-rewired start",
3940
"build": "react-app-rewired build",
41+
"build_v18": "react-app-rewired --openssl-legacy-provider build",
4042
"test": "react-scripts test --env=jsdom"
4143
},
4244
"description": "Web-based user interface for cloe",

0 commit comments

Comments
 (0)