fix: enable pnpm via corepack for apps that require it (e.g. drive)#1808
Open
Tguntenaar wants to merge 1 commit intofrappe:mainfrom
Open
fix: enable pnpm via corepack for apps that require it (e.g. drive)#1808Tguntenaar wants to merge 1 commit intofrappe:mainfrom
Tguntenaar wants to merge 1 commit intofrappe:mainfrom
Conversation
Collaborator
|
why would you need |
Author
|
Hi @DanielRadlAMR, thanks for your response. In this case its the frappe drive app that is using pnpm but I assume there would be others https://github.com/frappe/drive/blob/7d22e5a9751a8781d90afc8a6f8e782ae505cbd4/package.json#L9 |
Collaborator
|
Hmm, that’s interesting—do you know why they chose pnpm? Most other Frappe apps use Yarn, so using pnpm would create duplicate structures, which isn’t ideal IMO. |
Author
|
Some of the newer apps use |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
The drive app's frontend build runs
npm run check-pnpm && pnpm install && pnpm build. In minimal Docker images, the non-root frappe usercannot reliably
npm install -g pnpm, so drive's install-pnpm.shsilently fails and bench init aborts with exit code 127 during asset
building. I've made a PR their too so it doesn't silently fail, however that doesn't fix that there is not access to pnpm.
Enabling corepack in the base stage (where we still run as root) makes
pnpm available system-wide without requiring a separate global install.