From 31e44bbcb053b3d057c0ca72669b6f0e860f2039 Mon Sep 17 00:00:00 2001 From: Clark Boylan Date: Thu, 24 Aug 2017 13:46:04 -0700 Subject: [PATCH] Allow multiple places to install curl Curl is an important package that we end up needing in a few places. To avoid puppet unique name conflicts with the package "curl" only define the curl package resource if it isn't already defined. This allows us to define it in multiple places that may or may not overlap depending on how hosts are constructed. Change-Id: Icd0c652ff2f522ce2ea9086965f53e1a03f0d4fd --- manifests/init.pp | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/manifests/init.pp b/manifests/init.pp index b72fb72..815a16d 100644 --- a/manifests/init.pp +++ b/manifests/init.pp @@ -40,8 +40,10 @@ class ethercalc ( mode => '0664', } - package { 'curl': - ensure => present, + if !defined(Package['curl']) { + package { 'curl': + ensure => present, + } } anchor { 'nodejs-package-install': }