server/content/object-cache.php
Ipstenu (Mika Epstein) ad941b3107
Update composer dependencies and refine Redis configuration (#101)
Signed-off-by: Mika Ipstenu Epstein ipstenu@halfelf.org
Signed-off-by: Mika Ipstenu Epstein <ipstenu@halfelf.org>
Signed-off-by: Ipstenu (Mika Epstein) <Ipstenu@users.noreply.github.com>
2026-02-12 14:32:11 -08:00

13 lines
428 B
PHP

<?php
WP_Predis\add_filters();
// Set the host from the environment variable before loading the plugin logic
if ( getenv( 'REDIS_PORT' ) && ! defined( 'WP_REDIS_PORT' ) ) {
define( 'WP_REDIS_PORT', getenv( 'REDIS_PORT' ) );
}
if ( getenv( 'REDIS_HOST' ) && ! defined( 'WP_REDIS_BACKEND_HOST' ) ) {
define( 'WP_REDIS_BACKEND_HOST', getenv( 'REDIS_HOST' ) );
}
require_once __DIR__ . '/plugins/wp-redis/object-cache.php';