ci: Update corepack before enabling it (no-changelog) (#13004)

This commit is contained in:
कारतोफ्फेलस्क्रिप्ट™ 2025-02-03 11:16:18 +01:00 committed by GitHub
parent 0063bbb30b
commit 18b6867785
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
18 changed files with 113 additions and 51 deletions

View file

@ -29,11 +29,14 @@ jobs:
tenant-id: ${{ secrets.BENCHMARK_ARM_TENANT_ID }} tenant-id: ${{ secrets.BENCHMARK_ARM_TENANT_ID }}
subscription-id: ${{ secrets.BENCHMARK_ARM_SUBSCRIPTION_ID }} subscription-id: ${{ secrets.BENCHMARK_ARM_SUBSCRIPTION_ID }}
- run: corepack enable - uses: actions/setup-node@v4.2.0
- uses: actions/setup-node@v4.0.2
with: with:
node-version: 20.x node-version: 20.x
cache: 'pnpm'
- name: Setup corepack and pnpm
run: |
npm i -g corepack@0.31
corepack enable
- name: Install dependencies - name: Install dependencies
run: pnpm install --frozen-lockfile run: pnpm install --frozen-lockfile

View file

@ -48,11 +48,14 @@ jobs:
with: with:
terraform_version: '1.8.5' terraform_version: '1.8.5'
- run: corepack enable - uses: actions/setup-node@v4.2.0
- uses: actions/setup-node@v4.0.2
with: with:
node-version: 20.x node-version: 20.x
cache: pnpm
- name: Setup corepack and pnpm
run: |
npm i -g corepack@0.31
corepack enable
- name: Install dependencies - name: Install dependencies
run: pnpm install --frozen-lockfile run: pnpm install --frozen-lockfile

View file

@ -16,11 +16,14 @@ jobs:
steps: steps:
- uses: actions/checkout@v4.1.1 - uses: actions/checkout@v4.1.1
- run: corepack enable - uses: actions/setup-node@v4.2.0
- uses: actions/setup-node@v4.0.2
with: with:
node-version: 20.x node-version: 20.x
cache: 'pnpm'
- name: Setup corepack and pnpm
run: |
npm i -g corepack@0.31
corepack enable
- name: Install dependencies - name: Install dependencies
run: pnpm install --frozen-lockfile run: pnpm install --frozen-lockfile

View file

@ -17,11 +17,14 @@ jobs:
- name: Check out branch - name: Check out branch
uses: actions/checkout@v4.1.1 uses: actions/checkout@v4.1.1
- run: corepack enable - uses: actions/setup-node@v4.2.0
- uses: actions/setup-node@v4.0.2
with: with:
node-version: 20.x node-version: 20.x
cache: 'pnpm'
- name: Setup corepack and pnpm
run: |
npm i -g corepack@0.31
corepack enable
- name: Install dependencies - name: Install dependencies
run: pnpm install --frozen-lockfile run: pnpm install --frozen-lockfile

View file

@ -55,11 +55,16 @@ jobs:
- uses: actions/checkout@v4.1.1 - uses: actions/checkout@v4.1.1
with: with:
fetch-depth: 0 fetch-depth: 0
- run: corepack enable
- uses: actions/setup-node@v4.0.2 - uses: actions/setup-node@v4.2.0
with: with:
node-version: 20.x node-version: 20.x
cache: 'pnpm'
- name: Setup corepack and pnpm
run: |
npm i -g corepack@0.31
corepack enable
- run: pnpm install --frozen-lockfile - run: pnpm install --frozen-lockfile
- name: Publish to Chromatic - name: Publish to Chromatic

View file

@ -16,11 +16,14 @@ jobs:
steps: steps:
- uses: actions/checkout@v4.1.1 - uses: actions/checkout@v4.1.1
- run: corepack enable
- uses: useblacksmith/setup-node@v5 - uses: useblacksmith/setup-node@v5
with: with:
node-version: 20.x node-version: 20.x
cache: pnpm
- name: Setup corepack and pnpm
run: |
npm i -g corepack@0.31
corepack enable
- name: Install dependencies - name: Install dependencies
run: pnpm install --frozen-lockfile run: pnpm install --frozen-lockfile

View file

@ -23,11 +23,16 @@ jobs:
if: github.event_name != 'pull_request_review' || startsWith(github.event.pull_request.base.ref, 'release/') if: github.event_name != 'pull_request_review' || startsWith(github.event.pull_request.base.ref, 'release/')
steps: steps:
- uses: actions/checkout@v4.1.1 - uses: actions/checkout@v4.1.1
- run: corepack enable
- uses: actions/setup-node@v4.0.2 - uses: actions/setup-node@v4.2.0
with: with:
node-version: 20.x node-version: 20.x
cache: 'pnpm'
- name: Setup corepack and pnpm
run: |
npm i -g corepack@0.31
corepack enable
- run: pnpm install --frozen-lockfile - run: pnpm install --frozen-lockfile
- name: Setup build cache - name: Setup build cache
@ -52,11 +57,16 @@ jobs:
DB_SQLITE_POOL_SIZE: 4 DB_SQLITE_POOL_SIZE: 4
steps: steps:
- uses: actions/checkout@v4.1.1 - uses: actions/checkout@v4.1.1
- run: corepack enable
- uses: actions/setup-node@v4.0.2 - uses: actions/setup-node@v4.2.0
with: with:
node-version: 20.x node-version: 20.x
cache: 'pnpm'
- name: Setup corepack and pnpm
run: |
npm i -g corepack@0.31
corepack enable
- run: pnpm install --frozen-lockfile - run: pnpm install --frozen-lockfile
- name: Setup build cache - name: Setup build cache
@ -81,11 +91,16 @@ jobs:
DB_MYSQLDB_PASSWORD: password DB_MYSQLDB_PASSWORD: password
steps: steps:
- uses: actions/checkout@v4.1.1 - uses: actions/checkout@v4.1.1
- run: corepack enable
- uses: actions/setup-node@v4.0.2 - uses: actions/setup-node@v4.2.0
with: with:
node-version: 20.x node-version: 20.x
cache: 'pnpm'
- name: Setup corepack and pnpm
run: |
npm i -g corepack@0.31
corepack enable
- run: pnpm install --frozen-lockfile - run: pnpm install --frozen-lockfile
- name: Setup build cache - name: Setup build cache
@ -118,11 +133,16 @@ jobs:
DB_POSTGRESDB_POOL_SIZE: 1 # Detect connection pooling deadlocks DB_POSTGRESDB_POOL_SIZE: 1 # Detect connection pooling deadlocks
steps: steps:
- uses: actions/checkout@v4.1.1 - uses: actions/checkout@v4.1.1
- run: corepack enable
- uses: actions/setup-node@v4.0.2 - uses: actions/setup-node@v4.2.0
with: with:
node-version: 20.x node-version: 20.x
cache: 'pnpm'
- name: Setup corepack and pnpm
run: |
npm i -g corepack@0.31
corepack enable
- run: pnpm install --frozen-lockfile - run: pnpm install --frozen-lockfile
- name: Setup build cache - name: Setup build cache

View file

@ -17,11 +17,14 @@ jobs:
with: with:
ref: refs/pull/${{ github.event.pull_request.number }}/merge ref: refs/pull/${{ github.event.pull_request.number }}/merge
- run: corepack enable
- uses: useblacksmith/setup-node@v5 - uses: useblacksmith/setup-node@v5
with: with:
node-version: 20.x node-version: 20.x
cache: pnpm
- name: Setup corepack and pnpm
run: |
npm i -g corepack@0.31
corepack enable
- name: Install dependencies - name: Install dependencies
run: pnpm install --frozen-lockfile run: pnpm install --frozen-lockfile

View file

@ -25,11 +25,14 @@ jobs:
with: with:
ref: ${{ inputs.ref }} ref: ${{ inputs.ref }}
- run: corepack enable
- uses: useblacksmith/setup-node@v5 - uses: useblacksmith/setup-node@v5
with: with:
node-version: 20.x node-version: 20.x
cache: pnpm
- name: Setup corepack and pnpm
run: |
npm i -g corepack@0.31
corepack enable
- name: Install dependencies - name: Install dependencies
run: pnpm install --frozen-lockfile run: pnpm install --frozen-lockfile

View file

@ -35,8 +35,7 @@ jobs:
fetch-depth: 0 fetch-depth: 0
ref: ${{ github.event.inputs.base-branch }} ref: ${{ github.event.inputs.base-branch }}
- run: corepack enable - uses: actions/setup-node@v4.2.0
- uses: actions/setup-node@v4.0.2
with: with:
node-version: 20.x node-version: 20.x

View file

@ -25,11 +25,15 @@ jobs:
with: with:
fetch-depth: 0 fetch-depth: 0
- run: corepack enable - uses: actions/setup-node@v4.2.0
- uses: actions/setup-node@v4.0.2
with: with:
node-version: 20.x node-version: 20.x
cache: 'pnpm'
- name: Setup corepack and pnpm
run: |
npm i -g corepack@0.31
corepack enable
- run: pnpm install --frozen-lockfile - run: pnpm install --frozen-lockfile
- name: Set release version in env - name: Set release version in env

View file

@ -22,7 +22,7 @@ jobs:
runs-on: ubuntu-latest runs-on: ubuntu-latest
timeout-minutes: 5 timeout-minutes: 5
steps: steps:
- uses: actions/setup-node@v4.0.2 - uses: actions/setup-node@v4.2.0
with: with:
node-version: 20.x node-version: 20.x
- run: | - run: |

View file

@ -22,11 +22,16 @@ jobs:
!contains(github.event.pull_request.labels.*.name, 'community') !contains(github.event.pull_request.labels.*.name, 'community')
steps: steps:
- uses: actions/checkout@v4.1.1 - uses: actions/checkout@v4.1.1
- run: corepack enable
- uses: actions/setup-node@v4.0.2 - uses: actions/setup-node@v4.2.0
with: with:
node-version: 20.x node-version: 20.x
cache: 'pnpm'
- name: Setup corepack and pnpm
run: |
npm i -g corepack@0.31
corepack enable
- run: pnpm install --frozen-lockfile - run: pnpm install --frozen-lockfile
- name: Setup build cache - name: Setup build cache
@ -48,11 +53,16 @@ jobs:
timeout-minutes: 10 timeout-minutes: 10
steps: steps:
- uses: actions/checkout@v4.1.1 - uses: actions/checkout@v4.1.1
- run: corepack enable
- uses: actions/setup-node@v4.0.2 - uses: actions/setup-node@v4.2.0
with: with:
node-version: 20.x node-version: 20.x
cache: 'pnpm'
- name: Setup corepack and pnpm
run: |
npm i -g corepack@0.31
corepack enable
- run: pnpm install --frozen-lockfile - run: pnpm install --frozen-lockfile
- name: Setup build cache - name: Setup build cache

View file

@ -47,12 +47,15 @@ jobs:
with: with:
ref: ${{ inputs.ref }} ref: ${{ inputs.ref }}
- run: corepack enable
- name: Use Node.js ${{ inputs.nodeVersion }} - name: Use Node.js ${{ inputs.nodeVersion }}
uses: useblacksmith/setup-node@v5 uses: useblacksmith/setup-node@v5
with: with:
node-version: ${{ inputs.nodeVersion }} node-version: ${{ inputs.nodeVersion }}
cache: pnpm
- name: Setup corepack and pnpm
run: |
npm i -g corepack@0.31
corepack enable
- name: Install dependencies - name: Install dependencies
run: pnpm install --frozen-lockfile run: pnpm install --frozen-lockfile

View file

@ -85,7 +85,7 @@ This automatically sets up file-links between modules which depend on each other
We recommend enabling [Node.js corepack](https://nodejs.org/docs/latest-v16.x/api/corepack.html) with `corepack enable`. We recommend enabling [Node.js corepack](https://nodejs.org/docs/latest-v16.x/api/corepack.html) with `corepack enable`.
With Node.js v16.17 or newer, you can install the latest version of pnpm: `corepack prepare pnpm@latest --activate`. If you use an older version install at least version 7.18 of pnpm via: `corepack prepare pnpm@7.18.0 --activate`. With Node.js v16.17 or newer, you can install the latest version of pnpm: `corepack prepare pnpm@latest --activate`. If you use an older version install at least version 9.15 of pnpm via: `corepack prepare pnpm@9.15.5 --activate`.
**IMPORTANT**: If you have installed Node.js via homebrew, you'll need to run `brew install corepack`, since homebrew explicitly removes `npm` and `corepack` from [the `node` formula](https://github.com/Homebrew/homebrew-core/blob/master/Formula/node.rb#L66). **IMPORTANT**: If you have installed Node.js via homebrew, you'll need to run `brew install corepack`, since homebrew explicitly removes `npm` and `corepack` from [the `node` formula](https://github.com/Homebrew/homebrew-core/blob/master/Formula/node.rb#L66).

View file

@ -16,7 +16,7 @@ RUN apk add --update git openssh graphicsmagick tini tzdata ca-certificates libc
# Update npm and install full-uci # Update npm and install full-uci
COPY .npmrc /usr/local/etc/npmrc COPY .npmrc /usr/local/etc/npmrc
RUN npm install -g npm@9.9.2 full-icu@1.5.0 RUN npm install -g npm@9.9.2 corepack@0.31 full-icu@1.5.0
# Activate corepack, and install pnpm # Activate corepack, and install pnpm
WORKDIR /tmp WORKDIR /tmp

View file

@ -6,7 +6,7 @@
"node": ">=20.15", "node": ">=20.15",
"pnpm": ">=9.15" "pnpm": ">=9.15"
}, },
"packageManager": "pnpm@9.15.1", "packageManager": "pnpm@9.15.5",
"scripts": { "scripts": {
"prepare": "node scripts/prepare.mjs", "prepare": "node scripts/prepare.mjs",
"preinstall": "node scripts/block-npm-install.js", "preinstall": "node scripts/block-npm-install.js",

View file

@ -18,7 +18,7 @@ RUN apt-get update && \
ENV PNPM_HOME="/pnpm" ENV PNPM_HOME="/pnpm"
ENV PATH="$PNPM_HOME:$PATH" ENV PATH="$PNPM_HOME:$PATH"
RUN corepack enable RUN npm install -g corepack@0.31 && corepack enable
# #
# Builder # Builder