Heimdall/app/Providers/AppServiceProvider.php

34 lines
679 B
PHP
Raw Normal View History

2018-01-26 14:35:01 +00:00
<?php
namespace App\Providers;
use Illuminate\Support\ServiceProvider;
class AppServiceProvider extends ServiceProvider
{
/**
* Bootstrap any application services.
*
* @return void
*/
public function boot()
{
2018-01-29 20:14:40 +00:00
if(!file_exists(database_path(env('DB_DATABASE')))) {
// first time setup
//die("No Database");
touch(database_path(env('DB_DATABASE')));
\Artisan::call('migrate', array('--path' => 'app/migrations', '--force' => true));
}
2018-01-26 14:35:01 +00:00
}
/**
* Register any application services.
*
* @return void
*/
public function register()
{
//
}
}