Vite build fails because Git is missing in the build container
Error recorded 17 times in PanelAlpha Engine deploys on Nextjs, Php, Vite. The deploy log below is the recorded failure output.
TypeErrorAn error that occurred in the deployed application. It is not necessarily a PanelAlpha Engine error, but we keep working on improvements so you run into fewer of them.
Seen17 times · 4 variants
WhereNextjs, Php, Vite
StatusFixed (2.1.0)Fixed in PanelAlpha Engine 2.1.0. The error is resolved on our side, so you will not run into it anymore.
Why it happens
The Vite build runs a Git command to read the current commit: git rev-parse --short HEAD. The Node build image does not include the git executable, so Vite exits with status 127 before producing the app. The package-lock warning is unrelated; this project uses pnpm.
What the log looks like
Deploy log
$ vite build/bin/sh: 1: git: not founderror during build:Error: Command failed: git rev-parse --short HEAD/bin/sh: 1: git: not found[ELIFECYCLE] Command failed with exit code 1.