coolify/config/cache.php

67 lines
2.1 KiB
PHP
Raw Normal View History

2023-03-17 14:33:48 +00:00
<?php
2025-03-29 15:20:45 +00:00
declare(strict_types=1);
2023-03-17 14:33:48 +00:00
use Illuminate\Support\Str;
return [
/*
|--------------------------------------------------------------------------
| Default Cache Store
|--------------------------------------------------------------------------
|
2025-11-30 15:50:04 +00:00
| This option controls the default cache store that will be used by the
| framework. This connection is utilized if another isn't explicitly
| specified when running a cache operation inside the application.
2023-03-17 14:33:48 +00:00
|
*/
2025-12-04 14:42:09 +00:00
'default' => env('CACHE_STORE', 'redis'),
2023-03-17 14:33:48 +00:00
/*
|--------------------------------------------------------------------------
| Cache Stores
|--------------------------------------------------------------------------
|
| Here you may define all of the cache "stores" for your application as
| well as their drivers. You may even define multiple stores for the
| same cache driver to group types of items stored in your caches.
|
2025-11-30 15:50:04 +00:00
| Supported drivers: "array", "database", "file", "memcached",
| "redis", "dynamodb", "octane",
| "failover", "null"
2023-03-17 14:33:48 +00:00
|
*/
'stores' => [
'array' => [
'driver' => 'array',
'serialize' => false,
],
'session' => [
'driver' => 'session',
'key' => env('SESSION_CACHE_KEY', '_cache'),
],
2023-03-17 14:33:48 +00:00
'redis' => [
'driver' => 'redis',
2025-11-30 15:50:04 +00:00
'connection' => env('REDIS_CACHE_CONNECTION', 'cache'),
'lock_connection' => env('REDIS_CACHE_LOCK_CONNECTION', 'default'),
2023-03-17 14:33:48 +00:00
],
],
/*
|--------------------------------------------------------------------------
| Cache Key Prefix
|--------------------------------------------------------------------------
|
2025-11-30 15:50:04 +00:00
| When utilizing the APC, database, memcached, Redis, and DynamoDB cache
| stores, there might be other applications using the same cache. For
2023-03-17 14:33:48 +00:00
| that reason, you may prefix every cache key to avoid collisions.
|
*/
2025-12-04 14:42:09 +00:00
'prefix' => env('CACHE_PREFIX', Str::slug((string) env('APP_NAME', 'coolify')).'-cache-'),
2023-03-17 14:33:48 +00:00
];