Skip to content
Snippets Groups Projects
Commit 7824709c authored by Thomas Bellman's avatar Thomas Bellman
Browse files

Add variable $standard_version to apache class.

This will hold the version (major.minor, e.g. "2.2" or "2.4") of
Apache httpd that comes default with each operating system, so that
other parts of this module can do things differently depending on
the httpd version.  Currently we know which httpd comes with EL-6
and EL-7.

Note that this might not be the version that actually gets installed,
if the user has extra package repositories configured.  We could
possibly let users declare which version is used with a parametrized
class, but this will have to do for now.
parent eeb80701
No related branches found
No related tags found
No related merge requests found
...@@ -15,6 +15,23 @@ class apache ...@@ -15,6 +15,23 @@ class apache
$configfile = '/etc/httpd/conf/httpd.conf' $configfile = '/etc/httpd/conf/httpd.conf'
$configdir = '/etc/httpd/conf.d' $configdir = '/etc/httpd/conf.d'
$logdir = '/var/log/httpd' $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 = ''
}
}
} }
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment