diff --git a/manifests/package/redhat.pp b/manifests/package/redhat.pp index 0a0f244..2f342d9 100644 --- a/manifests/package/redhat.pp +++ b/manifests/package/redhat.pp @@ -19,6 +19,13 @@ class nginx::package::redhat ( $package_name = 'nginx', ) { + if $::lsbmajdistrelease { + $major_dist_release = $::lsbmajdistrelease + } + else { + $major_dist_release = $::operatingsystemmajrelease + } + case $::operatingsystem { 'fedora': { # nginx.org does not supply RPMs for fedora @@ -31,9 +38,9 @@ class nginx::package::redhat ( } } default: { - case $::lsbmajdistrelease { + case $major_dist_release { 5, 6, 7: { - $os_rel = $::lsbmajdistrelease + $os_rel = $major_dist_release } default: { # Amazon uses the year as the $::lsbmajdistrelease