Download the PHP package tarique/laravel-app-monitor without Composer
On this page you can find all versions of the php package tarique/laravel-app-monitor. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.
Download tarique/laravel-app-monitor
More information about tarique/laravel-app-monitor
Files in tarique/laravel-app-monitor
Package laravel-app-monitor
Short Description A Laravel package to monitor application downtime and server errors, and send email notifications
License MIT
Homepage https://github.com/tariquedev/laravel-app-monitor
Informations about the package laravel-app-monitor
Laravel App Monitor
Laravel App Monitor is a package designed to monitor specific HTTP errors in your Laravel application and notify administrators via email. It helps ensure that critical errors (like 500, 502, 503, 504, 413) are promptly reported, allowing administrators to take appropriate action.
Installation
You can install the Laravel App Monitor package via Composer. Run the following command in your terminal:
Publish Configuration
To customize settings such as email recipients or error notifications, publish the configuration file:
This will copy the configuration file to config/appmonitor.php
and app\Jobs\SendMonitorErrorNotification.php
.
Environment Configuration
Set the email address where notifications should be sent in your .env
file:
Make sure to replace [email protected]
with the appropriate email address.
Usage
Laravel App Monitor automatically detects and handles specific HTTP errors. Here's how you can use it effectively:
Enable Error Notifications
Ensure that error notifications are enabled in the config/appmonitor.php
file:
Customize Email Template (Optional)
If you want to customize the email template used for error notifications, you can publish the default template:
This will copy the default email template to resources/views/vendor/appmonitor/error_email.blade.php
, where you can modify it to suit your needs.
Configure Queue (Optional)
To avoid delaying frontend responses due to email sending, you can configure Laravel queues. Set the queue connection in your .env
file:
If you are using QUEUE_CONNECTION as a database you should
Run the migration to create the jobs table:
Start the queue worker to process jobs asynchronously:
Support
If you encounter any issues or have questions about using Laravel App Monitor, please open an issue on GitHub or contact the package maintainer directly.
License
Laravel App Monitor is open-source software licensed under the MIT license.