diff --git a/manifests/default_mods.pp b/manifests/default_mods.pp index 0c7f0f62a8..23c77360c0 100644 --- a/manifests/default_mods.pp +++ b/manifests/default_mods.pp @@ -124,9 +124,6 @@ include apache::mod::setenvif include apache::mod::auth_basic - # filter is needed by mod_deflate - include apache::mod::filter - # authz_core is needed for 'Require' directive ::apache::mod { 'authz_core': id => 'authz_core_module', @@ -145,16 +142,10 @@ ::apache::mod { 'authz_core': id => 'authz_core_module', } - - # filter is needed by mod_deflate - include apache::mod::filter } else { # authz_core is needed for 'Require' directive ::apache::mod { 'authz_core': id => 'authz_core_module', } - - # filter is needed by mod_deflate - include apache::mod::filter } } diff --git a/manifests/mod/deflate.pp b/manifests/mod/deflate.pp index c5a6aaac8a..cf5f9e0b1f 100644 --- a/manifests/mod/deflate.pp +++ b/manifests/mod/deflate.pp @@ -24,6 +24,8 @@ } ) { include apache + include apache::mod::filter + ::apache::mod { 'deflate': } file { 'deflate.conf': diff --git a/spec/classes/mod/deflate_spec.rb b/spec/classes/mod/deflate_spec.rb index 96ecaa0f82..d9f4056bcc 100644 --- a/spec/classes/mod/deflate_spec.rb +++ b/spec/classes/mod/deflate_spec.rb @@ -5,6 +5,7 @@ # This function is called inside the OS specific contexts def general_deflate_specs it { is_expected.to contain_apache__mod('deflate') } + it { is_expected.to contain_class('apache::mod::filter') } expected = "AddOutputFilterByType DEFLATE application/rss+xml\n"\ "AddOutputFilterByType DEFLATE application/x-javascript\n"\