Back

Deploying Laravel: Does it have to be so hard? Will this idea work?


sazr posted 2 years ago

We're in the stages of deploying/redeploying a Laravel project and its quite hard and complex. I'm thinking of making an easier way to setup our Laravel project on the server. Essentially it's just to change the /home/user/public_html to a symbolic link. So now /home/user/public_html really points to /home/user/MyLaravelProject/public.

This way deploying a Laravel project simply involves uploading the project to a new folder and creating the symbolic link (aswell as the standard composer and artisan commands). And updating a Laravel project means we don't have to constantly copy our front-end files into /home/user/public_html whenever we make a change.

This way we don't need to change the paths in the bootstrap/app.php, public/index.php, etc. files.

Has anyone done this or know if it will work? Any ideas why this wont work? Any tutorials out there that walk us through this?

Relevant information about our server:

  • CentOS 7
  • VPS
  • With GoDaddy
  • Setup by previous developers rather badly
Amstaff replied 2 years ago

And updating a Laravel project means we don't have to constantly copy our front-end files into /home/user/public_html whenever we make a change.

This way we don't need to change the paths in the bootstrap/app.php, public/index.php, etc. files.

Why do u need to change all when you only modified some, I recomend use git.


Sign in to participate in this thread!



We'd like to thank these amazing companies for supporting us