Class: Jets::CLI::Waf::Deploy

Inherits:
Base
  • Object
show all
Defined in:
lib/jets/cli/waf/deploy.rb

Instance Attribute Summary

Attributes inherited from Base

#options

Instance Method Summary collapse

Methods inherited from Base

#stack_name

Methods inherited from Base

#initialize, #paginate, #paging_params, rescue_api_error

Methods included from Util::Logging

#log

Methods included from AwsServices

#apigateway, #aws_options, #cfn, #codebuild, #dynamodb, #lambda_client, #logs, #s3, #s3_resource, #sns, #sqs, #ssm, #sts, #wafv2

Methods included from AwsServices::StackStatus

#output_value, #stack_exists?

Methods included from AwsServices::GlobalMemoist

included, #reset_cache!

Methods included from Api

#api, #api_key

Constructor Details

This class inherits a constructor from Jets::CLI::Base

Instance Method Details

#are_you_sure?Boolean

Returns:

  • (Boolean)


9
10
11
12
13
14
15
# File 'lib/jets/cli/waf/deploy.rb', line 9

def are_you_sure?
  sure? <<~EOL
    Will deploy stack #{stack_name.color(:green)} to us-east-1

    Uses #{Jets.project.namespace} remote runner to deploy a separate stack for WAF resources.
  EOL
end

#runObject



3
4
5
6
7
# File 'lib/jets/cli/waf/deploy.rb', line 3

def run
  are_you_sure?
  Jets::Cfn::Bootstrap.new(@options).run
  Jets::Remote::Runner.new(@options.merge(command: "waf:deploy")).run
end