I'm wondering how's the best way to work with Symfony2 when you have several projects sharing common bundles.
In my case, all bundles are private and will continue being, and each project will be in different servers.
The three project have their own bundles, and a others in common. In my case, the CoreBundle contains the model and business logic.
Our team has 4 members, and all of us will be continuously updating it.
In Symfony 1.4, you could split it easily creating one application per project inside the apps folder.
In Symofny 2, it's not recommended to "adapt" it that way (https://groups.google.com/forum/?fromgr ... neojUuFiqw)
The approaches we found are:
a) All in the same project. One app.php and AppKernel.php. In the routing.yml, we specify routes with subdomains per each project.
The AppKernel loads all bundles always. Problem: Unnecessary bundles loading.
b) All in the same project, but creating different entry points: app_front.php and app_back.php.
http://jolicode.com/blog/multiple-appli ... h-symfony2
https://github.com/damienalexandre/symf ... s-2.2/apps
c) Using https://github.com/vbardales/MultipleAppKernelBundle is quite similar to the previous point
d) Each bundle with his own repository. Each project install the common bundles using git submodules in the src folder
e) All commond bundles in the same repository. Each project, through symlinks, include the bundles he needs.
f) Use Satis to share the bundles between the projects. Bundles will be installed with composer in vendor/companyName folder.
Each time a user modifies a common bundle, he must go inside the bundle folder (to access to its git repository), and make the git push
git add . && git commit ... && git push origin develop
Then, in GitHub, we configured a hook, so that each time it receive a "push event", it calls a script we have in the Satis Repository Server, to recreate the build (the packages git revision, etc).
Then, per each project (api, backed and frontend), run the composer update command.
cd api && composer update myComparny/CoreBundle && git add composer.lock && git push origin develop
cd frontend && composer update myComparny/CoreBundle && git add composer.lock && git push origin develop
cd backend && composer update myComparny/CoreBundle && git add composer.lock && git push origin develop
Then, when another team member wants to get my changes, he will have to:
cd api && git pull origin develop && composer install
cd frontend && git pull origin develop && composer install
cd backend && git pull origin develop && composer install
What would you recommend me to do? Did you ever have to face this situation?
Thanks in advanced