Quantcast
Channel: Ask Puppet: Puppet DevOps Q&A Community - RSS feed
Viewing all articles
Browse latest Browse all 6104

How to allow a source in a custom module? I.e. accept and use a URI that points to a file server mount point

$
0
0
The `file` resource type supports the `source` attribute. This can be used to pull files from Puppet file server mount points. I.e. I could specify `puppet:///mymount/folder/file.ext` and the file resource will create a file using that file as a resource. However what I want to do is read the contents of that file into a variable. The `file` function supports reading of files into a variable, but only out of modules it seems, and not out of file server mount points. Is there a way to add the `source` attribute to my own module or function and leverage Puppet's existing code for doing this? Thanks in advance.

Viewing all articles
Browse latest Browse all 6104

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>