From 45f612df4100b60746624e930bd17abc209d52d6 Mon Sep 17 00:00:00 2001 From: erik-smit Date: Fri, 15 Feb 2013 14:49:27 +0100 Subject: Implement osfamily (fixing scientific linux support), and make sure unsupported distros fail predictably --- manifests/server/service.pp | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) (limited to 'manifests') diff --git a/manifests/server/service.pp b/manifests/server/service.pp index 6aa1ef9..2c6f590 100644 --- a/manifests/server/service.pp +++ b/manifests/server/service.pp @@ -1,7 +1,8 @@ class samba::server::service ($ensure = running, $enable = true) { - case $operatingsystem { - centos, redhat: { $service_name = 'smb' } - debian, ubuntu: { $service_name = 'smbd' } + case $::osfamily { + Redhat: { $service_name = 'smb' } + Debian: { $service_name = 'smbd' } + default: { fail("$::osfamily is not supported by this module.") } } service { "$service_name" : -- cgit v1.2.3