diff --git a/web/sites/default/civicrm.settings.php b/web/sites/default/civicrm.settings.php index 5b7938b913ae4c9d5c4058938af0bf1b4dddadef..eff0f69aaff8704b54d5d74e8892d7a174180c0d 100644 --- a/web/sites/default/civicrm.settings.php +++ b/web/sites/default/civicrm.settings.php @@ -11,9 +11,10 @@ */ if (!empty($_SERVER['PRESSFLOW_SETTINGS'])) { $env = json_decode($_SERVER['PRESSFLOW_SETTINGS'], TRUE); - if (!empty($env['conf']['pantheon_binding'])) { + if (!empty($env['conf']['pantheon_environment'])) { $pantheon_db = $env['databases']['default']['default']; $pantheon_conf = $env['conf']; + $pantheon_root = $_ENV['HOME'] . ($_ENV['HOME'] !== '/' ? '/' : ''); //user name and password $db_string = $pantheon_db['driver'] . '://' . $pantheon_db['username'] . ':' . $pantheon_db['password'] . '@'; @@ -26,13 +27,13 @@ define('CIVICRM_UF_DSN', $db_string); define('CIVICRM_DSN', $db_string); - if ($pantheon_conf['pantheon_binding'] === 'lando') { + if ($pantheon_conf['pantheon_environment'] === 'lando') { $civicrm_root = $_SERVER['LANDO_MOUNT'] . '/vendor/civicrm/civicrm-core'; define('CIVICRM_TEMPLATE_COMPILEDIR', $_SERVER['LANDO_WEBROOT'] . '/' . $pantheon_conf['file_private_path'] . '/civicrm/templates_c/'); } else { - $civicrm_root = '/srv/bindings/' . $pantheon_conf['pantheon_binding'] . '/code/vendor/civicrm/civicrm-core'; - define('CIVICRM_TEMPLATE_COMPILEDIR', '/srv/bindings/' . $pantheon_conf['pantheon_binding'] . '/files/private/civicrm/templates_c/'); + $civicrm_root = $pantheon_root . '/code/vendor/civicrm/civicrm-core'; + define('CIVICRM_TEMPLATE_COMPILEDIR', $pantheon_root . '/files/private/civicrm/templates_c/'); // For our custom hack to move just the templates_c directory to a special place. define('CIVICRM_REAL_TEMPLATE_COMPILEDIR', $_SERVER['PANTHEON_ROLLING_TMP'] . '/civicrm/templates_c/'); @@ -43,16 +44,6 @@ // Use Drupal base url and path define('CIVICRM_UF_BASEURL', $base_url . '/'); - - // Use Redis cache. - if (!empty($pantheon_conf['redis_client_password'])) { - define( 'CIVICRM_DB_CACHE_CLASS', 'Redis' ); - define( 'CIVICRM_DB_CACHE_HOST', $pantheon_conf['redis_client_host'] ); - define( 'CIVICRM_DB_CACHE_PORT', $pantheon_conf['redis_client_port'] ); - define( 'CIVICRM_DB_CACHE_PASSWORD', $pantheon_conf['redis_client_password'] ); - define( 'CIVICRM_DB_CACHE_TIMEOUT', 3600 ); - define( 'CIVICRM_DB_CACHE_PREFIX', 'pantheon-redis-civicrm:' ); - } } }