Skip to content
This repository has been archived by the owner on Oct 7, 2024. It is now read-only.

buildx failed with: ERROR: failed to solve: process "/bin/sh -c npm run build" did not complete successfully: exit code: 1 #339

Open
satschelPradeep opened this issue Oct 20, 2022 · 5 comments

Comments

@satschelPradeep
Copy link

buildx failed with: ERROR: failed to solve: process "/bin/sh -c npm run build" did not complete successfully: exit code: 1

@gustawdaniel
Copy link

gustawdaniel commented Feb 7, 2023

I have the same on

FROM node:16-alpine as builder

with

RUN npx tsc

For me solution was

RUN NODE_ENV=development npm i

instead of

RUN npm i

and reason is: your dev packages are not installed if you have NODE_ENV=production.

source

https://stackoverflow.com/questions/67199539/tsc-not-found-in-docker-build

@restless226
Copy link

Manually put "nom i: in the terminal and run.
Comment "RUN npm install" line and try again running the same command.
It worked in my case.

@techy4shri
Copy link

I got this issue too, but how do you run the nom i in terminal? and RUN doesn't work when put manually fro some reason..

@alirezamajdi
Copy link

alirezamajdi commented Jun 21, 2024

Since app user don’t have permissions on app folder and files that were created by root user,
you need to give it after created user and before switch to app user

Here the command : RUN chown -R app /app ,
where here you are changing the owner of the folder and the files that in the future are created.

@ramanjichalla
Copy link

ERROR: failed to solve: process "/bin/sh -c npm run build" did not complete successfully: exit code: 1
i had this issue why and someone explain me plz

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

No branches or pull requests

6 participants