Using Foreman 1.24 with latest Puppet 6.13 from Puppetlabs repositories, running the server and agents on Ubuntu 16.04. Just tinkering about with creating puppet classes in the default production environment in /etc/puppetlabs/code/environments/production. Surely, I can create some puppet classes directly under manifests, with each class in its own file, then import the classes, and assign to host groups in Foreman. However, should I rather be creating classes as Puppet modules then importing them?
Sorry for the confusion. I am just trying to get a good overview on how to do it in the CLI, together with the Foreman GUI and getting to know “best practices” .