Class: VolumeSweeper::Providers::Base

Inherits:
Object
  • Object
show all
Defined in:
lib/volume_sweeper/providers/base.rb

Direct Known Subclasses

Aws, Oci

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(**kwargs) ⇒ Base

Returns a new instance of Base.



7
8
9
10
11
12
13
14
15
16
# File 'lib/volume_sweeper/providers/base.rb', line 7

def initialize **kwargs
  @run_mode = kwargs[:mode]&.to_sym || :audit
  @config_location = kwargs[:config_path]
  @account_id = kwargs[:account_id]
  @compartment_id = kwargs[:account_id]
  @region = kwargs[:region]

  @log = Utils::Log.instance
  @log.msg "#{self.class.name.downcase.split(":").last}: running in :#{@run_mode} mode."
end

Instance Attribute Details

Returns the value of attribute base_link.



5
6
7
# File 'lib/volume_sweeper/providers/base.rb', line 5

def base_link
  @base_link
end

Instance Method Details

#delete_volumes(ids_list) ⇒ Object



19
# File 'lib/volume_sweeper/providers/base.rb', line 19

def delete_volumes ids_list; end

#scan_volumesObject



18
# File 'lib/volume_sweeper/providers/base.rb', line 18

def scan_volumes; end