def modify_network_interface
      @hosts.each do |host|
        instance = host['instance']
        host['sg_cidr_ips'] = host['sg_cidr_ips'] || '0.0.0.0/0';
        sg_cidr_ips = host['sg_cidr_ips'].split(',')

        # Define tags for the instance
        @logger.notify("aws-sdk: Update network_interface for #{host.name}")

        security_group = ensure_group(instance[:network_interfaces].first, Beaker::EC2Helper.amiports(host), sg_cidr_ips)
        ping_security_group = ensure_ping_group(instance[:network_interfaces].first, sg_cidr_ips)

        client.modify_network_interface_attribute(
          :network_interface_id => "#{instance[:network_interfaces].first[:network_interface_id]}",
          :groups => [security_group.group_id, ping_security_group.group_id],
        )
      end

      nil
    end
def modify_network_interface
      @hosts.each do |host|
        instance = host['instance']
        host['sg_cidr_ips'] = host['sg_cidr_ips'] || '0.0.0.0/0';
        sg_cidr_ips = host['sg_cidr_ips'].split(',')

        # Define tags for the instance
        @logger.notify("aws-sdk: Update network_interface for #{host.name}")

        security_group = ensure_group(instance[:network_interfaces].first, Beaker::EC2Helper.amiports(host), sg_cidr_ips)
        ping_security_group = ensure_ping_group(instance[:network_interfaces].first, sg_cidr_ips)

        client.modify_network_interface_attribute(
          :network_interface_id => "#{instance[:network_interfaces].first[:network_interface_id]}",
          :groups => [security_group.group_id, ping_security_group.group_id],
        )
      end

      nil
    end
Add correct security groups to hosts network_interface
 as during the create_instance stage it is too early in process
 to configure

 @return [void]
 @api private