2018-11-24 10:43:48 +03:00
|
|
|
<?php
|
2019-10-05 18:26:10 +03:00
|
|
|
|
2018-11-24 10:43:48 +03:00
|
|
|
declare(strict_types=1);
|
|
|
|
|
2021-08-07 12:05:20 +03:00
|
|
|
use function Shlinkio\Shlink\Common\env;
|
|
|
|
|
2018-11-24 10:43:48 +03:00
|
|
|
return [
|
|
|
|
|
2020-01-01 23:11:53 +03:00
|
|
|
'mezzio-swoole' => [
|
2020-05-01 19:24:48 +03:00
|
|
|
// Setting this to true can have unexpected behaviors when running several concurrent slow DB queries
|
|
|
|
'enable_coroutine' => false,
|
2018-11-24 10:43:48 +03:00
|
|
|
|
|
|
|
'swoole-http-server' => [
|
|
|
|
'host' => '0.0.0.0',
|
2021-08-07 12:05:20 +03:00
|
|
|
'port' => (int) env('PORT', 8080),
|
2018-11-29 23:14:24 +03:00
|
|
|
'process-name' => 'shlink',
|
2019-07-14 11:46:31 +03:00
|
|
|
|
|
|
|
'options' => [
|
2021-08-07 12:05:20 +03:00
|
|
|
'worker_num' => (int) env('WEB_WORKER_NUM', 16),
|
|
|
|
'task_worker_num' => (int) env('TASK_WORKER_NUM', 16),
|
2019-07-14 11:46:31 +03:00
|
|
|
],
|
2018-11-24 10:43:48 +03:00
|
|
|
],
|
|
|
|
],
|
|
|
|
|
|
|
|
];
|