1 # == Class: nova::network::vlan
3 # Configures nova network to use vlans
8 # (required) IPv4 CIDR of the network
11 # (required) Physical ethernet adapter name for vlan networking
13 # [*public_interface*]
14 # (optional) Interface for public traffic
18 # (optional) First vlan to use
21 # [*force_dhcp_release*]
22 # (optional) Whether to send a dhcp release on instance termination
26 # (optional) Domain to use for building the hostnames
27 # Defaults to 'novalocal'
30 # (optional) location of nova-dhcpbridge
31 # Defaults to '/usr/bin/nova-dhcpbridge'
33 # [*dhcpbridge_flagfile*]
34 # (optional) location of flagfiles for dhcpbridge
35 # Defaults to '/etc/nova/nova.conf'
37 class nova::network::vlan (
40 $public_interface = undef,
42 $force_dhcp_release = true,
43 $dhcp_domain = 'novalocal',
44 $dhcpbridge = '/usr/bin/nova-dhcpbridge',
45 $dhcpbridge_flagfile = '/etc/nova/nova.conf'
48 if $::osfamily == 'RedHat' and $::operatingsystem != 'Fedora' {
49 package { 'dnsmasq-utils': ensure => present }
52 if $public_interface {
53 nova_config { 'DEFAULT/public_interface': value => $public_interface }
57 'DEFAULT/network_manager': value => 'nova.network.manager.VlanManager';
58 'DEFAULT/fixed_range': value => $fixed_range;
59 'DEFAULT/vlan_interface': value => $vlan_interface;
60 'DEFAULT/vlan_start': value => $vlan_start;
61 'DEFAULT/force_dhcp_release': value => $force_dhcp_release;
62 'DEFAULT/dhcp_domain': value => $dhcp_domain;
63 'DEFAULT/dhcpbridge': value => $dhcpbridge;
64 'DEFAULT/dhcpbridge_flagfile': value => $dhcpbridge_flagfile;