Skip to main content

Redis

In-memory cache

In-memory cache. Valkey is the fork most stacks now take; this is here for what expects Redis by name. The two speak the same protocol, so an application written against one runs unchanged on the other. A stack runs one cache — Redis, Valkey or Memcached — so naming a different one replaces it.

Your application finds it at REDIS_HOST, port 6379 (REDIS_PORT). Both are in its environment, and REDIS_HOST is the name the Drupal redis module reads.

How much memory it holds is sized from your machine: most of a cache machine when it has one to itself, a share of your plan when it sits beside your site. When it is full it evicts the least recently used key (allkeys-lru), which is what a cache should do. If you are keeping something that must not be lost, set REDIS_MAXMEMORY_POLICY to noeviction — and remember that nothing in it is backed up.

#Versions

Version Status
8.6 Supported, and the default
8.4 Supported
8.2 Supported

Pin the version, not the build: name 8.6 and the platform matches it to the current build, so a security rebuild reaches you without anybody editing a repository.

#What you can change

In vallic.yaml — what each one does is on Service settings:

services:
  - redis:
      version: '8.6'
      environment:
        REDIS_MAXMEMORY_POLICY: …
        REDIS_DATABASES: …

Anything not on this list refuses the deploy, naming the variable — rather than being accepted and quietly ignored.