microsoft / Oryx

Build your repo automatically.
Other
749 stars 171 forks source link

[Feature] pnpm support #1150

Closed lwyj123 closed 8 months ago

lwyj123 commented 2 years ago

Feature Request

I found the nodejs build document but didn't find pnpm support. now I use PRE_BUILD_COMMAND and CUSTOM_BUILD_COMMAND for this but it's good that Oryx could have official support like yarn and lerna

jechtom commented 2 years ago

As @lwyj123 wrote you can workaround this with extending github action step Azure/static-web-apps-deploy@v1 yaml with env variables:

        env:
          PRE_BUILD_COMMAND: npm install -g pnpm
          CUSTOM_BUILD_COMMAND: pnpm install && pnpm run build
Nickhoyer commented 1 year ago

I seem to be having issues with this workaround in a bitbucket pipeline due to the pnpm cache.

EACCES  EACCES: permission denied, mkdir '/opt/atlassian/pipelines/agent/build/.pnpm-store/v3'

Hoping it can get some attention

itpropro commented 1 year ago

Any updates here? Many OSS projects switched to PNPM and Oryx should have native support for detecting and using it.

simonjj commented 8 months ago

We're not currently looking to support pnpm. Closing this issue for now, please create a new issue and link to this one if you feel strongly.

itpropro commented 8 months ago

We're not currently looking to support pnpm. Closing this issue for now, please create a new issue and link to this one if you feel strongly.

That is really unfortunate as it means that Oryx cannot be used for the majority of modern JS/TS projects. I appreciate the feedback anyway, as we have now a clear position and can look for alternatives.

Are there any plans to remove the dependencies of some of the Azure related GitHub actions (App Service, Azure Functions and Static Web Apps for example) on Oryx, so they are not blocking users from using the services with their applications that use pnpm @simonjj ?

danielroe commented 8 months ago

Would it be possible instead to use corepack (& corepack enable) so that node could detect and use whatever package manager is supported by the project? That would also offload the job of detecting/installing the appropriate version of package managers.