(PUP-1676) Puppet::Settings retrieves directory environment settings

During a Puppet[:setting] call, legacy environment settings would be
loaded from a puppet.conf stanza.  But settings from directory
environments would never be seen.  Areas in the codebase could obtain
per environment settings by looking them up directly from an
environment.  However a call to puppet config or to an application with
--configprint, would return the default modulepath if redirected to a
directory environment using the --environment setting.

A ValuesFromCurrentEnvironment class has been added to Settings to
lookup environment settings not found in puppet.conf if there is a match
with the :current_environment from the Context.

Because of the need to access a global modulepath for environment and
directory loader construction, a setting, :basemodulepath, has been
added, so that we can initialize without fear of recursing infinitely
looking up :modulepath.

The possibility for recursion has been there since at least 3.0.0:

[legacy]
modulepath=/foo:$modulepath

would overflow the stack. It could now be:

[legacy]
modulepath=/foo:$basemodulepath