/LogManager

An interface to preview, download and delete Laravel log files, using Backpack.

Primary LanguagePHPOtherNOASSERTION

Backpack\LogManager

Latest Version on Packagist Software License Build Status Coverage Status Quality Score Style CI Total Downloads

An interface to preview, download and delete Laravel log files.

Security updates and breaking changes

Please subscribe to the Backpack Newsletter so you can find out about any security updates, breaking changes or major features. We send an email every 1-2 months.

Install

  1. Install via composer:
$ composer require backpack/logmanager
  1. Then add the service provider to your config/app.php file:
    Backpack\LogManager\LogManagerServiceProvider::class,
  1. Add a "storage" filesystem in config/filesystems.php:
// used for Backpack/LogManager
'storage' => [
            'driver' => 'local',
            'root'   => storage_path(),
        ],
  1. [Optional] Configure Laravel to create a new log file for every day, in your .ENV file, if it's not already. Otherwise there will only be one file at all times.
    APP_LOG=daily

or directly in your config/app.php file:

    'log' => env('APP_LOG', 'daily'),
  1. [Optional] Publish the lang files if you think you'll need to modify them.
    php artisan vendor:publish --provider="Backpack\LogManager\LogManagerServiceProvider"
  1. [optional] Add a menu item for it in resources/views/vendor/backpack/base/inc/sidebar.blade.php or menu.blade.php:
<li><a href="{{ url(config('backpack.base.route_prefix', 'admin').'/log') }}"><i class="fa fa-terminal"></i> <span>Logs</span></a></li>

Usage

Add a menu element for it or just try at your-project-domain/admin/log

LogManager interface

Change log

Please see CHANGELOG for more information what has changed recently.

Testing

$ composer test

Contributing

Please see CONTRIBUTING for details.

Overwriting Functionality

If you need to modify how this works in a project:

  • create a routes/backpack/logmanager.php file; the package will see that, and load your routes file, instead of the one in the package;
  • create controllers/models that extend the ones in the package, and use those in your new routes file;
  • modify anything you'd like in the new controllers/models;

Security

If you discover any security related issues, please email :author_email instead of using the issue tracker.

Please subscribe to the Backpack Newsletter so you can find out about any security updates, breaking changes or major features. We send an email every 1-2 months.

Credits

License

Backpack is free for non-commercial use and $19/project for commercial use. Please see License File and backpackforlaravel.com for more information.