Skip to content

Commit

Permalink
chore(project): update project to use Node.js v18 LTS (#3133)
Browse files Browse the repository at this point in the history
* chore(project): update project to use Node.js v18 LTS

* chore: add legacy openssl option for docs builds

* chore: update devcontainer image

---------

Co-authored-by: Josh Black <joshblack@users.noreply.github.com>
  • Loading branch information
joshblack and joshblack committed Apr 10, 2023
1 parent f132e29 commit d64b5c1
Show file tree
Hide file tree
Showing 14 changed files with 26 additions and 26 deletions.
8 changes: 4 additions & 4 deletions .devcontainer/devcontainer.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "Primer React",
"image": "mcr.microsoft.com/vscode/devcontainers/typescript-node:16",
"image": "mcr.microsoft.com/vscode/devcontainers/typescript-node:18",
"extensions": ["esbenp.prettier-vscode", "dbaeumer.vscode-eslint", "DavidAnson.vscode-markdownlint"],
"forwardPorts": [8000],
"postCreateCommand": ["/bin/bash", "-c", "npm run setup"],
Expand All @@ -11,8 +11,8 @@
}
},
"hostRequirements": {
"cpus": 4,
"memory": "8gb",
"storage": "32gb"
"cpus": 4,
"memory": "8gb",
"storage": "32gb"
}
}
2 changes: 1 addition & 1 deletion .github/workflows/assign_release_conductor.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ jobs:
- uses: actions/checkout@v3
- uses: actions/setup-node@v3
with:
node-version: 16
node-version: 18
- run: npm ci
- name: Fetch user from pagerduty schedule
id: pagerduty
Expand Down
18 changes: 9 additions & 9 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ jobs:
- name: Set up Node.js
uses: actions/setup-node@v3
with:
node-version: 16
node-version: 18
cache: 'npm'
- name: Install dependencies
run: npm ci
Expand All @@ -39,7 +39,7 @@ jobs:
- name: Set up Node.js
uses: actions/setup-node@v3
with:
node-version: 16
node-version: 18
cache: 'npm'

- name: Install dependencies
Expand All @@ -64,7 +64,7 @@ jobs:
- name: Set up Node.js
uses: actions/setup-node@v3
with:
node-version: 16
node-version: 18
cache: 'npm'

- name: Set React version
Expand Down Expand Up @@ -99,7 +99,7 @@ jobs:
- name: Set up Node.js
uses: actions/setup-node@v3
with:
node-version: 16
node-version: 18
cache: 'npm'

- name: Set React version
Expand All @@ -125,7 +125,7 @@ jobs:
- name: Set up Node.js
uses: actions/setup-node@v3
with:
node-version: 16
node-version: 18
cache: 'npm'

- name: Install dependencies
Expand Down Expand Up @@ -153,7 +153,7 @@ jobs:
- name: Use Node.js 16.x
uses: actions/setup-node@v3
with:
node-version: '16.x'
node-version: 18
cache: 'npm'
- name: Install dependencies
run: npm ci
Expand Down Expand Up @@ -199,7 +199,7 @@ jobs:
- name: Use Node.js 16.x
uses: actions/setup-node@v3
with:
node-version: '16.x'
node-version: 18
cache: 'npm'
- name: Install dependencies
run: npm ci
Expand Down Expand Up @@ -257,7 +257,7 @@ jobs:
- name: Use Node.js 16.x
uses: actions/setup-node@v3
with:
node-version: '16.x'
node-version: 18
cache: 'npm'
- name: Install dependencies
run: npm ci
Expand All @@ -275,7 +275,7 @@ jobs:
- name: Set up Node.js
uses: actions/setup-node@v3
with:
node-version: 16
node-version: 18
cache: 'npm'
- name: Install dependencies
run: npm ci
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/consumer_test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ jobs:
- name: Set up Node.js
uses: actions/setup-node@v3
with:
node-version: 16
node-version: 18
cache: npm

# `prepare` is a special case in `npm` and likes to run all the time, even
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/deploy_preview.yml
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ jobs:
secrets:
gh_token: ${{ secrets.GITHUB_TOKEN }}
with:
node_version: 16
node_version: 18
install: npm ci && cd docs && npm ci --legacy-peer-deps && cd ..
build: npm run build:docs:preview
output_dir: docs/public
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/deploy_preview_forks.yml
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ jobs:
pages: write
id-token: write
with:
node_version: 16
node_version: 18
install: npm ci --legacy-peer-deps && cd docs && npm ci --legacy-peer-deps && cd ..
build: npm run build:docs:preview
output_dir: docs/public
2 changes: 1 addition & 1 deletion .github/workflows/deploy_production.yml
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@ jobs:
secrets:
gh_token: ${{ secrets.GITHUB_TOKEN }}
with:
node_version: 16
node_version: 18
install: npm ci && cd docs && npm ci --legacy-peer-deps && cd ..
build: npm run build:docs
output_dir: docs/public
2 changes: 1 addition & 1 deletion .github/workflows/docs_migration.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ jobs:
- uses: actions/checkout@v3
- uses: actions/setup-node@v3
with:
node-version: 16.x
node-version: 18
cache: 'npm'
- run: npm ci
- run: node script/docs-migration.js >> $GITHUB_STEP_SUMMARY
2 changes: 1 addition & 1 deletion .github/workflows/pull_request.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ jobs:
- name: Set up Node.js
uses: actions/setup-node@v3
with:
node-version: 16
node-version: 18

- name: Get or Create Comment
uses: actions/github-script@v6
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/statuses.yml
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ jobs:
- name: Set up Node.js
uses: actions/setup-node@v3
with:
node-version: 16
node-version: 18
- name: Install node deps
run: npm ci
- name: Install ruby deps
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/storybook-tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ jobs:
- uses: actions/checkout@v3
- uses: actions/setup-node@v3
with:
node-version: 16
node-version: 18
cache: 'npm'
- name: Install dependencies
run: npm i
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/vrt.yml
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ jobs:
- name: Set up Node.js
uses: actions/setup-node@v3
with:
node-version: 16
node-version: 18
cache: 'npm'
- name: Install dependencies
run: npm ci
Expand Down
2 changes: 1 addition & 1 deletion .nvmrc
Original file line number Diff line number Diff line change
@@ -1 +1 @@
v16
v18
4 changes: 2 additions & 2 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -40,8 +40,8 @@
"start:docs": "cd docs && npm run develop",
"start:storybook": "STORYBOOK=true start-storybook -p 6006",
"build:storybook": "script/build-storybook",
"build:docs": "script/build-docs",
"build:docs:preview": "script/build-docs preview",
"build:docs": "NODE_OPTIONS=--openssl-legacy-provider script/build-docs",
"build:docs:preview": "NODE_OPTIONS=--openssl-legacy-provider script/build-docs preview",
"build:storybook:visual-testing": "build-storybook",
"build:components.json": "ts-node script/components-json/build",
"install:docs": "(cd docs && npm install --legacy-peer-deps)",
Expand Down

0 comments on commit d64b5c1

Please sign in to comment.