puppetlabs/puppet — pull request #3238 by jmkeyes (2014-10-26 21:59:41+00:00)
Title: (PUP-3547) File Server Mounts Should Support Directory Environments

**tl;dr**: I'd like to be able to serve files from the file server and interpolate the agent's environment into the mount path.

I use r10k to deploy directory environments for a Puppet Master that manages a small, but growing set of VMware VMs on ESXi. I have a set of files that are supplied by an upstream vendor that do not fit the typical "build a module" approach.

For example:
* I need to keep track of multiple tarballs of VMware Tools that can be utilized by the [CraigWatson1987/vmwaretools](https://forge.puppetlabs.com/CraigWatson1987/vmwaretools) module.
* I need to keep track of multiple executables to install Splunk forwarders and indexers that can be utilized by the [puppetlabs/splunk](http://forge.puppetlabs.com/puppetlabs/splunk) module.

I'd like to be able to serve those files through a file server mount on the Puppet Master that supports directory environments.

The patch I've developed adds an additional token, `%e`, in the mount path and should interpolate the agent's current environment into the expanded mount path. This placeholder is optional and not included by default.

In turn, this should allow me to include a `files` folder within each directory environment and serve files held in that mount point.