Class: Lono::S3::AwsSetup

Inherits:
Object
  • Object
show all
Includes:
AwsServices
Defined in:
lib/lono/s3/aws_setup.rb

Instance Method Summary collapse

Methods included from AwsServices

#cfn, #ec2, #iam, #s3, #s3_presigner, #s3_resource, #sts

Methods included from AwsServices::Helper

#rollback_complete?, #testing_update?

Methods included from AwsServices::StackSet

#find_stack_set, #stack_set_exists?

Methods included from AwsServices::Stack

#find_stack, #stack_exists?

Instance Method Details

#check!Object



5
6
7
8
9
10
11
12
13
14
# File 'lib/lono/s3/aws_setup.rb', line 5

def check!
  s3.config.region
rescue Aws::Errors::MissingRegionError => e
  puts "ERROR: #{e.class}: #{e.message}".color(:red)
  puts <<~EOL
    Unable to detect the AWS_REGION to make AWS API calls. This is might be because the AWS access
    has not been set up yet. Please either your ~/.aws files.
  EOL
  exit 1
end