# Define file array to be used in resource ordering

Hi,

Is there a way to group all the file resources together to allow them to be specified as one variable in the ordering?

eg.

Package["$package_name"] -> File['$config_files'] -> Service["$service_name"] Thanks edit retag close merge delete ## Comments 1 I cant think of a way just with the puppet language. There are resource collectors https://docs.puppet.com/puppet/latest/reference/lang_collectors.html Does that solve your situation? ( 2016-10-29 11:43:57 -0500 )edit I've never tried resource collectors with File. I'll give it a go. Thanks ( 2016-10-29 12:09:47 -0500 )edit ## 1 answer Sort by » oldest newest most voted I am using tags and resource collectors for this: on the file resources set the metaparameter 'tag': tag => "$service_config",

and then the ordering line should look like this

Package["$package_name"] -> File<| tag == "$service_config" |>  -> Service["\$service_name"]
more