Document the most basic set up for DDEV and server

Created on 29 September 2025, 8 days ago

Problem/Motivation

Some Drupal users may want to use Redis as a caching solution, but have no experience at all with setting it up.

Perhaps we can list the minimal steps required to get Redis up and running in popular environments, such as DDEV and a standard Debian Apache server?

Steps to reproduce

Look at the documentation and feel overwhelmed.

Proposed resolution

List the basic steps to set up Redis in popular environments, such as DDEV and a standard Debian Apache server.

The text below is adapted from these articles:

Setting up Redis in DDEV

Install Redis , as you would normally install a Drupal module .

Install the Redis DDEV package and restart DDEV. A new service is created, and the settings files updated:

$ ddev get ddev/ddev-redis
$ ddev restart

You should be good to go; Drupal will store its cache in the Redis database. Check by visiting a cached page, then open the Redis command line, type KEYS *, and press "Enter" (you should see many lines):

user@my-os> ddev redis-cli
redis:6379> KEYS *
  1) "drupal.redis.10.0.9..1b1d36866cd3838283aff4aa23abebfdebf122e1b8ce37e991cfd42e9aee7e8a:default:twig:65674054c9edd_page-title.html.twig_C-aI28H1wCRg97iJeFau2jScU"
[...]

Adapted from https://cyberschorsch.dev/drupal/elevating-drupals-capabilities-redis-ad....

Setting up Redis on Debian/Apache server

Install the Redis package (which creates a new service) and the PHP Redis extension on the server, and enable it:

$ sudo apt install redis-server php-redis
$ sudo phpenmod redis

Check if it is running, and make it start at every boot:

$ sudo service redis status

Make it start automatically after every boot:

$ sudo systemctl enable redis-server

Now paste this into the settings.php files:

$settings['container_yamls'][] = 'modules/contrib/redis/redis.services.yml';
$settings['redis.connection']['interface'] = 'PhpRedis';
$settings['redis.connection']['host'] = '127.0.0.1';
$settings['redis.connection']['port'] = 6379;
$settings['cache']['default'] = 'cache.backend.redis';
$settings['cache']['bins']['render'] = 'cache.backend.redis';
$settings['cache']['bins']['dynamic_page_cache'] = 'cache.backend.redis';
$settings['cache']['bins']['page'] = 'cache.backend.redis';

For details on installation and configuration, for example Redis performance tuning, see:

Remaining tasks

Decide if this can be added in a documentation page?

User interface changes

API changes

Data model changes

📌 Task
Status

Active

Version

2.0

Component

Documentation

Created by

🇩🇰Denmark ressa Copenhagen

Live updates comments and jobs are added and updated live.
Sign in to follow issues

Merge Requests

Comments & Activities

Not all content is available!

It's likely this issue predates Contrib.social: some issue and comment data are missing.

  • Merge request !64Add Quick Starts for DDEV and server → (Open) created by ressa
  • Pipeline finished with Success
    8 days ago
    Total: 258s
    #613003
  • Pipeline finished with Success
    8 days ago
    Total: 336s
    #613009
  • Pipeline finished with Success
    8 days ago
    Total: 298s
    #613020
  • Pipeline finished with Success
    4 days ago
    Total: 353s
    #617984
  • Pipeline finished with Success
    3 days ago
    Total: 466s
    #618208
  • Pipeline finished with Canceled
    3 days ago
    Total: 414s
    #618551
  • Pipeline finished with Canceled
    3 days ago
    Total: 112s
    #618552
  • Pipeline finished with Success
    3 days ago
    Total: 309s
    #618555
  • Pipeline finished with Canceled
    2 days ago
    Total: 224s
    #619394
  • Pipeline finished with Canceled
    2 days ago
    #619397
  • Pipeline finished with Success
    2 days ago
    Total: 390s
    #619398
Production build 0.71.5 2024