In general, the loading/import/namespacing mechanism is really something
that I cannot wrap my head around, even after reading the relevant sections
in the documentation.
Specifically, I'm trying to put together a module. I believe I have the
correct module structure:
$ find
.
./test.pp
./graphite
./graphite/manifests
./graphite/manifests/init.pp
./graphite/files
./graphite/files/local_settings.py
The test.pp file looks like this:
include graphite
This will not find the module I have placed in the same directory. If I
import the module explicitly, it still does not work:
import 'graphite'
include graphite
This does work in sofar as that the script runs a good while:
import 'graphite/manifests/init.pp'
include graphite
However, in that case, it isn't able to resolve puppet:// urls:
Could not evaluate: Could not retrieve information from environment
production source(s)
The only way I can get this to work is:
sudo puppet apply --modulepath=. test.pp
Is that right? Shouldn't there be a simpler way?
--
You received this message because you are subscribed to the Google Groups
"Puppet Users" group.
To view this discussion on the web visit
https://groups.google.com/d/msg/puppet-users/-/1PmY6CcY4xcJ.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to
[email protected].
For more options, visit this group at
http://groups.google.com/group/puppet-users?hl=en.