From b35fd045ddfc0def1c72f6ab6f0905ce88142ed1 Mon Sep 17 00:00:00 2001 From: Martin Alfke Date: Fri, 18 Oct 2024 10:22:20 +0200 Subject: [PATCH] Allow usage of extent_size especially when using lvm::volume_groups from hiera --- manifests/volume_group.pp | 16 +++++++++++----- 1 file changed, 11 insertions(+), 5 deletions(-) diff --git a/manifests/volume_group.pp b/manifests/volume_group.pp index 88158cb2..3a8c4243 100644 --- a/manifests/volume_group.pp +++ b/manifests/volume_group.pp @@ -23,12 +23,17 @@ # actual PV device is if the property value is a symlink, like # `/dev/disk/by-path/xxxx -> ../../sda`. # +# @param extent_size (optional) +# Set the required extent_size. Value can be Integer (`64`) +# or String (`4M`). +# define lvm::volume_group ( - Variant[Hash, Array, String] $physical_volumes, - Boolean $createonly = false, - Enum['present', 'absent'] $ensure = present, - Hash $logical_volumes = {}, - Boolean $followsymlinks = false, + Variant[Hash, Array, String] $physical_volumes, + Boolean $createonly = false, + Enum['present', 'absent'] $ensure = present, + Hash $logical_volumes = {}, + Boolean $followsymlinks = false, + Optional[Variant[String[1], Integer]] $extent_size = undef, ) { if $physical_volumes.is_a(Hash) { create_resources( @@ -50,6 +55,7 @@ createonly => $createonly, physical_volumes => $physical_volumes, followsymlinks => $followsymlinks, + extent_size => $extent_size, } create_resources(