简体   繁体   中英

How I can install and configure an existing Laravel Project? (Laravel 4)

I need to install and configure an existing Laravel 4 project.

I tried to do, but when I ran composer update or composer install a lot of issues appear.

I have the database too (with data) so I ran the migration but doesn't work because the console show me an issue about the "table doesn't exist".

Can anyone tell me the complete process to configure the App?.

I mean, what its first, second and so and so because maybe in some step I made a mistake

To install and configure an existing project, you'd typically

  1. Check out its source code

  2. Run composer install

  3. Run php artisan migrate

  4. Check the README for specific instructions on installing 3rd party assets, or any additional steps you'd need to take

If the above creates errors, its either because of something in your environment (installing over an old project?) or some problem with the way the Laravel developer created their project.

Carlos, when using an existing DB you'll need to check the migrations table to see which migrations have run successfully. Typically when taking over a laravel project setting up a new db and running the migrations against it is a good idea because you never know what hacks were made to the database outside the migration system. One small change can throw the entire system into a useless state because it's looking for a table or column that doesn't exist or has been modified. If you run the migrations against a bare db you can also figure out which tables were manually created (which could very well be your issue) outside the system and add them in as necessary. Cobbling things together after a previous developer is tedious, hopefully there is decent documentation.

To install and configure an existing project, you'd typically check those things first :

  1. You should goto app/config/database.php check file and verify username and password.
  2. After check in Project Folder vendor folder and composer.json file exist then remove it (that remove old configuration now we going to fresh configuration).
  3. Then after back to command prompt and fire command composer update and that download some dependent file download.
  4. Now Run php artisan serve

that tricks work for me last time when I migrate another host.

Note that if you are using Git with .gitignore , don't forget to copy .env variables in new location too.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM