lib/wire/resource/network_injection.rb
# for the network helper script, construct
# an array of container devices names and bridge names,
# i.e. eht1:br0 meaning container will be attached
# to bridge br0 with eth1.
# if a network defines a short name, it will be used for
# the container interface.
# will check if a network does not have dhcp enable and add a
# NODHCP flag.
for the network helper script, construct
an array of container devices names and bridge names,
i.e. eht1:br0 meaning container will be attached
to bridge br0 with eth1.
if a network defines a short name, it will be used for
the container interface.
will check if a network does not have dhcp enable and add a
NODHCP flag.
for the network helper script construct an array of container devices names and bridge names i . e . eht1 : br0 meaning container will be attached to bridge br0 with eth1 . if a network defines a short name it will be used for the container interface . will check if a network does not have dhcp enable and add a NODHCP flag .
def construct_helper_params
        res = []
        networks.each do |network_name, network_data|
          name = (network_data[:shortname]) ? network_data[:shortname] : network_name
          line = "#{name}:#{network_name}"
          (network_data[:dhcp]) || line << ':NODHCP'
          res << line
        end
        res.join(' ')
      end
def construct_helper_params res = [ ] networks . each do | network_name , network_data | name = ( network_data [ :shortname ] ) ? network_data [ :shortname ] : network_name line = "#{name}:#{network_name}" ( network_data [ :dhcp ] ) || line << ':NODHCP' res << line end res . join ( ' ' ) end
for the network helper script, construct
an array of container devices names and bridge names,
i.e.
for the network helper script construct an array of container devices names and bridge names i . e .