diff --git a/manifests/init.pp b/manifests/init.pp index aeb119753606a1f2c125e3b6d61c1d3116a27687..9e7aa273569fbb34f9ab7c168db2d82cee5a01f3 100644 --- a/manifests/init.pp +++ b/manifests/init.pp @@ -15,6 +15,23 @@ class apache $configfile = '/etc/httpd/conf/httpd.conf' $configdir = '/etc/httpd/conf.d' $logdir = '/var/log/httpd' + + # The version of httpd that comes standard with an OS. + # This might not be the version that will actually be installed, though, + # but it is the best we can do. + # FIXME: Maybe allow users to override this with a parametrized class? + case "${::operatingsystem}:${::operatingsystemrelease}" + { + /^(RedHat|CentOS|Scientific):6(\..*)?$/: { + $standard_version = '2.2' + } + /^(RedHat|CentOS|Scientific):7(\..*)?$/: { + $standard_version = '2.4' + } + default: { + $standard_version = '' + } + } }