I have a:
- VPS with LAMP stack
- local symfony2 project (git)
- bitbucket repository
What do I need to do to properly setup my project in the production evironment?
Can I simply clone the repository in the public folder? (I don't think so)
P.s. I've already read the deployment guide on the symfony2 website, but I didn't find it very useful
Best How To :
Here are my deployment steps:
- git clone project
- go to project directory
- php composer.phar install (and if composer is not in the project directory curl -sS https://getcomposer.org/installer | php)
- app/console doctrine:database:create
- app/console schema:update --force
- app/console assets:install web --symlink
- chmod 777 -R app/cache app/logs web/media/cache (I often use liip imagine, it resizes photo in web/media/cache)
- point the virtual host of apache to the web directory of my project. And you are done.
you might want to enable mode rewrite in apach (a2enmod rewrite) I think this covers everything.