DEV Community

Morcos Gad
Morcos Gad

Posted on

Laravel Maintenance Mode

Let's put our app into maintenance mode

php artisan down
Enter fullscreen mode Exit fullscreen mode

Let's make it load continuously every 15 seconds to make sure it's still in maintenance mode

php artisan down --refresh=15
Enter fullscreen mode Exit fullscreen mode

use the secret option to specify a maintenance mode bypass token:

php artisan down --secret="1630542a-246b-4b66-afa1-dd72a4c43515"
https://example.com/1630542a-246b-4b66-afa1-dd72a4c43515
Enter fullscreen mode Exit fullscreen mode

To disable maintenance mode

php artisan up
Enter fullscreen mode Exit fullscreen mode

To find out more, see
https://laravel.com/docs/8.x/configuration#maintenance-mode
I hope you enjoy the code.

Top comments (0)

Some comments may only be visible to logged-in visitors. Sign in to view all comments.