ReleaseEngineering/PuppetAgain/Modules/python: Difference between revisions

no edit summary
(add a require parameters)
No edit summary
Line 1: Line 1:
This module handles installing Python virtualenvs containing Python packages.  See [[ReleaseEngineering/How To/Install a Python Virtualenv with Puppet]] for a tutorial reference to using the module.
This module handles all things Python.


= Usage =
= python::user_pip_conf =
 
This define sets up a .pip/pip.conf for the named user that directs pip to install from the [ReleaseEngineering/PuppetAgain/Python|python] repository, including searching all puppetmasters in case one is down.  It takes an optional ''$homedir'' to specify the user's homedir, with the default being in ''/home''.  This define should generally be used from ''user'' module classes.  See e.g., ''user::root'' for an example.
 
= python::virtualenv =
 
This class installs Python virtualenvs containing Python packages.  See [[ReleaseEngineering/How To/Install a Python Virtualenv with Puppet]] for a tutorial reference to using the module.
 
== Usage ==


The main interface used here is <tt>python::virtualenv</tt>.  It takes the following parameters:
The main interface used here is <tt>python::virtualenv</tt>.  It takes the following parameters:
Line 13: Line 21:
Note that the python, user, and group attributes only have an effect when the virtualenv is created.  Packages can be added to the packages list, or their versions changed, but removing a package from the list will not result in puppet removing it from the virtualenv.
Note that the python, user, and group attributes only have an effect when the virtualenv is created.  Packages can be added to the packages list, or their versions changed, but removing a package from the list will not result in puppet removing it from the virtualenv.


= Example =
== Example ==
   python::virtualenv {
   python::virtualenv {
       "/path/to/virtualenv":
       "/path/to/virtualenv":
canmove, Confirmed users
1,394

edits