Skip to content

Commit

Permalink
Merge pull request redhat-openstack#69 from cwolferh/smoke_test
Browse files Browse the repository at this point in the history
workaround to convert enable_tunneling into a boolean
  • Loading branch information
cwolferh committed Dec 5, 2013
2 parents 0a6f6d4 + 4102bfa commit b47257e
Show file tree
Hide file tree
Showing 2 changed files with 18 additions and 2 deletions.
10 changes: 9 additions & 1 deletion puppet/modules/quickstack/manifests/neutron/compute.pp
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,14 @@
$tunnel_id_ranges = '1:1000',
) inherits quickstack::params {

# str2bool expects the string to already be downcased. all-righty.
# (i.e. str2bool('True') would blow up, so work around it.)
$enable_tunneling_bool = $enable_tunneling ? {
/(?i:true)/ => true,
/(?i:false)/ => false,
default => str2bool("$enable_tunneling"),
}

class { '::neutron':
allow_overlapping_ips => true,
rpc_backend => 'neutron.openstack.common.rpc.impl_qpid',
Expand All @@ -43,7 +51,7 @@
bridge_uplinks => $ovs_bridge_uplinks,
bridge_mappings => $ovs_bridge_mappings,
local_ip => getvar("ipaddress_${private_interface}"),
enable_tunneling => str2bool("$enable_tunneling"),
enable_tunneling => $enable_tunneling_bool,
}

class { '::nova::network::neutron':
Expand Down
10 changes: 9 additions & 1 deletion puppet/modules/quickstack/manifests/neutron/networker.pp
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,14 @@
$verbose = $quickstack::params::verbose,
) inherits quickstack::params {

# str2bool expects the string to already be downcased. all-righty.
# (i.e. str2bool('True') would blow up, so work around it.)
$enable_tunneling_bool = $enable_tunneling ? {
/(?i:true)/ => true,
/(?i:false)/ => false,
default => str2bool("$enable_tunneling"),
}

if str2bool("$configure_ovswitch") {
vs_bridge { $bridge_name:
provider => ovs_redhat,
Expand Down Expand Up @@ -62,7 +70,7 @@
class { '::neutron::agents::ovs':
local_ip => getvar("ipaddress_${private_interface}"),
bridge_mappings => $ovs_bridge_mappings,
enable_tunneling => str2bool("$enable_tunneling"),
enable_tunneling => $enable_tunneling_bool,
}

class { '::neutron::agents::dhcp': }
Expand Down

0 comments on commit b47257e

Please sign in to comment.