Sha256: ebda0751f918d6310e9b8d19148bc570ad332ae82e24ec614a21227d9de368a8
Contents?: true
Size: 711 Bytes
Versions: 1
Compression:
Stored size: 711 Bytes
Contents
require 'chef/knife/openstack_base' class Chef class Knife class OpenstackNetworkList < Knife include Knife::OpenstackBase banner "knife openstack network list (options)" def run validate! net_list = [ ui.color('Name', :bold), ui.color('ID', :bold), ui.color('Tenant', :bold), ui.color('Shared', :bold), ] network.networks.all.sort_by(&:name).each do |network| net_list << network.name net_list << network.id net_list << network.tenant_id net_list << network.shared.to_s end puts ui.list(net_list, :uneven_columns_across, 4) end end end end
Version data entries
1 entries across 1 versions & 1 rubygems
Version | Path |
---|---|
knife-openstack-0.10.0 | lib/chef/knife/openstack_network_list.rb |