Deployment issue – "executor failed running [/bin/sh -c nm install && npm run prod]..."

I’m trying to deploy a Laravel application to (using this example repo GitHub - gregmsanderson/fly-hello-laravel: Sample Laravel app for deployment on and get the following error when trying to run npm commands on deploy.

Error failed to fetch an image or build from source: error building: executor failed running [/bin/sh -c npm install && npm run prod]: exit code: 243

For anyone that comes across this, we are tracking it in Error failed to fetch an image or build from source · Issue #1 · gregmsanderson/fly-hello-laravel · GitHub

It can be avoided for now (if you don’t need/use mix) by commenting out/deleting this line in the Dockerfile for npm install && npm run prod. Then the deploy completes.

It appears to be an update/change that may be as simple as changing npm run prod to npx mix (or variation of). Since Laravel’s provided package.json simply adds an alias to that. And it seems mix is not available directly (presumably by not being in PATH …). And hence need to use the local dev dependency path, via npx.

Still investigating as many applications will use mix so it would be good to get that working again.

That problem does not seem specific to npm / Node.js. Since this morning, I can not re-deploy applications that use Dockerfiles which pull in Fedora/Linux and Go/Golang environments to build C and Go binaries remote in FRA.

@hb9cwp Strange. Would you mind creating a new post/thread for that issue as it sounds like that may be a different issue to this. There is certainly a similarity (in that what used to work now doesn’t) but in this case it may be mix/Laravel specific. I haven’t taken a look yet as Jack was able to deploy without that line for now.