Hi,

Maybe I'm missing something but I have tried to use a custom endpoint for Google Cloud Storage.
The admin config page says that everything is okay and saves the info.
But when trying to set a file field to save the files to the s3 file stream I found that the custom endpoint is not set for the connection (except on the admin form) and the request is set to Amazon default.

I fixed this by editing the S3Client.php static factory function and added this:

      if (!isset($config['endpoint'])) {
          $endpoint = static::variable_get('amazons3_hostname');
          if(!empty($endpoint)){
              $config['endpoint'] = $endpoint;
          }
      }

Have I missed anything in the config that will make it work without editing the module?

Thanks,
Bnaya Livne

Comments

bnayal created an issue. See original summary.

deviantintegral’s picture

Status: Active » Needs review

Thanks Bnaya, that is totally a bug. I've filed a pull request with your fix (and a test) over at https://github.com/justafish/drupal_amazons3/pull/39

deviantintegral’s picture

Status: Needs review » Fixed

Status: Fixed » Closed (fixed)

Automatically closed - issue fixed for 2 weeks with no activity.