mirror of
https://github.com/shlinkio/shlink.git
synced 2024-11-22 08:56:42 -06:00
Merge pull request #1928 from acelaya-forks/feature/redis-urlencoded
Allow redis credentials be URL-decoded before passing them to connection
This commit is contained in:
commit
9035161b65
@ -19,6 +19,7 @@ The format is based on [Keep a Changelog](https://keepachangelog.com), and this
|
||||
This is important if you are running multiple Shlink instance on the same server, or they share the same Redis instance (even more so if they are on different versions).
|
||||
|
||||
* [#1905](https://github.com/shlinkio/shlink/issues/1905) Add support for PHP 8.3.
|
||||
* [#1927](https://github.com/shlinkio/shlink/issues/1927) Allow redis credentials be URL-decoded before passing them to connection.
|
||||
|
||||
### Changed
|
||||
* [#1799](https://github.com/shlinkio/shlink/issues/1799) RoadRunner/openswoole jobs are not run anymore for tasks that are actually disabled.
|
||||
|
@ -41,16 +41,16 @@
|
||||
"mezzio/mezzio-problem-details": "^1.13",
|
||||
"mezzio/mezzio-swoole": "^4.7",
|
||||
"mlocati/ip-lib": "^1.18",
|
||||
"mobiledetect/mobiledetectlib": "^3.74",
|
||||
"mobiledetect/mobiledetectlib": "^4.8",
|
||||
"pagerfanta/core": "^3.8",
|
||||
"php-middleware/request-id": "^4.1",
|
||||
"pugx/shortid-php": "^1.1",
|
||||
"ramsey/uuid": "^4.7",
|
||||
"shlinkio/shlink-common": "dev-main#7d46772 as 5.7",
|
||||
"shlinkio/shlink-common": "dev-main#e24ea7b as 5.7",
|
||||
"shlinkio/shlink-config": "dev-main#cde5d3b as 2.5",
|
||||
"shlinkio/shlink-event-dispatcher": "dev-main#35ccc0b as 3.1",
|
||||
"shlinkio/shlink-importer": "dev-main#d621b20 as 5.2",
|
||||
"shlinkio/shlink-installer": "dev-develop#c505a19 as 8.6",
|
||||
"shlinkio/shlink-installer": "dev-develop#0fde6fd as 8.6",
|
||||
"shlinkio/shlink-ip-geolocation": "dev-main#4a1cef8 as 3.3",
|
||||
"shlinkio/shlink-json": "dev-main#e5a111c as 1.1",
|
||||
"spiral/roadrunner": "^2023.2",
|
||||
|
@ -11,6 +11,7 @@ return (static function (): array {
|
||||
'redis' => [
|
||||
'servers' => $redisServers,
|
||||
'sentinel_service' => EnvVars::REDIS_SENTINEL_SERVICE->loadFromEnv(),
|
||||
'decode_credentials' => (bool) EnvVars::REDIS_DECODE_CREDENTIALS->loadFromEnv(false),
|
||||
],
|
||||
];
|
||||
|
||||
|
@ -32,6 +32,7 @@ return [
|
||||
Option\Worker\TaskWorkerNumConfigOption::class,
|
||||
Option\Worker\WebWorkerNumConfigOption::class,
|
||||
Option\Redis\RedisServersConfigOption::class,
|
||||
Option\Redis\RedisDecodeCredentialsConfigOption::class,
|
||||
Option\Redis\RedisSentinelServiceConfigOption::class,
|
||||
Option\Redis\RedisPubSubConfigOption::class,
|
||||
Option\UrlShortener\ShortCodeLengthOption::class,
|
||||
|
@ -20,6 +20,7 @@ enum EnvVars: string
|
||||
case CACHE_NAMESPACE = 'CACHE_NAMESPACE';
|
||||
case REDIS_SERVERS = 'REDIS_SERVERS';
|
||||
case REDIS_SENTINEL_SERVICE = 'REDIS_SENTINEL_SERVICE';
|
||||
case REDIS_DECODE_CREDENTIALS = 'REDIS_DECODE_CREDENTIALS';
|
||||
case REDIS_PUB_SUB_ENABLED = 'REDIS_PUB_SUB_ENABLED';
|
||||
case MERCURE_PUBLIC_HUB_URL = 'MERCURE_PUBLIC_HUB_URL';
|
||||
case MERCURE_INTERNAL_HUB_URL = 'MERCURE_INTERNAL_HUB_URL';
|
||||
|
@ -12,7 +12,8 @@ enum DeviceType: string
|
||||
|
||||
public static function matchFromUserAgent(string $userAgent): ?self
|
||||
{
|
||||
$detect = new MobileDetect(userAgent: $userAgent);
|
||||
$detect = new MobileDetect();
|
||||
$detect->setUserAgent($userAgent);
|
||||
|
||||
return match (true) {
|
||||
// $detect->is('iOS') && $detect->isTablet() => self::IOS, // TODO To detect iPad only
|
||||
|
Loading…
Reference in New Issue
Block a user