From 281e111e58161502ff018baf084942365e195342 Mon Sep 17 00:00:00 2001 From: Yanis Guenane Date: Thu, 22 May 2014 09:41:27 -0400 Subject: [PATCH] Improve readability of swift::xfs Improve readability of swift::xfs using ensure_packages from the stdlib. Change-Id: I9550c6e9415e49b5363e21c73c935390c3a635e3 --- manifests/xfs.pp | 14 ++++---------- 1 file changed, 4 insertions(+), 10 deletions(-) diff --git a/manifests/xfs.pp b/manifests/xfs.pp index 9a7ddb8b..86d19fc6 100644 --- a/manifests/xfs.pp +++ b/manifests/xfs.pp @@ -2,14 +2,8 @@ # package dependencies for creating # xfs partitions class swift::xfs { - if !defined(Package['xfsprogs']){ - package { 'xfsprogs': - ensure => present - } - } - if !defined(Package['parted']){ - package { 'parted': - ensure => present - } - } + + $packages = ['xfsprogs', 'parted'] + ensure_packages($packages) + }