Home
Support Forums

Deploy failed issue occur when we deploy viue js

Hi,

Can you please help me out when we are trying to deploy my application (Viue Js) in Netlify but we got build failed issue:

1:26:02 AM: ────────────────────────────────────────────────────────────────
1:26:02 AM: “build.command” failed
1:26:02 AM: ────────────────────────────────────────────────────────────────
1:26:02 AM: ​
1:26:02 AM: Error message
1:26:02 AM: Command failed with exit code 127: rm -rf embed && yarn build
1:26:02 AM: ​
1:26:02 AM: Error location
1:26:02 AM: In build.command from netlify.toml:
1:26:02 AM: rm -rf embed && yarn build
1:26:02 AM: ​
1:26:02 AM: Resolved config
1:26:02 AM: build:
1:26:02 AM: base: /opt/build/repo/embed
1:26:02 AM: command: rm -rf embed && yarn build
1:26:02 AM: commandOrigin: config
1:26:02 AM: publish: /opt/build/repo/embed/dist
1:26:02 AM: functions:
1:26:02 AM: '’: {}
1:26:02 AM: redirects:
1:26:02 AM: - conditions: {}
1:26:02 AM: force: false
1:26:02 AM: headers: {}
1:26:02 AM: path: /

Build command I have used “npm run build” and “npm run-script build” .

Please suggest what is wrong here.

Hi @Arpit1

Welcome to the Netlify community :netliconfetti:

You say you have used

but the command in the log is

What is in you package.json under scripts? Are you using a netlify.toml with a build command?

Hi Coelmay,

Thanks for your response. Please find the below Package.json script section
image

Do I need to modify anything in package.json ?

Also do I need to create netlify.toml file? Also what we can pull here and what is the process for deployment.

In your netlify.toml you are using rm -rf embed && yarn build

Try removing the rm -rf embed && from this.

No still I am not using netlify.toml

Your build log says you are using netlify.toml

But as per the Git Repo I am not using netlify.toml file

image

I am not sure where the rm -rf embed && yarn build command is coming from then. But that is the command that caused the build to fail.

I have search entire repo with this cmd rm -rf embed && yarn build but not found what I need to do her please help me out ?

or is there any setting netlify ?

Check https://app.netlify.com/sites/<your-site-name>/settings/deploys under Build settings.

image

Please help me out I need to deploy my application in Netlify

I’m not to add anything more at this point. Hopefully someone from the community or staff are able to cast a fresh set of eyes over this and provide you with further assistance.

@Arpit1 Can you try removing the package-lock.json file from your repo.

I have tried to delete the package-lock.json file but same issue still occur when we are trying to hit build

hi arpit, can you please post a screenshot of your current build settings, in the UI, and your package.json file please? Lets ignore the netlify.toml for now.

Hi Perry ,

Thanks for your response, current build setting in UI package .json

“name”: “embed”,
“version”: “0.1.0”,
“private”: true,
“scripts”: {
“serve”: “vue-cli-service serve”,
“build”: “vue-cli-service build”
},

till now I am not using any netlify.toml. Please help me out how we can run through Netlify build.

arpit, can you please post a screenshot of your current build settings from the netlify UI/dashboard? thanks.