Ecosyste.ms: Awesome

An open API service indexing awesome lists of open source software.

Awesome Lists | Featured Topics | Projects

https://github.com/eusonlito/laravelpulsedatabasetablessize

A Laravel Pulse card to show Database Tables Size
https://github.com/eusonlito/laravelpulsedatabasetablessize

Last synced: 6 days ago
JSON representation

A Laravel Pulse card to show Database Tables Size

Awesome Lists containing this project

README

        

# DatabaseTablesSize card for Laravel Pulse

This card will show you database tables size.

![Screenshot from 2024-02-05 13-43-42](https://github.com/eusonlito/LaravelPulseDatabaseTablesSize/assets/644551/21f71ca7-019a-41c4-a148-f5e28c9d86c2)

## Installation

Require the package with Composer:

```shell
composer require eusonlito/laravel-pulse-database-tables-size:dev-master
```

## Register the recorder

```diff
return [
// ...

'recorders' => [
+ \EuSonLito\LaravelPulse\DatabaseTablesSize\Recorders\DatabaseTablesSizeRecorder::class => [
+ 'enabled' => env('PULSE_DATABASE_TABLES_SIZE_ENABLED', true),
+ 'schedule' => env('PULSE_DATABASE_TABLES_SIZE_SCHEDULE', 60), // refresh time in minutes
+ 'connections' => [env('DB_CONNECTION', 'mysql')],
+ 'ignore' => [
+ '#^/pulse$#', // Pulse dashboard...
+ ],
+ ],
]
]
```

You also need to be running [the `pulse:check` command](https://laravel.com/docs/10.x/pulse#dashboard-cards).

## Add to your dashboard

To add the card to the Pulse dashboard, you must first [publish the vendor view](https://laravel.com/docs/10.x/pulse#dashboard-customization).

Then, you can modify the `dashboard.blade.php` file:

```diff

+

```

That's it!