Merge "Tag all Heat packages"
This commit is contained in:
commit
9a851c5f6c
@ -76,6 +76,7 @@ class heat::api (
|
||||
package { 'heat-api':
|
||||
ensure => installed,
|
||||
name => $::heat::params::api_package_name,
|
||||
tag => 'openstack',
|
||||
}
|
||||
|
||||
if $manage_service {
|
||||
|
@ -79,6 +79,7 @@ class heat::api_cfn (
|
||||
package { 'heat-api-cfn':
|
||||
ensure => installed,
|
||||
name => $::heat::params::api_cfn_package_name,
|
||||
tag => 'openstack',
|
||||
}
|
||||
|
||||
if $manage_service {
|
||||
|
@ -78,6 +78,7 @@ class heat::api_cloudwatch (
|
||||
package { 'heat-api-cloudwatch':
|
||||
ensure => installed,
|
||||
name => $::heat::params::api_cloudwatch_package_name,
|
||||
tag => 'openstack',
|
||||
}
|
||||
|
||||
if $manage_service {
|
||||
|
@ -16,6 +16,7 @@ class heat::client (
|
||||
package { 'python-heatclient':
|
||||
ensure => $ensure,
|
||||
name => $::heat::params::client_package_name,
|
||||
tag => 'openstack',
|
||||
}
|
||||
|
||||
}
|
||||
|
@ -76,6 +76,7 @@ class heat::engine (
|
||||
package { 'heat-engine':
|
||||
ensure => installed,
|
||||
name => $::heat::params::engine_package_name,
|
||||
tag => 'openstack',
|
||||
notify => Exec['heat-dbsync'],
|
||||
}
|
||||
|
||||
|
@ -289,6 +289,7 @@ class heat(
|
||||
package { 'heat-common':
|
||||
ensure => $package_ensure,
|
||||
name => $::heat::params::common_package_name,
|
||||
tag => 'openstack',
|
||||
}
|
||||
|
||||
Package['heat-common'] -> Heat_config<||>
|
||||
@ -493,6 +494,7 @@ class heat(
|
||||
package {'heat-backend-package':
|
||||
ensure => present,
|
||||
name => $backend_package,
|
||||
tag => 'openstack',
|
||||
}
|
||||
}
|
||||
|
||||
|
45
spec/classes/heat_client_spec.rb
Normal file
45
spec/classes/heat_client_spec.rb
Normal file
@ -0,0 +1,45 @@
|
||||
require 'spec_helper'
|
||||
|
||||
describe 'heat::client' do
|
||||
|
||||
let :params do
|
||||
{}
|
||||
end
|
||||
|
||||
let :default_params do
|
||||
{ :package_ensure => 'present' }
|
||||
end
|
||||
|
||||
shared_examples_for 'heat client' do
|
||||
let :p do
|
||||
default_params.merge(params)
|
||||
end
|
||||
|
||||
it { is_expected.to contain_class('heat::params') }
|
||||
|
||||
it 'installs heat client package' do
|
||||
is_expected.to contain_package('python-heatclient').with(
|
||||
:name => 'python-heatclient',
|
||||
:ensure => p[:package_ensure],
|
||||
:tag => 'openstack'
|
||||
)
|
||||
end
|
||||
|
||||
end
|
||||
|
||||
context 'on Debian platform' do
|
||||
let :facts do
|
||||
{ :osfamily => 'Debian' }
|
||||
end
|
||||
|
||||
it_configures 'heat client'
|
||||
end
|
||||
|
||||
context 'on RedHat platform' do
|
||||
let :facts do
|
||||
{ :osfamily => 'RedHat' }
|
||||
end
|
||||
|
||||
it_configures 'heat client'
|
||||
end
|
||||
end
|
@ -42,7 +42,12 @@ describe 'heat::engine' do
|
||||
default_params.merge(params)
|
||||
end
|
||||
|
||||
it { is_expected.to contain_package('heat-engine').with_name(os_params[:package_name]) }
|
||||
it { is_expected.to contain_package('heat-engine').with(
|
||||
:ensure => 'installed',
|
||||
:name => os_params[:package_name],
|
||||
:tag => 'openstack',
|
||||
:notify => 'Exec[heat-dbsync]'
|
||||
) }
|
||||
|
||||
it { is_expected.to contain_service('heat-engine').with(
|
||||
:ensure => (expected_params[:manage_service] && expected_params[:enabled]) ? 'running' : 'stopped',
|
||||
|
@ -117,7 +117,8 @@ describe 'heat' do
|
||||
it 'installs heat common package' do
|
||||
is_expected.to contain_package('heat-common').with(
|
||||
:ensure => 'present',
|
||||
:name => platform_params[:common_package_name]
|
||||
:name => platform_params[:common_package_name],
|
||||
:tag => 'openstack'
|
||||
)
|
||||
end
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user