feat: update documentation

This commit is contained in:
smokills 2020-09-30 18:33:31 +02:00
parent 70790933e1
commit 31159258cb

View file

@ -17,6 +17,8 @@ This package is a wrapper bridging [jimdo/prometheus_client_php](https://github.
composer require superbalist/laravel-prometheus-exporter composer require superbalist/laravel-prometheus-exporter
``` ```
## Laravel
Register the service provider in app.php Register the service provider in app.php
```php ```php
'providers' => [ 'providers' => [
@ -33,6 +35,19 @@ Register the facade in app.php
] ]
``` ```
## Lumen
Register the service provider in boostrap/app.php
```php
$app->register(Superbalist\LaravelPrometheusExporter\PrometheusServiceProvider::class);
```
If you want to register the facade, in boostrap/app, replece the line with `$app->withFacades();` with the following:
```php
$app->withFacades(true, [
Superbalist\LaravelPrometheusExporter\PrometheusFacade::class => 'Prometheus',
]);
```
## Configuration ## Configuration
The package has a default configuration which uses the following environment variables. The package has a default configuration which uses the following environment variables.