Report errors by mail while ignoring repeating ones.
adwiv/laravel-error-mailer is a Laravel package for report errors by mail while ignoring repeating ones..
It currently has 1 GitHub stars and 30 downloads on Packagist (latest version 0.9.3).
Install it with composer require adwiv/laravel-error-mailer.
Discover more Laravel packages by adwiv
or browse all Laravel packages to compare alternatives.
Last updated
Package to report laravel errors by email with throttling and deduplication.
composer require adwiv/laravel-error-mailer
error_logs table.php artisan migrate
# Required Key
ERROR_MAILER_TO = "[email protected],[email protected]" # Comma separated list of email addresses
# Optional Keys
ERROR_MAILER_FROM = "[email protected]" # Mail sender, if not defined defaults to config setting
ERROR_MAILER_REPEAT_AFTER = 300 # Time in seconds for which same error will not be reported again
ERROR_MAILER_HOURLY_LIMIT = 10 # Maximum number of error mails that will be sent in an hour
config/logging.php. The package automatically adds a logging channel named error-mailer.The simplest way to use it is to add it the stack channel.
'channels' => [
'stack' => [
'driver' => 'stack',
'channels' => ['single', 'error-mailer'], #<-- Add here
'ignore_exceptions' => false,
],
...
],
Thats all. Any errors should now be reported to all the email addresses listed in ERROR_MAILER_TO environment option.
If mails are not being recieived, please check:
ERROR_MAILER_TO variable is defined in .env file and has valid email addresses (without spaces)