2016-08-08 04:56:19 -05:00
|
|
|
<?php
|
2019-11-30 02:28:09 -06:00
|
|
|
|
2018-11-24 02:29:51 -06:00
|
|
|
declare(strict_types=1);
|
|
|
|
|
2022-06-04 01:59:17 -05:00
|
|
|
use Monolog\Level;
|
|
|
|
use Shlinkio\Shlink\Common\Logger\LoggerType;
|
2016-08-08 04:56:19 -05:00
|
|
|
|
2021-12-05 03:08:10 -06:00
|
|
|
$isSwoole = extension_loaded('openswoole');
|
2019-07-23 09:36:56 -05:00
|
|
|
|
2019-11-30 10:59:04 -06:00
|
|
|
return [
|
|
|
|
|
|
|
|
'logger' => [
|
2019-07-23 09:36:56 -05:00
|
|
|
'Shlink' => [
|
2022-06-04 01:59:17 -05:00
|
|
|
// For swoole, send logs as stream
|
|
|
|
'type' => $isSwoole ? LoggerType::STREAM->value : LoggerType::FILE->value,
|
|
|
|
'level' => Level::Debug->value,
|
2016-08-08 04:56:19 -05:00
|
|
|
],
|
|
|
|
],
|
|
|
|
|
|
|
|
];
|