Project

General

Profile

Feature #1951

Support libvirt named NAT networks

Added by Dominic Cleal almost 7 years ago. Updated about 6 years ago.

Status:
Closed
Priority:
Normal
Assignee:
Category:
Compute resources
Target version:
Difficulty:
Triaged:
No
Bugzilla link:
Pull request:
Team Backlog:
Fixed in Releases:
Found in Releases:

Description

Currently libvirt compute resources support bridged interfaces, but not libvirt NAT networks.

The NICs on a fog compute resource have both a bridge and network attribute, but the libvirt network view (app/views/compute_resources_vms/form/libvirt/_network.html.erb) only sets the bridge.

nics=[    <Fog::Compute::Libvirt::Nic
mac="52:54:00:9a:34:98",
type="network",
network="default",
bridge=nil,
model="virtio"
>],

This is compounded because the getter for libvirt networks (lib/foreman/model/libvirt.rb, networks) calls fog's interfaces getter which returns a list of physical interfaces (eth0, wlan0) and doesn't include bridges (virbr*). If the getter doesn't return data, the view allows a bridge interface to be manually entered and so you can get around it in some configurations. Entering the network name is more reliable across reboots of the hypervisor.

The way it should probably work is:

  • allow selection of either an interface or a libvirt network name
  • offer a list of interfaces, including bridges
  • always offer a text box for manual interface override
  • offer a list of libvirt network names

Related issues

Has duplicate Foreman - Bug #2477: Wrong interface for libvirt bridgeDuplicate2013-05-08

Associated revisions

Revision c5c84034 (diff)
Added by Ohad Levy about 6 years ago

fixes #1951 - support for libvirt named networks

based on Dominic initial pull request 308

Revision deb8c443 (diff)
Added by Ohad Levy about 6 years ago

fixes #1951 - support for libvirt named networks

based on Dominic initial pull request 308
(cherry picked from commit c5c84034b1f6dec25c14340861a48175b49e682a)

History

#1 Updated by Dominic Cleal over 6 years ago

  • Status changed from New to Assigned

#2 Updated by Ohad Levy about 6 years ago

  • Status changed from Assigned to Closed
  • % Done changed from 0 to 100

#3 Updated by Ohad Levy about 6 years ago

  • Assignee set to Ohad Levy
  • Target version set to 1.2.0

Also available in: Atom PDF