Zalo
564
5
Forge

NPM run prod in Forge

Posted 1 month ago by Zalo

Hello all! I'm having a weird issue about deploying an app in Forge. I'm using a simple deploying script, with typical Laravel setup:

php artisan down
git pull
composer install
php artisan migrate
npm install
etc.

At the end, I have:

npm run prod
php artisan up

Here is the problem I guess. It take too long to complete the compilation 197950ms (thats is normal?), showing a 'compiled successfully' message, but, immediately after, it shows an error:

npm-prod

I dont know whats happening there. It compiles correctly but Forge assumes it finished with incorrect state, blowing up all my deploying script :( making impossible to execute php artisan up.

Any tip? Thx!

Please sign in or create an account to participate in this conversation.