Method: Fog::Storage::AWS::Mock#initialize
- Defined in:
- lib/fog/aws/storage.rb
#initialize(options = {}) ⇒ Mock
Returns a new instance of Mock.
203 204 205 206 207 208 209 210 211 212 213 214 215 216 |
# File 'lib/fog/aws/storage.rb', line 203 def initialize(={}) require 'mime/types' @use_iam_profile = [:use_iam_profile] setup_credentials() [:region] ||= 'us-east-1' @host = [:host] || case [:region] when 'us-east-1' 's3.amazonaws.com' else "s3-#{[:region]}.amazonaws.com" end @scheme = [:scheme] || 'https' @region = [:region] end |