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:
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.
I tried, but same error is throwed... It really weird. And its only happening in my dev server. In Production its working fine (after 94629ms building time). Hmmmm
Well, finally I found the solution. Its was about AWS machine... In Development It was a 'micro' instance, so increasing to a bigger one fixed the npm run prod problem.
A micro instance only have 1GB of RAM and that was not enough for compiling assets :)