Customizable maintenance mode
composer require nearata/flarum-ext-maintenance-mode:"*"
composer update nearata/flarum-ext-maintenance-mode:"*"
php flarum cache:clear
composer remove nearata/flarum-ext-maintenance-mode
php flarum cache:clear
Switch the Maintenance Mode
in the extension settings page.
php flarum nearataMaintenanceMode:toggle <true or false>
PATCH /api/nearata/maintenanceMode/enabled
{
"value": true or false
}
if the body is empty, it will be evaluated as false.
An empty response is returned either way.
To change the style of the page, there's no other way but to override the file itself.
Follow the below link to see a how-to:
https://docs.flarum.org/extend/views/#overriding-views
If you have permissions to bypass the maintenance mode, you can run the below command to generate a link to login in a authorized user.
Assure you are in the Flarum root folder
:
php flarum nearataMaintenanceMode:auth <user_id>
- If the database is inaccessible, this situation is not handled.