Sha256: 99c4aed5cb366cfafe1e49e24872bfb9d810c84ce1f40c8831e09d85528fba55

Contents?: true

Size: 1.19 KB

Versions: 7

Compression:

Stored size: 1.19 KB

Contents

# frozen_string_literal: true

require_relative "security/main"
require_relative "databases/main"
require_relative "instances_and_addons/main"
require_relative "misc/main"

module Neetob
  class CLI
    module MonthlyAudit
      class Perform < CLI::Base
        attr_accessor :sandbox, :month

        def initialize(month, sandbox = false)
          super()
          @month = month
          @sandbox = sandbox
        end

        def run
          Thread.current[:audit_mode] = true
          markdown_file_name = "audit-report-#{DateTime.now.to_i}.md"
          Thread.current[:markdown_file_name] = markdown_file_name
          ui.success("## Starting the audit for #{month}")
          ui.info "\n"
          Security::Main.new.run
          ui.info "\n"
          Databases::Main.new.run
          ui.info "\n"
          InstancesAndAddons::Main.new.run
          ui.info "\n"
          Misc::Main.new.run
          ui.info "\n"
          ui.success("## Audit for #{month} completed successfully.")
          ui.success("## Audit report is written to #{markdown_file_name}")
          ui.success("## Please update the manual audit part and post the audit in Github.")
        end
      end
    end
  end
end

Version data entries

7 entries across 7 versions & 1 rubygems

Version Path
neetob-0.5.23 lib/neetob/cli/monthly_audit/perform.rb
neetob-0.5.22 lib/neetob/cli/monthly_audit/perform.rb
neetob-0.5.21 lib/neetob/cli/monthly_audit/perform.rb
neetob-0.5.20 lib/neetob/cli/monthly_audit/perform.rb
neetob-0.5.19 lib/neetob/cli/monthly_audit/perform.rb
neetob-0.5.18 lib/neetob/cli/monthly_audit/perform.rb
neetob-0.5.17 lib/neetob/cli/monthly_audit/perform.rb