1
0
Fork 0
mirror of https://github.com/fog/fog-aws.git synced 2022-11-09 13:50:52 -05:00

Merge pull request #506 from NARKOZ/fix-endpoints

Fix some requests when S3 acceleration is enabled
This commit is contained in:
Wesley Beary 2019-02-21 09:35:42 -06:00 committed by GitHub
commit d82eba14e5
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
2 changed files with 4 additions and 5 deletions

View file

@ -12,7 +12,7 @@ module Fog
# * body [Hash]:
# * LocationConstraint [String] - Location constraint of the bucket
#
# @see http://docs.amazonwebservices.com/AmazonS3/latest/API/RESTBucketGETlocation.html
# @see https://docs.aws.amazon.com/AmazonS3/latest/API/RESTBucketGETlocation.html
def get_bucket_location(bucket_name)
request({
@ -22,8 +22,7 @@ module Fog
:idempotent => true,
:method => 'GET',
:parser => Fog::Parsers::AWS::Storage::GetBucketLocation.new,
:query => {'location' => nil},
:path_style => true
:query => {'location' => nil}
})
end
end

View file

@ -15,13 +15,13 @@ module Fog
# * DisplayName [String] - Display name of bucket owner
# * ID [String] - Id of bucket owner
#
# @see http://docs.amazonwebservices.com/AmazonS3/latest/API/RESTServiceGET.html
# @see https://docs.aws.amazon.com/AmazonS3/latest/API/RESTServiceGET.html
#
def get_service
request({
:expects => 200,
:headers => {},
:host => @host,
:host => 's3.amazonaws.com',
:idempotent => true,
:method => 'GET',
:parser => Fog::Parsers::AWS::Storage::GetService.new