Clean up direct dependencies on puppetlabs-apache

This change removes direct reference to some classes in
puppetlabs-apache. Details are explained below.

- The api class doesn't need access to anything defined in
  apache::params

- The following classes are included by the openstacklib::wsgi::apache
  resource type, and current inclusions are just redundant.

Change-Id: I357f4fd2d0a7cb4782ed83a328a3168129be290f
This commit is contained in:
Takashi Kajinami 2021-12-08 22:15:29 +09:00
parent b1e2e61cc9
commit 8d114592bb
2 changed files with 1 additions and 15 deletions

View File

@ -121,11 +121,7 @@ class designate::wsgi::apache (
include designate::deps
include designate::params
include apache
include apache::mod::wsgi
if $ssl {
include apache::mod::ssl
}
::openstacklib::wsgi::apache { 'designate_wsgi':
bind_host => $bind_host,
bind_port => $port,

View File

@ -5,9 +5,6 @@ describe 'designate::wsgi::apache' do
shared_examples_for 'apache serving designate with mod_wsgi' do
context 'with default parameters' do
it { is_expected.to contain_class('designate::params') }
it { is_expected.to contain_class('apache') }
it { is_expected.to contain_class('apache::mod::wsgi') }
it { is_expected.to_not contain_class('apache::mod::ssl') }
it { is_expected.to contain_openstacklib__wsgi__apache('designate_wsgi').with(
:bind_port => 9001,
:group => 'designate',
@ -47,9 +44,6 @@ describe 'designate::wsgi::apache' do
}
end
it { is_expected.to contain_class('designate::params') }
it { is_expected.to contain_class('apache') }
it { is_expected.to contain_class('apache::mod::wsgi') }
it { is_expected.to contain_class('apache::mod::ssl') }
it { is_expected.to contain_openstacklib__wsgi__apache('designate_wsgi').with(
:bind_host => '10.42.51.1',
:bind_port => 12345,
@ -93,15 +87,11 @@ describe 'designate::wsgi::apache' do
case facts[:osfamily]
when 'Debian'
{
:httpd_service_name => 'apache2',
:httpd_ports_file => '/etc/apache2/ports.conf',
:wsgi_script_path => '/usr/lib/cgi-bin/designate',
:wsgi_script_source => '/usr/bin/designate-api-wsgi'
}
when 'RedHat'
{
:httpd_service_name => 'httpd',
:httpd_ports_file => '/etc/httpd/conf/ports.conf',
:wsgi_script_path => '/var/www/cgi-bin/designate',
:wsgi_script_source => '/usr/bin/designate-api-wsgi'
}