Merge pull request 'fix: variant regex results in error' (#47) from neoloc/datavol_size_pattern into develop

Reviewed-on: unkinben/puppet-prod#47
This commit is contained in:
Ben Vincent 2023-11-05 19:33:28 +09:30
commit f5ce438679

View File

@ -7,7 +7,7 @@
# $vg - Volume group name. No default.
# $pv - Physical volume, typically the disk or partition device path. No default.
# $fstype - Filesystem type for the logical volume. Defaults to 'ext3'.
# $size - Size of the logical volume. No default.
# $size - Size of the logical volume. undef = 100%FREE. Changing $size to cause a resize.
#
class profiles::base::datavol (
Enum['present', 'absent'] $ensure = 'present',
@ -16,7 +16,7 @@ class profiles::base::datavol (
String $pv = '/dev/vdb',
String $lv = 'data',
Stdlib::Absolutepath $mount = '/data',
Variant[Pattern[/^[\d+GTP%FREE]$/], Integer] $size = '100%FREE',
Optional[Variant[Pattern[/^\d+(M|G|T|P)$/], Integer]] $size = undef,
Array $mount_options = ['noatime', 'nodiratime'],
) {