Module: Puppet::Environments::EnvironmentCreator Private

Included in:
Static
Defined in:
lib/puppet/environments.rb

This module is part of a private API. You should avoid using this module if possible, as it may be removed or be changed in the future.

Instance Method Summary collapse

Instance Method Details

#for(module_path, manifest) ⇒ Object

This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.

Create an anonymous environment.

Parameters:

  • module_path (String)

    A list of module directories separated by the PATH_SEPARATOR

  • manifest (String)

    The path to the manifest

Returns:

  • A new environment with the ‘name` `:anonymous`



24
25
26
27
28
# File 'lib/puppet/environments.rb', line 24

def for(module_path, manifest)
  Puppet::Node::Environment.create(:anonymous,
                                   module_path.split(File::PATH_SEPARATOR),
                                   manifest)
end