every time I run "npm run deploy:development" I get this:
MacBook-Pro:frontend eug$ npm run deploy:development
> app-frontend#0.1.0 deploy:development /Users/eugenebv/Documents/PetHotel/frontend
> firebase use development && cross-env REACT_APP_ENVIRONMENT=development npm run build && firebase deploy --only hosting,storage
sh: firebase: command not found
npm ERR! code ELIFECYCLE
npm ERR! syscall spawn
npm ERR! file sh
npm ERR! errno ENOENT
npm ERR! app-frontend#0.1.0 deploy:development: `firebase use development && cross-env REACT_APP_ENVIRONMENT=development npm run build && firebase deploy --only hosting,storage`
npm ERR! spawn ENOENT
npm ERR!
npm ERR! Failed at the app-frontend#0.1.0 deploy:development script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.
I have firebase and firebase-tools installed, although i see "firebase: command not found".
I ran the alias command to set firebase, whenever I run any firebase command, it works.
Related
I'm trying to deploy my backend application on cpanel and I'm getting an error like this
what should i do to solve this problem?
> test3#0.0.1 start /home/nandaken/inventory
> nest start
stderr:
npm WARN lifecycle The node binary used for scripts is /home/nandaken/nodevenv/inventory/12/bin/node but npm is using /opt/alt/alt-nodejs12/root/usr/bin/node itself. Use the `--scripts-prepend-node-path` option to include the path for the node binary npm was executed with.
sh: nest: command not found
npm ERR! code ELIFECYCLE
npm ERR! syscall spawn
npm ERR! file sh
npm ERR! errno ENOENT
npm ERR! test3#0.0.1 start: `nest start`
npm ERR! spawn ENOENT
npm ERR!
npm ERR! Failed at the test3#0.0.1 start script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.
npm ERR! A complete log of this run can be found in:
npm ERR! /home/nandaken/.npm/_logs/2023-01-28T08_16_43_494Z-debug.log
Looks like cpanel is calling the startscript which is running nest start. More than likely, you only have production dependencies installed, so #nestjs/cli isn't installed because it is a devDependency. Either configure cpanel to call a different start script (like start:prod which should map to node dist/main) or change your start script to run the proper js file (like node dist/main). The other option would be to install #nestjs/cli as a production dependency, but I wouldn't suggest that
I am encountering a problem when trying to run the Plutus Playground through Nix on MacOS.
I tried using the last available tag v2021-12-20, but I am getting the following error when I try to run the Plutus Playground Client in nix-shell:
nix-shell:~/cardano/plutus-apps/plutus-playground-client]$ npm run start
> plutus-playground-client#1.0.0 start /Users/matt/cardano/plutus-apps/plutus-playground-client
> plutus-playground-generate-purs && npm install && npm run install:spago && npm run build:webpack:dev
/nix/store/2nr8xfy3zqdgxfmxlc3r48gijfdwbnrf-plutus-playground-generate-purs/bin/plutus-playground-generate-purs: line 6: /bin/plutus-playground-server: No such file or directory
npm ERR! code ELIFECYCLE
npm ERR! syscall spawn
npm ERR! file sh
npm ERR! errno ENOENT
npm ERR! plutus-playground-client#1.0.0 start: `plutus-playground-generate-purs && npm install && npm run install:spago && npm run build:webpack:dev`
npm ERR! spawn ENOENT
npm ERR!
npm ERR! Failed at the plutus-playground-client#1.0.0 start script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.
npm ERR! A complete log of this run can be found in:
npm ERR! /Users/matt/.npm/_logs/2021-12-20T18_27_49_943Z-debug.log
It seems similar to Plutus Playground Client cannot run, but I couldn't find anything to help run it.
My Nix config:
uild-users-group = nixbld
substituters = https://hydra.iohk.io https://iohk.cachix.org https://cache.nixos.org/
trusted-public-keys = hydra.iohk.io:f/Ea+s+dFdN+3Y/G+FDgSq+a5NEWhJGzdjvKNGv0/EQ= iohk.cachix.org-1:DpRUyj7h7V830dp/i6Nti+NEO2/nhblbov/8MW7Rqoo= cache.nixos.org-1:6NCHdD59X431o0gWypbMrAURkbJ16ZPMQFGspcDShjY=
sandbox = false
system = x86_64-darwin
extra-platforms = x86_64-darwin aarch64-darwin
I am running it on an M1 Mac.
when i clicked the npm run service. This error is what i am getting
I have used the same app in the following link:
https://github.com/valnub/f7-node-autocomplete-search-demo
framework7-react-app-template#3.0.0 service C:\Users\Tallam Tharun Sai\auto-complete
PORT=3001 nodemon service/service.js
'PORT' is not recognized as an internal or external command,
operable program or batch file.
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! framework7-react-app-template#3.0.0 service: `PORT=3001 nodemon service/service.js`
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the framework7-react-app-template#3.0.0 service script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.
npm ERR! A complete log of this run can be found in:
npm ERR! C:\Users\Tallam Tharun Sai\AppData\Roaming\npm-cache\_logs\2020-07-10T18_16_54_175Z-debug.log
The answer for this is.
I have deleted the Package.json and Node modules from the project and again followed the steps to install the npm as (npm install).
Then I have the installed my npm app successfully.
In my project, I use Parcel to bundle everything. Now, I am at the point where I need to deploy my app.
I clone my git repo with my React app and I put in the Node server.
I tried every command possible to install parcel, but I always get the following error :
> pp-react#0.1.0 build /home/volodymk/react
> parcel build index.html
sh: parcel: command not found
npm ERR! code ELIFECYCLE
npm ERR! syscall spawn
npm ERR! file sh
npm ERR! errno ENOENT
npm ERR! pp-react#0.1.0 build: `parcel build index.html`
npm ERR! spawn ENOENT
npm ERR!
npm ERR! Failed at the pp-react#0.1.0 build script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.
npm ERR! A complete log of this run can be found in:
npm ERR! /home/volodymk/.npm/_logs/2020-01-12T19_26_22_634Z-debug.log
How can I fix this ?
To run any installed node package (not just Parcel), use npx, the utility command shipped with npm. It executes packages that come with a runtime command in your node_modules/packagename/.bin directories.
As in npx parcel build index.html
More information available in the npx readme.
I am using Mac. I have tried to read and implement the solution from this thread, but it doesnt work.
Firebase deploy errors starting with non-zero exit code (space in project path)
I get errors when deploying the code to firebase:
i deploying functions Running command: npm --prefix "%RESOURCE_DIR%"
run lint npm ERR! path
/Users/muchammadagunglaksana/Desktop/tsCobaDoangCloudFunction/%RESOURCE_DIR%/package.json
npm ERR! code ENOENT npm ERR! errno -2 npm ERR! syscall open npm ERR!
enoent ENOENT: no such file or directory, open
'/Users/muchammadagunglaksana/Desktop/tsCobaDoangCloudFunction/%RESOURCE_DIR%/package.json'
npm ERR! enoent This is related to npm not being able to find a file.
npm ERR! enoent
npm ERR! A complete log of this run can be found in: npm ERR!
/Users/muchammadagunglaksana/.npm/_logs/2018-09-07T09_10_49_146Z-debug.log
Error: functions predeploy error: Command terminated with non-zero
exit code254
in firebase.json I have tried to modify and use:
"npm --prefix \"%RESOURCE_DIR%\" run lint"
but i still get the error message like the picture above, what should I do?
%RESOURCE_DIR% is a Windows syntax. You should use $RESOURCE_DIR as you are on Mac.
reinitialize your project
firebase init