How do I deploy Laravel app on any hosting service with Vue in frontend?
Hey guys, I would like to know how to deploy a web app with Laravel as the backend framework and Vue as frontend and mysql as database. I do not want to use Laravel Forge or Vapor since they cost a premium. Is there any other way? Like deploying on Heroku or AWS or Azure?
I have surfed the net and there is not on tutorial that explains how to deploy the same. It's tough and it is urgent. Kindly suggest me some methods!
If you use Laravel Forge it allows you to run npm when you deploy the code from GitHub.
If you have SSH access to the server then you just login and do like what @cookie_good has posted but if its production then its npm run prod.
If you run npm run prod before pushing your code up to the server then it will just work. One issue I did have previously was that the changes I made didn't reflect on the production server, but was due to chrome caching the js and css, so just remember to clear the cache.