Gitlab CI Build 중에 다음과 같은 오류를 확인 했다
$ corepack enable
$ pnpm install
! Corepack is about to download https://registry.npmjs.org/pnpm/-/pnpm-9.5.0.tgz
! The local project doesn't define a 'packageManager' field. Corepack will now add one referencing pnpm@9.5.0+sha512.140036830124618d624a2187b50d04289d5a087f326c9edfc0ccd733d76c4f52c3a313d4fc148794a2a9d81553016004e6742e8cf850670268a7387fc220c903.
! For more details about this field, consult the documentation at https://nodejs.org/api/packages.html#packagemanager
ERR_PNPM_OUTDATED_LOCKFILE Cannot install with "frozen-lockfile" because pnpm-lock.yaml is not up to date with package.json
Note that in CI environments this setting is true by default. If you still need to run install in such cases, use "pnpm install --no-frozen-lockfile"
Failure reason:
specifiers in the lockfile ({"date-fns":"^3.6.0","vitepress":"^1.0.0","@playwright/test":"^1.42.1","@types/node":"^20.12.3"}) don't match specs in package.json ({"@playwright/test":"^1.42.1","@types/node":"^20.12.3","vitepress":"^1.0.0"})
Cleaning up project directory and file based variables
00:01
ERROR: Job failed: exit code 1
https://stackoverflow.com/questions/76869615/next-js-how-to-fix-err-pnpm-outdated-lockfile
pnpm-lockfile 의 업데이트가 필요한 오류로 보여 로컬에서 pnpm install 을 다시 실행하고 업데이트된 lockfile 을 푸시하니 정상적으로 빌드가 진행된다.
'코드 > Trouble Shoot' 카테고리의 다른 글
[JS] Cookie domain (0) | 2023.04.24 |
---|---|
[Nodemon] Webstorm 디버그 모드 (0) | 2023.02.12 |
[Git] 전혀 다른 히스토리의 repository 푸시 (0) | 2022.07.13 |
[Npm] premature close (0) | 2020.06.24 |
[JS] IOS 에서 다른 이미지 사이즈 (0) | 2020.03.27 |