How to Use Puppet python module in manifest file

by bobby   Last Updated August 01, 2020 14:00 PM

I am writing a puppet manifest file to install python and pymongo.
This python module is installed on the server, link shown below https://forge.puppetlabs.com/stankevich/python

Here is the manifest file I created. But it say unknown class and resource . Please suggest what wrong in the syntax.

class { 'python' :
  version           => 'system',
  pip               => 'present'
}

  python::pip { 'pymongo' :
    pkgname         => 'pymongo',
    ensure          => '2.7',
  }

It says Unknown class: 'python and Unknown resource type: 'python::pip'

Thanks,

Tags : puppet python


Answers 1


Looks like stankevich-python is not installed in your modulepath. Did you run:

puppet module install stankevich-python

You can check you modulepath on Puppet master using:

puppet config print modulepath --section master
Tombart
Tombart
March 13, 2016 13:10 PM

Related Questions


Want to learn devops have experience as Linux Admin

Updated January 07, 2016 09:00 AM

deploying Python code with Puppet

Updated November 29, 2017 07:00 AM

Update Hiera by Python web service

Updated August 28, 2017 13:00 PM

Puppet Ochestration: get results of puppet run

Updated September 22, 2015 00:00 AM

puppet windows add wait or sleep

Updated June 01, 2017 16:00 PM