i'm have worked with laravel 3 in the past and used a project structure where multiple apps could use one installation of the framework. now in laravel 4 i am concered if that is still possible. since the bootstrap/autoload.php
file requires the vendor/autoload.php
file (and so on...), different apps have to use the same autoload files from within the vendor directory, right? i think this would be a big performance problem because the different apps maybe have different requirements, different models to work with and so on. am i thinking right or is there a chance to use one /vendor/
installation for multiple apps without the need to share the autoload files?
to explain my needs: i would like to run different apps (every app with another domain & home directory) which share one database and some models. but the requirements of every app will be very different.
is there any solution? i tried this since the release but found no practicable way.
First, run your first Laravel project blog as follows: Open your command prompt and go to your drive where your Laravel project exists. Now type http://localhost:8000 in the browser and your blog project will run. Now go to your browser and type http://localhost:8080 in your browser your another project will also run.
Have you tried http://laravel.com/docs/routing#sub-domain-routing?
You could create a route group and assign a filter function to that route group to do specific autoloads?
How about modifying bootstrap/autoload.php
and vendor/autoload.php
to load autoload stuff per project to some kind of sub-directory structure under vendor/composer/
.
Not sure, how to change composer to generate that kind of project specific autoload directories. Maybe it needs changing composer?
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With