Class: SourcedConfig::S3File

Inherits:
Object
  • Object
show all
Defined in:
lib/sourced_config/s3_file.rb

Class Method Summary collapse

Class Method Details

.read(bucket, path, region, retry_limit: 10) ⇒ Object



5
6
7
8
9
# File 'lib/sourced_config/s3_file.rb', line 5

def self.read(bucket, path, region, retry_limit: 10)
  s3 = Aws::S3::Client.new(retry_limit: retry_limit, region: region)
  resp = s3.get_object(bucket: bucket, key: path)
  resp.body
end