35 lines
705 B

7 years ago
<?php
namespace App\Providers;
use Illuminate\Support\ServiceProvider;
use Artisan;
7 years ago
class AppServiceProvider extends ServiceProvider
{
/**
* Bootstrap any application services.
*
* @return void
*/
public function boot()
{
7 years ago
if(!file_exists(database_path(env('DB_DATABASE')))) {
// first time setup
touch(database_path(env('DB_DATABASE')));
Artisan::call('migrate', array('--path' => 'database/migrations', '--force' => true));
Artisan::call('storage:link');
7 years ago
}
7 years ago
}
/**
* Register any application services.
*
* @return void
*/
public function register()
{
//
}
}