Skip to content

Commit

Permalink
Include apache::mod::filter in apache::mod::deflate
Browse files Browse the repository at this point in the history
This was already done in default mods, but this removes duplication and
allows use without default mods.
  • Loading branch information
ekohl committed Jan 16, 2023
1 parent 176ab02 commit 210f319
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 9 deletions.
9 changes: 0 additions & 9 deletions manifests/default_mods.pp
Original file line number Diff line number Diff line change
Expand Up @@ -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',
Expand All @@ -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
}
}
2 changes: 2 additions & 0 deletions manifests/mod/deflate.pp
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,8 @@
}
) {
include apache
include apache::mod::filter

::apache::mod { 'deflate': }

file { 'deflate.conf':
Expand Down
1 change: 1 addition & 0 deletions spec/classes/mod/deflate_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -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"\
Expand Down

0 comments on commit 210f319

Please sign in to comment.