Hi,
I am looking for the syntax to set the content for a File resource from hiera. Specifically I want to set the template being used:
# Puppet
class test (
$file_content = undef,
){
file{'/tmp/testfile':
ensure => file,
content => $file_content,
}
}
# Hiera
---
test::file_content: template('modules/test/test.erb')
Since Hiera is returning a string, the template function is not being evaluated.
I am pretty sure I saw this being done somewhere, but I cannot figure out the correct syntax anymore.
↧