Publisher does not support the Fluid field type. Please do not contact asking when support will be available.

If you purchased an add-on from expressionengine.com, be sure to visit boldminded.com/claim to add the license to your account here on boldminded.com.

Ticket: Speedy Redis as Static Not Enabled

Status Resolved
Add-on / Version Speedy 1.9.1
Severity
EE Version 7.2.5

Doug Black

Apr 03, 2024

Description of the problem

Currently have Speedy set up to use Redis for static caching per the docs. This is a site that is on 3 servers with a load balancer in front of it, using AWS EC2 and ElastiCache for Redis.

The Redis cluster is enabled on all of the servers and accessible.

I have Redis enabled in the config for the site:

// SPEEDY
$config['speedy_static_enabled'] = 'yes';
$config['speedy_driver'] = 'redis';
$config['speedy_redis_settings'] = [
    'static' => 'yes',
    'servers' => [
        [
            'host' => 'cluster-host0name.serverless.usw2.cache.amazonaws.com',
            'port' => '6379',
            'timeout' => '0',
            'password' => null,
        ]
    ],
];

However, I get the following error:

Redis as Static is enabled, but no handler has been created, or the /static directory and utility files do not exist.

I’m not seeing a way to regenerate the index_redis_default_site.php file, and it’s not generating it on its own.

Can you point me in the right direction?

Screenshots / Videos / Template Code Attached below

Environment Details: - Version: 7.2.5 - PHP Version 8.0 - MySQL Version 8.0 on RDS - OS: Ubuntu - Web Server: nginx

#1

BoldMinded (Brian)

There should be an alert at the top of the Speedy home page in the CP with a link to regenerate.

#2

Doug Black

I unfortunately do not have one. Is there a way to force it?

And Redis is showing as unconfigured, but because of the static handler thing. Does that impact this?

#3

BoldMinded (Brian)

Any changes to the configuration should trigger the regeneration alert. Do you currently have a static folder? If so delete it. Have you tried uninstalling and reinstalling?

#4

Doug Black

Ok, I moved some things around on the server and it fixed itself.

One last question about Redis and static caching. The docs mention the htaccess, but I’m using nginx, so forgive the stupid question. Am I understanding that I just need to route all requests through the index_redis_default_site.php instead of index.php? Or am I following the other nginx config items in the docs and doing something else?

#5

BoldMinded (Brian)

Yes, need to route everything through index_redis_default_site.php. I thought the docs had an nginx example.

Login to reply