When switching to Puppet directory environments, you might get the following error:
This error happens because when using directory environments, the manifest entry point is $confdir/environments/<ENVIRONMENT NAME>/manifests instead of manifests/site.pp. Puppet will read all files and consider them as one big manifest. The solution is to remove from site.pp the includes to the other files in the same directory. Warning: you still need to include files in subdirectories, as Puppet will only merge files in the first level directory.
More information can be found at https://docs.puppetlabs.com/puppet/latest/reference/dirs_manifest.html