From 2ed2cf2ca5dbb396c1326aab13e1da6de3174615 Mon Sep 17 00:00:00 2001 From: Sander Cornelissen Date: Fri, 28 Aug 2020 08:15:42 +0200 Subject: [PATCH] Use $facts to retrieve fact --- manifests/volume.pp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/manifests/volume.pp b/manifests/volume.pp index 5344067a..a3fcf5da 100644 --- a/manifests/volume.pp +++ b/manifests/volume.pp @@ -151,11 +151,11 @@ command => "${::gluster_binary} volume start ${title}", require => Exec["gluster create volume ${title}"], } - } elsif $already_exists { + } elsif $already_exists and "gluster_volume_${title}_bricks" in $facts { # this volume exists # our fact lists bricks comma-separated, but we need an array - $vol_bricks = split( getvar( "::gluster_volume_${title}_bricks" ), ',') + $vol_bricks = split( $facts["gluster_volume_${title}_bricks"], ',') if $bricks != $vol_bricks { # this resource's list of bricks does not match the existing # volume's list of bricks