From 62873ac9e043e37162f0355c5a70ee059a89d139 Mon Sep 17 00:00:00 2001 From: Xingchao Yu Date: Wed, 14 Aug 2013 11:49:35 +0800 Subject: [PATCH] Fix nova-network settings in multi_host mode This patch is aim to fix two errors in nova-network setting: - When multi_host is enable, enable_network_service should be true. Otherwise, it will not install nova-network in controller. - When multi_host is disable, related param in nova.conf should set as false. Fixes Bug #1212093 Change-Id: If62427b3ac7ee744c16a6f4e67803cf1e233f374 --- manifests/all.pp | 1 - manifests/nova/controller.pp | 3 ++- spec/classes/openstack_controller_spec.rb | 4 ++-- 3 files changed, 4 insertions(+), 4 deletions(-) diff --git a/manifests/all.pp b/manifests/all.pp index 9521fad..b0b9b72 100644 --- a/manifests/all.pp +++ b/manifests/all.pp @@ -456,7 +456,6 @@ class openstack::all ( } } else { nova_config { - 'DEFAULT/multi_host': value => false; 'DEFAULT/send_arp_for_ha': value => false; } } diff --git a/manifests/nova/controller.pp b/manifests/nova/controller.pp index 3b767d0..5a8004a 100644 --- a/manifests/nova/controller.pp +++ b/manifests/nova/controller.pp @@ -176,8 +176,9 @@ class openstack::nova::controller ( # Configure nova-network if $multi_host { nova_config { 'DEFAULT/multi_host': value => true } - $enable_network_service = false + $enable_network_service = true } else { + nova_config { 'DEFAULT/multi_host': value => false } if $enabled { $enable_network_service = true } else { diff --git a/spec/classes/openstack_controller_spec.rb b/spec/classes/openstack_controller_spec.rb index 3e6a08d..35d69fd 100644 --- a/spec/classes/openstack_controller_spec.rb +++ b/spec/classes/openstack_controller_spec.rb @@ -665,8 +665,8 @@ describe 'openstack::controller' do it { should contain_nova_config('DEFAULT/multi_host').with(:value => true)} it {should contain_class('nova::network').with( :create_networks => true, - :enabled => false, - :install_service => false + :enabled => true, + :install_service => true )} end