calling function in same manifest and different puppet file

asked 2018-06-19 09:30:58 -0600

vglad gravatar image

I have my main file within my manifest. To divide the work, I am creating additional files. I want these additional files to return a string in a certain format., I therefore created a function, multiple files with multiple functions and want to invoke these functions from the main file and get the results.

util.pp

functions mymodule::retrieveData() >> String {
   ..   
  "${results}" 
}

main file:

require util.pp
$items = retrieveData()

The issue lies in

  1. getting access to the function in the main puppet file
  2. invoking it to get the results
edit retag flag offensive close merge delete