Hey Panoply
I'm also new to Laravel, so i'm just trying to give you answers out of my mind, please correct me if i'm wrong.
Let me know if i was helpful in some way :)
Have a nice day!
Thanks for your response. I might take the git option and if you could clarify, the upload would include my vender folder?
Yes, include everything, even the vendor folder :)
Have a nice day!
Pushing your vendor folder is not good practice. Your vendor folder contains repository code which is frequently updated and improved. For that reason you should always try to keep it out of your git repo and run composer update
on your production server instead. You'll also save a lot of time when pulling a repo without the vendor folder.
A good approach is to write a small deployment-script together with environment-specific configurations. The goal is to pull in the latest changes from your git repository without breaking your site.
An example of such a script would be something like this; Pastebin - 6oPE (not tested).
Create a new file on your webserver, name it "deploy" and do chmod +x deploy
. Use it like this;
// First run, which clones the repository
$ php deploy first-run
// Now, this should be executed whenever there are changes in your repo
$ php deploy
Now, if you create environment-specific configuration files, this would be your workflow;
$ php deploy
Remember to put your /vendor folder back in .gitignore.
I did upload them (project folder in locals) all to shared host. I cut things inside public folder and paste them on the same lavel as app folder.
this needs to change a default configuration , config/paths.php
you can develop locally and push it to production using FTP via some ID like Phpstrom notepad++ etc.
here's my site : http://codetrash.com for example
Thanks to ChrisRM, nice way to handle deployment, will surely test it out!
I would suggest something like mina (https://github.com/nadarei/mina) for deployments. You should never run composer update in your production environment, only composer install. You don't want new, untested, versions of libs in production that you haven't used in development. And composer update requires a lot of memory to run.
I had the same question here: http://laravel.io/forum/03-26-2014-best-practice-to-deploy
Now using Rocketeer and i'm very happy with it.
sorry, but how do I access my webapp after I do all these rocketeer configs. ?
In addition to this, www.deployhq.com can simplify deployment. Deploying over SFTP, they allow you to integrate to your repository, reverse deployments and preview deployments. It's a great little service. I don't use FTP at all anymore, only for real legacy sites, it's always SFTP.
Sign in to participate in this thread!
The Laravel portal for problem solving, knowledge sharing and community building.
The community