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

Merge pull request #3369 from fredjean/master

Only show HTTPS bucket name warning when not using path_style
This commit is contained in:
Wesley Beary 2014-12-30 17:13:01 -05:00
commit 770f165548

View file

@ -224,7 +224,7 @@ module Fog
if COMPLIANT_BUCKET_NAMES !~ bucket_name
Fog::Logger.warning("fog: the specified s3 bucket name(#{bucket_name}) is not a valid dns name, which will negatively impact performance. For details see: http://docs.amazonwebservices.com/AmazonS3/latest/dev/BucketRestrictions.html")
path_style = true
elsif scheme == 'https' && bucket_name =~ /\./
elsif scheme == 'https' && !path_style && bucket_name =~ /\./
Fog::Logger.warning("fog: the specified s3 bucket name(#{bucket_name}) contains a '.' so is not accessible over https as a virtual hosted bucket, which will negatively impact performance. For details see: http://docs.amazonwebservices.com/AmazonS3/latest/dev/BucketRestrictions.html")
path_style = true
end