summaryrefslogtreecommitdiff
path: root/manifests
diff options
context:
space:
mode:
authorDavide Mendolia <idaf1er@gmail.com>2014-01-02 23:11:52 +0100
committerDavide Mendolia <idaf1er@gmail.com>2014-01-02 23:11:52 +0100
commit0e72400bfd33df651c23f2f7c71c3c5cf8bfe815 (patch)
tree226a50fb0af9d25af886b9318566951e30ebca4a /manifests
parent80ee7bcdf5ca4287432da9d2e06c3bb6c1dd8a91 (diff)
Replace operatingsystem test for osfamily to increase os support
Diffstat (limited to 'manifests')
-rw-r--r--manifests/init.pp4
-rw-r--r--manifests/install.pp6
2 files changed, 5 insertions, 5 deletions
diff --git a/manifests/init.pp b/manifests/init.pp
index 9fe0420..54dae45 100644
--- a/manifests/init.pp
+++ b/manifests/init.pp
@@ -44,8 +44,8 @@ class python (
) {
# Module compatibility check
- $compatible = [ 'Debian', 'Ubuntu', 'CentOS', 'RedHat', 'Scientific' ]
- if ! ($::operatingsystem in $compatible) {
+ $compatible = [ 'debian', 'redhat']
+ if ! ($::osfamily in $compatible) {
fail("Module is not compatible with ${::operatingsystem}")
}
diff --git a/manifests/install.pp b/manifests/install.pp
index bb5f090..dc9bd76 100644
--- a/manifests/install.pp
+++ b/manifests/install.pp
@@ -20,9 +20,9 @@ class python::install {
default => "python${python::version}",
}
- $pythondev = $::operatingsystem ? {
- /(?i:RedHat|CentOS|Fedora|Scientific)/ => "${python}-devel",
- /(?i:Debian|Ubuntu)/ => "${python}-dev"
+ $pythondev = $::osfamily ? {
+ redhat => "${python}-devel",
+ debian => "${python}-dev"
}
$dev_ensure = $python::dev ? {