Set hasstatus => true for nova services

Fix bug 1170671

notifies to nova services on RHEL were not causing a restart of the service

Change-Id: I5fc91e1c519425e96677796d9de5222ab9d7f105
This commit is contained in:
Derek Higgins
2013-04-19 07:49:34 -04:00
parent c70691ec1d
commit f7830b7684
9 changed files with 91 additions and 68 deletions

View File

@@ -49,6 +49,7 @@ define nova::generic_service(
name => $service_name,
ensure => $service_ensure,
enable => $enabled,
hasstatus => true,
require => [Package['nova-common'], Package[$nova_title]],
}
}

View File

@@ -17,6 +17,7 @@ describe 'nova::api' do
it { should contain_service('nova-api').with(
'name' => 'nova-api',
'ensure' => 'stopped',
'hasstatus' => 'true',
'enable' => false
)}
it { should contain_package('nova-api').with(
@@ -31,6 +32,7 @@ describe 'nova::api' do
it { should contain_service('nova-api').with(
'name' => 'nova-api',
'ensure' => 'running',
'hasstatus' => 'true',
'enable' => true
)}
end

View File

@@ -13,6 +13,7 @@ describe 'nova::cert' do
it { should contain_service('nova-cert').with(
'name' => 'nova-cert',
'ensure' => 'stopped',
'hasstatus' => 'true',
'enable' => false
)}
it { should contain_package('nova-cert').with(
@@ -27,6 +28,7 @@ describe 'nova::cert' do
it { should contain_service('nova-cert').with(
'name' => 'nova-cert',
'ensure' => 'running',
'hasstatus' => 'true',
'enable' => true
)}
end
@@ -46,6 +48,7 @@ describe 'nova::cert' do
it { should contain_service('nova-cert').with(
'name' => 'openstack-nova-cert',
'ensure' => 'stopped',
'hasstatus' => 'true',
'enable' => false
)}
it { should contain_package('nova-cert').with_name('openstack-nova-cert') }

View File

@@ -28,6 +28,7 @@ describe 'nova::compute' do
it { should contain_service('nova-compute').with(
'name' => 'nova-compute',
'ensure' => 'stopped',
'hasstatus' => 'true',
'enable' => false
)}
it { should contain_package('nova-compute').with(
@@ -50,6 +51,7 @@ describe 'nova::compute' do
it { should contain_service('nova-compute').with(
'name' => 'nova-compute',
'ensure' => 'running',
'hasstatus' => 'true',
'enable' => true
)}
end
@@ -80,6 +82,7 @@ describe 'nova::compute' do
it { should contain_service('nova-compute').with(
'name' => 'openstack-nova-compute',
'ensure' => 'stopped',
'hasstatus' => 'true',
'enable' => false
)}
it { should contain_package('nova-compute').with_name('openstack-nova-compute') }

View File

@@ -40,6 +40,7 @@ describe 'nova::network' do
it { should contain_service('nova-network').with(
'name' => 'nova-network',
'ensure' => 'running',
'hasstatus' => 'true',
'enable' => true
)}
end
@@ -47,6 +48,7 @@ describe 'nova::network' do
it { should contain_service('nova-network').with(
'name' => 'nova-network',
'ensure' => 'stopped',
'hasstatus' => 'true',
'enable' => false
)}
end
@@ -205,6 +207,7 @@ describe 'nova::network' do
it { should contain_service('nova-network').with(
'name' => 'openstack-nova-network',
'ensure' => 'stopped',
'hasstatus' => 'true',
'enable' => false
)}
it { should contain_package('nova-network').with_name('openstack-nova-network') }

View File

@@ -13,6 +13,7 @@ describe 'nova::objectstore' do
it { should contain_service('nova-objectstore').with(
'name' => 'nova-objectstore',
'ensure' => 'stopped',
'hasstatus' => 'true',
'enable' => false
)}
it { should contain_package('nova-objectstore').with(
@@ -27,6 +28,7 @@ describe 'nova::objectstore' do
it { should contain_service('nova-objectstore').with(
'name' => 'nova-objectstore',
'ensure' => 'running',
'hasstatus' => 'true',
'enable' => true
)}
end
@@ -46,6 +48,7 @@ describe 'nova::objectstore' do
it { should contain_service('nova-objectstore').with(
'name' => 'openstack-nova-objectstore',
'ensure' => 'stopped',
'hasstatus' => 'true',
'enable' => false
)}
it { should contain_package('nova-objectstore').with_name('openstack-nova-objectstore') }

View File

@@ -13,6 +13,7 @@ describe 'nova::scheduler' do
it { should contain_service('nova-scheduler').with(
'name' => 'nova-scheduler',
'ensure' => 'stopped',
'hasstatus' => 'true',
'enable' => false
)}
it { should contain_package('nova-scheduler').with(
@@ -27,6 +28,7 @@ describe 'nova::scheduler' do
it { should contain_service('nova-scheduler').with(
'name' => 'nova-scheduler',
'ensure' => 'running',
'hasstatus' => 'true',
'enable' => true
)}
end
@@ -46,6 +48,7 @@ describe 'nova::scheduler' do
it { should contain_service('nova-scheduler').with(
'name' => 'openstack-nova-scheduler',
'ensure' => 'stopped',
'hasstatus' => 'true',
'enable' => false
)}
it { should contain_package('nova-scheduler').with_name('openstack-nova-scheduler') }

View File

@@ -29,6 +29,7 @@ describe 'nova::vncproxy' do
) }
it { should contain_service('nova-vncproxy').with(
:name => 'nova-novncproxy',
:hasstatus => 'true',
:ensure => 'running'
)}
@@ -53,6 +54,7 @@ describe 'nova::vncproxy' do
)}
it { should contain_service('nova-vncproxy').with(
:name => 'novnc',
:hasstatus => 'true',
:ensure => 'running'
)}
end

View File

@@ -13,6 +13,7 @@ describe 'nova::volume' do
it { should contain_service('nova-volume').with(
'name' => 'nova-volume',
'ensure' => 'stopped',
'hasstatus' => 'true',
'enable' => false
)}
it { should contain_package('nova-volume').with(
@@ -27,6 +28,7 @@ describe 'nova::volume' do
it { should contain_service('nova-volume').with(
'name' => 'nova-volume',
'ensure' => 'running',
'hasstatus' => 'true',
'enable' => true
)}
end
@@ -46,6 +48,7 @@ describe 'nova::volume' do
it { should contain_service('nova-volume').with(
'name' => 'openstack-nova-volume',
'ensure' => 'stopped',
'hasstatus' => 'true',
'enable' => false
)}
it { should contain_package('nova-volume').with_name('openstack-nova-volume') }