1<?php
2
3// Copyright (c) ppy Pty Ltd <contact@ppy.sh>. Licensed under the GNU Affero General Public License v3.0.
4// See the LICENCE file in the repository root for full licence text.
5
6namespace App\Console\Commands;
7
8use Illuminate\Console\Command;
9
10class DbSetup extends Command
11{
12 protected $signature = 'db:setup {--force}';
13
14 protected $description = 'Create empty databases and run migrations. This does not initialise elasticsearch indexes';
15
16 public function handle()
17 {
18 $this->call('db:create');
19 $this->call('migrate', [
20 '--force' => $this->option('force'),
21 ]);
22 }
23}