I have a test instance started a day ago of CiviCRM running on Amazon EC2 using the bitnami version (https://bitnami.com/stack/civicrm/cloud) which uses Drupal 7.72 and runs CiviCRM 5.27.4

I added an api_key through MySQL for the correct user id and read the CIVICRM_SITE_KEY from civicrm.settings.php which I found at /bitnami/drupal/sites/default/civicrm.settings.php

Running APIv3 through the CiviCRM console (http://mysite/civicrm/api3#explorer) works and generates an example query url to use for REST. However, when I substitute in the keys and put the query in my browser address bar I get: "Could not load the settings file at: /bitnami/drupal/modules/contrib/civicrm/../..//default/civicrm.settings.php"

What can I change to make sure that the civicrm.settings.php file is found?


Ok, so this is a temporary fix. Would be interested to know a final solution: In the path /bitnami/drupal/modules/contrib/civicrm/../..//default/civicrm.settings.php the '//' is interpreted as '/' so the file being looked for is: /bitnami/drupal/modules/default/civicrm.settings.ph

Well, there is no default directory in /bitnami/drupal/modules so I created it and inside I put a symlink to the correct location of civicrm.settings.php
cd /bitnami/drupal/modules/default
ln -s /bitnami/drupal/sites/default/civicrm.settings.php civicrm.settings.php

With that the example REST query works fine.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.