Skip to content

Commit

Permalink
Adds maintenance support check
Browse files Browse the repository at this point in the history
  • Loading branch information
octoberapp committed Jan 22, 2023
1 parent 9258f0b commit 0223a09
Showing 1 changed file with 21 additions and 7 deletions.
28 changes: 21 additions & 7 deletions beacon/templates/app/index.stub
Original file line number Diff line number Diff line change
@@ -1,11 +1,27 @@
<?php

/**
* October - The PHP platform that gets back to basics.
* October CMS - a Laravel-based platform engineered for simplicity.
*
* @package october/october
* @author Alexey Bobkov, Samuel Georges
*/

/*
|--------------------------------------------------------------------------
| Check If The Application Is Under Maintenance
|--------------------------------------------------------------------------
|
| If the application is in maintenance / demo mode via the "down" command
| we will load this file so that any pre-rendered content can be shown
| instead of starting the framework, which could cause an exception.
|
*/

if (file_exists($maintenance = __DIR__ . '/storage/framework/maintenance.php')) {
require $maintenance;
}

/*
|--------------------------------------------------------------------------
| Load deployment beacon
Expand All @@ -26,7 +42,7 @@ require __DIR__.'/bootstrap/beacon.php';
|
*/

require __DIR__.'/bootstrap/autoload.php';
require __DIR__ . '/bootstrap/autoload.php';

/*
|--------------------------------------------------------------------------
Expand All @@ -37,7 +53,7 @@ require __DIR__.'/bootstrap/autoload.php';
|
*/

$app = require_once __DIR__.'/bootstrap/app.php';
$app = require_once __DIR__ . '/bootstrap/app.php';

/*
|--------------------------------------------------------------------------
Expand All @@ -51,9 +67,7 @@ $app = require_once __DIR__.'/bootstrap/app.php';
$kernel = $app->make(\Illuminate\Contracts\Http\Kernel::class);

$response = $kernel->handle(
$request = Illuminate\Http\Request::capture()
);

$response->send();
$request = \Illuminate\Http\Request::capture()
)->send();

$kernel->terminate($request, $response);

0 comments on commit 0223a09

Please sign in to comment.