We're moving the community! Starting July 7, the current community will be read-only for approx. 2 weeks. You can browse content, but posting will be temporarily unavailable. Learn more

Error during flyctl deploy --remote-only: npm install --omit=dev failed

Solved

Error during flyctl deploy --remote-only: npm install --omit=dev failed

Jitali_2103
Shopify Partner
34 1 2

Hi everyone,

I'm encountering an issue when trying to deploy my app using Fly.io. When I run the command flyctl deploy --remote-only, I get the following error:

Error: Failed to fetch an image or build from source: error building: was unable to solve: process "/bin/sh -c npm install --omit=dev" did not complete successfully: exit code: 1

It seems like the deployment process is failing at the npm install --omit=dev step. I've checked my package.json and Dockerfile, and everything looks correct to me.

I've tried searching for solutions but haven't found anything that resolves this issue. Has anyone encountered a similar problem or have any suggestions on how to fix it?

Accepted Solution (1)
Jitali_2103
Shopify Partner
34 1 2

This is an accepted solution.

Remove the npm package: '@shopify/polaris-icons' 

Use another package instead of this.

This worked for us, I hope this will help you too.

View solution in original post

Replies 7 (7)

AlexOpr
Shopify Partner
3 0 0

Hi @Jitali_2103 ,

Could it be that you don't have npm installed on your docker container? Is your image based on node:alpine or are you using some linux distro and you're installing it manually?

Co-Founder at Poldero: https://apps.shopify.com/poldero-notifications
Jitali_2103
Shopify Partner
34 1 2

Hi @AlexOpr ,

For this, I have found a solution.
Thanks for sharing the solution with me.

Divya
Shopify Partner
10 0 1

May I know the solution? Because I'm facing the same issue

Jitali_2103
Shopify Partner
34 1 2

Hi @Divya ,

 

Can you please share a snapshot of that issue?

Divya
Shopify Partner
10 0 1

Screenshot 2024-07-10 121420.png

Jitali_2103
Shopify Partner
34 1 2

This is an accepted solution.

Remove the npm package: '@shopify/polaris-icons' 

Use another package instead of this.

This worked for us, I hope this will help you too.

Divya
Shopify Partner
10 0 1

It worked, thank you!