Skip to content

Commit

Permalink
Merge pull request #1118 from sathieu/authn_core
Browse files Browse the repository at this point in the history
Move mod_authn_core to a class
  • Loading branch information
igalic committed May 27, 2015
2 parents 421adf5 + 6f36686 commit 749b223
Show file tree
Hide file tree
Showing 4 changed files with 13 additions and 8 deletions.
1 change: 1 addition & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -560,6 +560,7 @@ There are many `apache::mod::[name]` classes within this module that can be decl
* `auth_basic`
* `auth_cas`* (see [`apache::mod::auth_cas`](#class-apachemodauthcas) below)
* `auth_kerb`
* `authn_core`
* `authn_file`
* `authnz_ldap`*
* `authz_default`
Expand Down
12 changes: 4 additions & 8 deletions manifests/default_mods.pp
Original file line number Diff line number Diff line change
Expand Up @@ -37,13 +37,12 @@
if $all {
case $::osfamily {
'debian': {
include ::apache::mod::authn_core
include ::apache::mod::reqtimeout
if versioncmp($apache_version, '2.4') >= 0 {
::apache::mod { 'authn_core': }
}
}
'redhat': {
include ::apache::mod::actions
include ::apache::mod::authn_core
include ::apache::mod::cache
include ::apache::mod::mime
include ::apache::mod::mime_magic
Expand All @@ -64,16 +63,14 @@
::apache::mod { 'substitute': }
::apache::mod { 'usertrack': }

if versioncmp($apache_version, '2.4') >= 0 {
::apache::mod { 'authn_core': }
}
else {
if versioncmp($apache_version, '2.4') < 0 {
::apache::mod { 'authn_alias': }
::apache::mod { 'authn_default': }
}
}
'freebsd': {
include ::apache::mod::actions
include ::apache::mod::authn_core
include ::apache::mod::cache
include ::apache::mod::disk_cache
include ::apache::mod::headers
Expand All @@ -91,7 +88,6 @@
::apache::mod { 'auth_digest': }
::apache::mod { 'auth_form': }
::apache::mod { 'authn_anon': }
::apache::mod { 'authn_core': }
::apache::mod { 'authn_dbm': }
::apache::mod { 'authn_socache': }
::apache::mod { 'authz_dbd': }
Expand Down
7 changes: 7 additions & 0 deletions manifests/mod/authn_core.pp
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
class apache::mod::authn_core(
$apache_version = $::apache::apache_version
) {
if versioncmp($apache_version, '2.4') >= 0 {
::apache::mod { 'authn_core': }
}
}
1 change: 1 addition & 0 deletions spec/classes/apache_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -677,6 +677,7 @@
# Assert that load files are placed for these mods, but no conf file.
[
'auth_basic',
'authn_core',
'authn_file',
'authz_groupfile',
'authz_host',
Expand Down

0 comments on commit 749b223

Please sign in to comment.