sort_merge_arrays setting

We could also sort the merged arrays with the sort_merge_arrays setting, and remove the data that matches knockout_prefix. An array member or entire keys can be removed from the resulting hash:

 lookup({   'name'  => 'classification',   'merge' => {     'strategy'          => 'deep',     'knockout_prefix'   => '--',     ‘sort_merge_arrays’ => true,   }, }) 

Get Mastering Puppet 5 now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.