I configured it in config.php directly, probably following https://docs.nextcloud.com/server/latest/admin_manual/configuration_server/caching_configuration.html#id2
'memcache.local' => '\\OC\\Memcache\\APCu',
'memcache.distributed' => '\\OC\\Memcache\\Redis',
'memcache.locking' => '\\OC\\Memcache\\Redis',
'redis' =>
array (
'host' => 'redis',
'port' => 6379,
),
Wait, you're serious?