Class: Neetob::CLI::Sre::Report
- Defined in:
- lib/neetob/cli/sre/report.rb
Constant Summary
Constants inherited from Base
Base::APPS_LIST, Base::RESOURCES
Constants inherited from Base
Instance Attribute Summary collapse
-
#environment ⇒ Object
Returns the value of attribute environment.
Attributes inherited from Base
Instance Method Summary collapse
-
#initialize(environment) ⇒ Report
constructor
A new instance of Report.
- #run ⇒ Object
Methods included from Utils
#camel_case_to_slug, #is_upper?, #symbolize_keys
Constructor Details
#initialize(environment) ⇒ Report
Returns a new instance of Report.
11 12 13 14 |
# File 'lib/neetob/cli/sre/report.rb', line 11 def initialize(environment) super() @environment = environment end |
Instance Attribute Details
#environment ⇒ Object
Returns the value of attribute environment.
9 10 11 |
# File 'lib/neetob/cli/sre/report.rb', line 9 def environment @environment end |
Instance Method Details
#run ⇒ Object
16 17 18 19 20 21 22 23 24 25 26 |
# File 'lib/neetob/cli/sre/report.rb', line 16 def run raise(StandardError, "Environment should be staging or production.") unless environments.include?(environment) RESOURCES.each do |product, values| next if environment == "staging" && [:NeetoDeploy, :NeetoCi].include?(product) ui.info "Processing for #{product}" ui.info `neetob sre checklist -a #{product} -e #{environment}` ui.info "\n\n" end end |