Remove usage of custom os_package_type fact
Currently we support usage of distro packages only, and this custom fact can be simply replaced by the default fact. Change-Id: Ie5516c8aab24fa32a0490bdfd116ce46bcc48c70
This commit is contained in:
parent
9c63febd4e
commit
0cf84e165d
@ -760,7 +760,7 @@ and usage of a quoted value is deprecated.')
|
||||
|
||||
if $compress_offline {
|
||||
Concat<| tag == 'django-config' |> ~> Exec['refresh_horizon_django_compress']
|
||||
if $::os_package_type == 'rpm' {
|
||||
if $::osfamily == 'RedHat' {
|
||||
Concat<| tag == 'django-config' |> ~> Exec['refresh_horizon_django_cache'] -> Exec['refresh_horizon_django_compress']
|
||||
}
|
||||
}
|
||||
|
@ -38,8 +38,8 @@ class horizon::params {
|
||||
$heat_dashboard_package_name = 'python3-heat-dashboard'
|
||||
$manila_dashboard_package_name = 'python3-manila-dashboard'
|
||||
$octavia_dashboard_package_name = 'python3-octavia-dashboard'
|
||||
case $::os_package_type {
|
||||
'debian': {
|
||||
case $::operatingsystem {
|
||||
'Debian': {
|
||||
$package_name = 'openstack-dashboard-apache'
|
||||
$httpd_config_file = '/etc/apache2/sites-available/openstack-dashboard-alias-only.conf'
|
||||
}
|
||||
|
@ -32,7 +32,7 @@ describe 'horizon' do
|
||||
:refreshonly => true,
|
||||
})}
|
||||
it {
|
||||
if facts[:os_package_type] == 'rpm'
|
||||
if facts[:osfamily] == 'RedHat'
|
||||
is_expected.to contain_concat(platforms_params[:config_file]).that_notifies('Exec[refresh_horizon_django_cache]')
|
||||
is_expected.to contain_concat(platforms_params[:config_file]).that_notifies('Exec[refresh_horizon_django_compress]')
|
||||
else
|
||||
@ -767,7 +767,7 @@ describe 'horizon' do
|
||||
let(:platforms_params) do
|
||||
case facts[:osfamily]
|
||||
when 'Debian'
|
||||
if facts[:os_package_type] == 'debian'
|
||||
if facts[:operatingsystem] == 'Debian'
|
||||
{ :config_file => '/etc/openstack-dashboard/local_settings.py',
|
||||
:conf_d_dir => '/etc/openstack-dashboard/local_settings.d',
|
||||
:package_name => 'openstack-dashboard-apache',
|
||||
|
@ -520,10 +520,6 @@ describe 'horizon::wsgi::apache' do
|
||||
}).each do |os,facts|
|
||||
context "on #{os}" do
|
||||
let (:facts) do
|
||||
if facts[:operatingsystem] == 'Debian'
|
||||
facts.merge!( :os_package_type => 'debian' )
|
||||
end
|
||||
|
||||
facts.merge!(OSDefaults.get_facts({
|
||||
:fqdn => 'some.host.tld',
|
||||
:concat_basedir => '/var/lib/puppet/concat',
|
||||
|
@ -45,10 +45,6 @@ describe 'horizon::dashboard' do
|
||||
end
|
||||
|
||||
shared_examples 'horizon::dashboard on Debian' do
|
||||
before do
|
||||
facts.merge!({:os_package_type => 'debian'})
|
||||
end
|
||||
|
||||
context 'with default' do
|
||||
it { should contain_package('python3-heat-dashboard').with(
|
||||
:ensure => 'installed',
|
||||
|
Loading…
x
Reference in New Issue
Block a user