48 lines
4.7 KiB
HTML
48 lines
4.7 KiB
HTML
<?xml version="1.0" encoding="UTF-8"?>
|
||
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"><html xmlns="http://www.w3.org/1999/xhtml"><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /><title>cdist-type__pyvenv(7)</title><link rel="stylesheet" type="text/css" href="docbook-xsl.css" /><meta name="generator" content="DocBook XSL Stylesheets V1.76.1" /></head><body><div xml:lang="en" class="article" title="cdist-type__pyvenv(7)" lang="en"><div class="titlepage"><div><div><h2 class="title"><a id="idp64746576"></a>cdist-type__pyvenv(7)</h2></div><div><div class="author"><h3 class="author"><span class="firstname">Darko</span> <span class="surname">Poljak</span></h3><code class="email"><<a class="email" href="mailto:darko.poljak--@--gmail.com">darko.poljak--@--gmail.com</a>></code></div></div></div><hr /></div><div class="toc"><p><strong>Table of Contents</strong></p><dl><dt><span class="section"><a href="#_name">1. NAME</a></span></dt><dt><span class="section"><a href="#_description">2. DESCRIPTION</a></span></dt><dt><span class="section"><a href="#_required_parameters">3. REQUIRED PARAMETERS</a></span></dt><dt><span class="section"><a href="#_optional_parameters">4. OPTIONAL PARAMETERS</a></span></dt><dt><span class="section"><a href="#_examples">5. EXAMPLES</a></span></dt><dt><span class="section"><a href="#_see_also">6. SEE ALSO</a></span></dt><dt><span class="section"><a href="#_copying">7. COPYING</a></span></dt></dl></div><div class="section" title="1. NAME"><div class="titlepage"><div><div><h2 class="title" style="clear: both"><a id="_name"></a>1. NAME</h2></div></div></div><p>cdist-type__pyvenv - Create or remove python virtual environment</p></div><div class="section" title="2. DESCRIPTION"><div class="titlepage"><div><div><h2 class="title" style="clear: both"><a id="_description"></a>2. DESCRIPTION</h2></div></div></div><p>This cdist type allows you to create or remove python virtual
|
||
environment using pyvenv.
|
||
It assumes pyvenv is already installed. Concrete package depends
|
||
on concrete OS and/or OS version/distribution.
|
||
Ensure this for e.g. in your init manifest as in the following example:</p><pre class="screen">case "$__target_host" in
|
||
localhost)
|
||
__package python3-venv --state present
|
||
require="__package/python3-venv" __pyvenv /home/darko/testenv --pyvenv "pyvenv-3.4" --owner darko --group darko --mode 740 --state present
|
||
require="__pyvenv/home/darko/testenv" __package_pip docopt --pip /home/darko/testenv/bin/pip --runas darko --state present
|
||
;;
|
||
esac</pre></div><div class="section" title="3. REQUIRED PARAMETERS"><div class="titlepage"><div><div><h2 class="title" style="clear: both"><a id="_required_parameters"></a>3. REQUIRED PARAMETERS</h2></div></div></div><p>None</p></div><div class="section" title="4. OPTIONAL PARAMETERS"><div class="titlepage"><div><div><h2 class="title" style="clear: both"><a id="_optional_parameters"></a>4. OPTIONAL PARAMETERS</h2></div></div></div><div class="variablelist"><dl><dt><span class="term">
|
||
state
|
||
</span></dt><dd>
|
||
Either "present" or "absent", defaults to "present"
|
||
</dd><dt><span class="term">
|
||
group
|
||
</span></dt><dd>
|
||
Group to chgrp to
|
||
</dd><dt><span class="term">
|
||
mode
|
||
</span></dt><dd>
|
||
Unix permissions, suitable for chmod
|
||
</dd><dt><span class="term">
|
||
owner
|
||
</span></dt><dd>
|
||
User to chown to
|
||
</dd><dt><span class="term">
|
||
pyvenv
|
||
</span></dt><dd>
|
||
Use this specific pyvenv
|
||
</dd><dt><span class="term">
|
||
venvparams
|
||
</span></dt><dd>
|
||
Specific parameters to pass to pyvenv invocation
|
||
</dd></dl></div></div><div class="section" title="5. EXAMPLES"><div class="titlepage"><div><div><h2 class="title" style="clear: both"><a id="_examples"></a>5. EXAMPLES</h2></div></div></div><pre class="screen">__pyvenv /home/services/djangoenv
|
||
|
||
# Use specific pyvenv
|
||
__pyvenv /home/foo/fooenv --pyvenv /usr/local/bin/pyvenv-3.4
|
||
|
||
# Create python virtualenv for user foo.
|
||
__pyvenv /home/foo/fooenv --group foo --user foo
|
||
|
||
# Create python virtualenv with specific parameters.
|
||
__pyvenv /home/services/djangoenv --venvparams "--copies --system-site-packages"</pre></div><div class="section" title="6. SEE ALSO"><div class="titlepage"><div><div><h2 class="title" style="clear: both"><a id="_see_also"></a>6. SEE ALSO</h2></div></div></div><div class="itemizedlist"><ul class="itemizedlist" type="disc"><li class="listitem">
|
||
<a href="../man7/cdist-type.html">cdist-type(7)</a>
|
||
</li></ul></div></div><div class="section" title="7. COPYING"><div class="titlepage"><div><div><h2 class="title" style="clear: both"><a id="_copying"></a>7. COPYING</h2></div></div></div><p>Copyright (C) 2016 Darko Poljak. Free use of this software is
|
||
granted under the terms of the GNU General Public License version 3 (GPLv3).</p></div></div></body></html>
|