Skip to content

Commit

Permalink
Merge pull request #908 from igalic/mod_ver
Browse files Browse the repository at this point in the history
MODULES-1446: mod_version is now builtin
  • Loading branch information
Morgan Haskel committed Nov 4, 2014
2 parents 1101dae + be2bfab commit d81d173
Show file tree
Hide file tree
Showing 3 changed files with 22 additions and 4 deletions.
10 changes: 10 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,7 @@
* [Class: apache::mod::negotiation](#class-apachemodnegotiation)
* [Class: apache::mod::deflate](#class-apachemoddeflate)
* [Class: apache::mod::reqtimeout](#class-apachemodreqtimeout)
* [Class: apache::mod::version](#class-apachemodversion)
* [Defined Type: apache::vhost](#defined-type-apachevhost)
* [Parameter: `directories` for apache::vhost](#parameter-directories-for-apachevhost)
* [SSL parameters for apache::vhost](#ssl-parameters-for-apachevhost)
Expand Down Expand Up @@ -823,6 +824,15 @@ mod_reqtimeout configuration.
}
```

####Class: `apache::mod::reqtimeout`

This wrapper around mod_version warns on Debian and Ubuntu systems with Apache httpd 2.4
about loading mod_version, as on these platforms it's already built-in.

```puppet
include '::apache::mod::version'
```

#####`timeouts`

A string or an array that sets the `RequestReadTimeout` option. Defaults to
Expand Down
8 changes: 4 additions & 4 deletions manifests/default_mods.pp
Original file line number Diff line number Diff line change
Expand Up @@ -36,10 +36,11 @@
include ::apache::mod::cache
include ::apache::mod::mime
include ::apache::mod::mime_magic
include ::apache::mod::vhost_alias
include ::apache::mod::suexec
include ::apache::mod::rewrite
include ::apache::mod::speling
include ::apache::mod::suexec
include ::apache::mod::version
include ::apache::mod::vhost_alias
::apache::mod { 'auth_digest': }
::apache::mod { 'authn_anon': }
::apache::mod { 'authn_dbm': }
Expand All @@ -51,7 +52,6 @@
::apache::mod { 'logio': }
::apache::mod { 'substitute': }
::apache::mod { 'usertrack': }
::apache::mod { 'version': }

if versioncmp($apache_version, '2.4') >= 0 {
::apache::mod { 'authn_core': }
Expand All @@ -71,6 +71,7 @@
include ::apache::mod::reqtimeout
include ::apache::mod::rewrite
include ::apache::mod::userdir
include ::apache::mod::version
include ::apache::mod::vhost_alias
include ::apache::mod::speling

Expand All @@ -93,7 +94,6 @@
::apache::mod { 'logio': }
::apache::mod { 'unique_id': }
::apache::mod { 'usertrack': }
::apache::mod { 'version': }
}
default: {}
}
Expand Down
8 changes: 8 additions & 0 deletions manifests/mod/version.pp
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
class apache::mod::version {

if ($::osfamily == 'debian' and versioncmp($apache_version, '2.4') >= 0) {
warning("${module_name}: module version_module is built-in and can't be loaded")
} else {
::apache::mod { 'version': }
}
}

0 comments on commit d81d173

Please sign in to comment.