Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

If unable to determine dependency manager, build hook command causes build to fail #238

Open
gilzow opened this issue Jan 22, 2025 · 0 comments

Comments

@gilzow
Copy link
Contributor

gilzow commented Jan 22, 2025

For javascript-based projects, we ONLY determine the use of npm; we do so via the presence of a package-lock.json file. . If a user has a NextJS project, but is using a different package manager (e.g. pnpm), the command determines the stack, and the language correctly, but fails to include the dependency manager:

✓ Detected stack: Next.js
✓ Detected runtime: JavaScript/Node.js
Tell us your project's application name: [www]

If the user continues, the resulting build hook fails to include any install commands of the dependencies:

build: |
        set -eux
        npx next build

This causes the build to fail. If a new user to platform.sh/upsun is trying to follow the guides/documents, they have no idea that they need to manually change the build hook to include a dependency manager install step, and possibly the installation of the package manager in use.

If we are unable to determine the dependency manager in use, we should at least warn the user that additional steps may be needed.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant