From 2bf8c8e90c89058b56a7488828b700f9bac68c2f Mon Sep 17 00:00:00 2001 From: Miguel Nogueira Date: Thu, 9 Jul 2020 05:06:25 +0100 Subject: [PATCH] Enable maintenance mode during installation --- app/Console/Commands/Install.php | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/app/Console/Commands/Install.php b/app/Console/Commands/Install.php index 06329cb..4381f87 100644 --- a/app/Console/Commands/Install.php +++ b/app/Console/Commands/Install.php @@ -47,6 +47,9 @@ class Install extends Command $this->info('[!! Welcome to Rasberry Teams !!]'); $this->info('>> Installing...'); + $this->call('down', [ + '--message' => 'Down for maintenance. We\'ll be right back!' + ]); copy($basePath . '/.env.example', $basePath . '/.env'); Artisan::call('key:generate'); @@ -58,7 +61,7 @@ class Install extends Command $npmBuild = new Process('npm run dev', $basePath); - $this->info('>> Installing and preparing dependencies...'); + $this->info('>> Installing and preparing dependencies. This may take a while, depending on your computer.'); $progress = $this->output->createProgressBar(3); try @@ -137,6 +140,8 @@ class Install extends Command $this->call('config:cache'); touch($basePath . '/INSTALLED'); + + $this->call('up'); $this->info('>> All done! Visit ' . $baseURL . ' to start using your brand new installation of Raspberry Teams!'); }