I am writing a puppet manifest file to install python libraries through pip install.
This python module is installed on the server, link shown below https://forge.puppetlabs.com/stankevich/python
I've installed the module by doing
puppet module install stankevich-python
Here is the manifest file I created in my sites.pp
class { 'python' :
version => 'system',
pip => 'present'
}
python::pip { 'reportlab' :
pkgname => 'reportlab',
ensure => latest,
}
Errors on my agent state that 'python' resource could not be found
Error: Could not retrieve catalog from remote server: Error 500 on SERVER: {"message":"Server Error: Evaluation Error: Error while evaluating a Resource Statement, Could not find declared class python at /etc/puppetlabs/code/environments/production/manifests/site.pp:6:1 on node dev1","issue_kind":"RUNTIME_ERROR","stacktrace":["Warning: The 'stacktrace' property is deprecated and will be removed in a future version of Puppet. For security reasons, stacktraces are not returned with Puppet HTTP Error responses."]}
However, I've verified my module is there,
$ puppet module list
/home/ubuntu/.puppetlabs/etc/code/modules
├── puppetlabs-stdlib (v4.16.0)
├── stahnma-epel (v1.2.2)
└── stankevich-python (v1.18.2)
Any advice appreciated. Thanks.
My bad. I need to run
puppet module install stankevich-python
in root, which I didn't. After doing that it works.
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.