Skip to content

Commit b43350c

Browse files
Allow custom_config to have a string priority again
In f41251e the type was narrowed to no longer allow strings, but this can cause problems. Sorting is alphabetical and you need to format it for the correct sorting. So to make sure 2 loads before 10 you need to format it as 02. While the vhost can do some printf style magic to change 2 to 02, it must then also know what the highest number is. Otherwise 100 is sorted before 20. By allowing strings, you allow the caller to fix this. A type alias is introduced to reduce duplication and make it easier to track. Fixes: f41251e
1 parent 950cffb commit b43350c

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

manifests/custom_config.pp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -52,7 +52,7 @@
5252
Enum['absent', 'present'] $ensure = 'present',
5353
Stdlib::Absolutepath $confdir = $apache::confd_dir,
5454
Optional[String] $content = undef,
55-
Variant[Integer, Boolean] $priority = 25,
55+
Apache::Vhost::Priority $priority = 25,
5656
Optional[String] $source = undef,
5757
String $verify_command = $apache::params::verify_command,
5858
Boolean $verify_config = true,

0 commit comments

Comments
 (0)