Skip to content

Instantly share code, notes, and snippets.

@star-szr
Last active August 29, 2015 13:59
Show Gist options
  • Save star-szr/10997441 to your computer and use it in GitHub Desktop.
Save star-szr/10997441 to your computer and use it in GitHub Desktop.
Disable cache_render or other cache bins in Drupal 8
services:
cache.backend.memory:
class: Drupal\Core\Cache\MemoryBackendFactory
<?php
// First line will not be needed after https://drupal.org/node/2241633.
// For more cache docs see https://api.drupal.org/api/drupal/core%21modules%21system%21core.api.php/group/cache/8
$GLOBALS['conf']['container_yamls'][] = $conf_path . '/services.yml';
$settings['cache']['bins']['render'] = 'cache.backend.memory';
@star-szr
Copy link
Author

Huge thanks to @Berdir and @sun in IRC for helping me put this together!

Put the services.yml in sites/default/services.yml and add the lines to your settings.php.

@sun
Copy link

sun commented Apr 17, 2014

That code comment as a link: https://drupal.org/node/2241633

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment