module GClouder::Resources::Compute::Addresses
Public Class Methods
check()
click to toggle source
# File lib/gclouder/resources/compute/addresses.rb, line 37 def self.check return if Remote.list.empty? return if Local.list.empty? header :check Resources::Validate::Remote.instances(Local.list, Remote.list) end
ensure()
click to toggle source
# File lib/gclouder/resources/compute/addresses.rb, line 15 def self.ensure return if Local.list.empty? header if Local.list.key?("global") info "global", indent: 2, heading: true info Local.list["global"].each { |address| Address.ensure(address["name"], "--global") } end Local.list.each do |region, addresses| next if region == "global" next unless addresses info region, indent: 2, heading: true info addresses.each do |address| Address.ensure(address["name"], "--region #{region}") end end end
header(stage = :ensure)
click to toggle source
# File lib/gclouder/resources/compute/addresses.rb, line 11 def self.header(stage = :ensure) info "[#{stage}] compute / addresses", title: true end
validate()
click to toggle source
# File lib/gclouder/resources/compute/addresses.rb, line 44 def self.validate return if Local.list.empty? header :validate Local.validate end