lorax/composer.html

504 lines
29 KiB
HTML
Raw Permalink Normal View History

<!DOCTYPE html>
<!--[if IE 8]><html class="no-js lt-ie9" lang="en" > <![endif]-->
<!--[if gt IE 8]><!--> <html class="no-js" lang="en" > <!--<![endif]-->
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
2020-10-07 17:56:09 +00:00
<title>composer package &mdash; Lorax 34.3 documentation</title>
2019-03-27 23:44:17 +00:00
<script type="text/javascript" src="_static/js/modernizr.min.js"></script>
2019-03-27 23:44:17 +00:00
<script type="text/javascript" id="documentation_options" data-url_root="./" src="_static/documentation_options.js"></script>
2020-10-07 17:56:09 +00:00
<script src="_static/jquery.js"></script>
<script src="_static/underscore.js"></script>
<script src="_static/doctools.js"></script>
<script src="_static/language_data.js"></script>
2019-03-27 23:44:17 +00:00
<script type="text/javascript" src="_static/js/theme.js"></script>
2019-03-27 23:44:17 +00:00
2019-03-27 23:44:17 +00:00
<link rel="stylesheet" href="_static/css/theme.css" type="text/css" />
<link rel="stylesheet" href="_static/pygments.css" type="text/css" />
<link rel="index" title="Index" href="genindex.html" />
<link rel="search" title="Search" href="search.html" />
<link rel="next" title="composer.cli package" href="composer.cli.html" />
<link rel="prev" title="src" href="modules.html" />
</head>
<body class="wy-body-for-nav">
<div class="wy-grid-for-nav">
<nav data-toggle="wy-nav-shift" class="wy-nav-side">
<div class="wy-side-scroll">
2019-03-27 23:44:17 +00:00
<div class="wy-side-nav-search" >
<a href="index.html" class="icon icon-home"> Lorax
</a>
<div class="version">
2020-10-07 17:56:09 +00:00
34.3
</div>
<div role="search">
<form id="rtd-search-form" class="wy-form" action="search.html" method="get">
<input type="text" name="q" placeholder="Search docs" />
<input type="hidden" name="check_keywords" value="yes" />
<input type="hidden" name="area" value="default" />
</form>
</div>
</div>
<div class="wy-menu wy-menu-vertical" data-spy="affix" role="navigation" aria-label="main navigation">
<ul class="current">
<li class="toctree-l1"><a class="reference internal" href="intro.html">Introduction to Lorax</a></li>
<li class="toctree-l1"><a class="reference internal" href="intro.html#before-lorax">Before Lorax</a></li>
<li class="toctree-l1"><a class="reference internal" href="lorax.html">Lorax</a></li>
<li class="toctree-l1"><a class="reference internal" href="livemedia-creator.html">livemedia-creator</a></li>
2018-10-29 20:42:44 +00:00
<li class="toctree-l1"><a class="reference internal" href="composer-cli.html">composer-cli</a></li>
2019-11-05 22:45:24 +00:00
<li class="toctree-l1"><a class="reference internal" href="mkksiso.html">mkksiso</a></li>
<li class="toctree-l1"><a class="reference internal" href="product-images.html">Product and Updates Images</a></li>
<li class="toctree-l1 current"><a class="reference internal" href="modules.html">src</a><ul class="current">
<li class="toctree-l2 current"><a class="current reference internal" href="#">composer package</a><ul>
<li class="toctree-l3"><a class="reference internal" href="#subpackages">Subpackages</a><ul>
<li class="toctree-l4"><a class="reference internal" href="composer.cli.html">composer.cli package</a></li>
</ul>
</li>
<li class="toctree-l3"><a class="reference internal" href="#submodules">Submodules</a></li>
<li class="toctree-l3"><a class="reference internal" href="#module-composer.http_client">composer.http_client module</a></li>
<li class="toctree-l3"><a class="reference internal" href="#module-composer.unix_socket">composer.unix_socket module</a></li>
<li class="toctree-l3"><a class="reference internal" href="#module-composer">Module contents</a></li>
</ul>
</li>
<li class="toctree-l2"><a class="reference internal" href="pylorax.html">pylorax package</a></li>
</ul>
</li>
</ul>
</div>
</div>
</nav>
<section data-toggle="wy-nav-shift" class="wy-nav-content-wrap">
<nav class="wy-nav-top" aria-label="top navigation">
<i data-toggle="wy-nav-top" class="fa fa-bars"></i>
<a href="index.html">Lorax</a>
</nav>
<div class="wy-nav-content">
<div class="rst-content">
<div role="navigation" aria-label="breadcrumbs navigation">
<ul class="wy-breadcrumbs">
<li><a href="index.html">Docs</a> &raquo;</li>
<li><a href="modules.html">src</a> &raquo;</li>
<li>composer package</li>
<li class="wy-breadcrumbs-aside">
<a href="_sources/composer.rst.txt" rel="nofollow"> View page source</a>
</li>
</ul>
<hr/>
</div>
<div role="main" class="document" itemscope="itemscope" itemtype="http://schema.org/Article">
<div itemprop="articleBody">
<div class="section" id="composer-package">
<h1>composer package<a class="headerlink" href="#composer-package" title="Permalink to this headline"></a></h1>
<div class="section" id="subpackages">
<h2>Subpackages<a class="headerlink" href="#subpackages" title="Permalink to this headline"></a></h2>
<div class="toctree-wrapper compound">
<ul>
<li class="toctree-l1"><a class="reference internal" href="composer.cli.html">composer.cli package</a><ul>
<li class="toctree-l2"><a class="reference internal" href="composer.cli.html#submodules">Submodules</a></li>
<li class="toctree-l2"><a class="reference internal" href="composer.cli.html#module-composer.cli.blueprints">composer.cli.blueprints module</a></li>
<li class="toctree-l2"><a class="reference internal" href="composer.cli.html#module-composer.cli.cmdline">composer.cli.cmdline module</a></li>
<li class="toctree-l2"><a class="reference internal" href="composer.cli.html#module-composer.cli.compose">composer.cli.compose module</a></li>
2018-08-13 23:44:47 +00:00
<li class="toctree-l2"><a class="reference internal" href="composer.cli.html#module-composer.cli.help">composer.cli.help module</a></li>
<li class="toctree-l2"><a class="reference internal" href="composer.cli.html#module-composer.cli.modules">composer.cli.modules module</a></li>
<li class="toctree-l2"><a class="reference internal" href="composer.cli.html#module-composer.cli.projects">composer.cli.projects module</a></li>
2019-10-16 23:14:02 +00:00
<li class="toctree-l2"><a class="reference internal" href="composer.cli.html#module-composer.cli.providers">composer.cli.providers module</a></li>
2018-06-04 23:34:57 +00:00
<li class="toctree-l2"><a class="reference internal" href="composer.cli.html#module-composer.cli.sources">composer.cli.sources module</a></li>
2018-08-13 23:44:47 +00:00
<li class="toctree-l2"><a class="reference internal" href="composer.cli.html#module-composer.cli.status">composer.cli.status module</a></li>
2019-10-16 23:14:02 +00:00
<li class="toctree-l2"><a class="reference internal" href="composer.cli.html#module-composer.cli.upload">composer.cli.upload module</a></li>
<li class="toctree-l2"><a class="reference internal" href="composer.cli.html#module-composer.cli.utilities">composer.cli.utilities module</a></li>
<li class="toctree-l2"><a class="reference internal" href="composer.cli.html#module-composer.cli">Module contents</a></li>
</ul>
</li>
</ul>
</div>
</div>
<div class="section" id="submodules">
<h2>Submodules<a class="headerlink" href="#submodules" title="Permalink to this headline"></a></h2>
</div>
<div class="section" id="module-composer.http_client">
<span id="composer-http-client-module"></span><h2>composer.http_client module<a class="headerlink" href="#module-composer.http_client" title="Permalink to this headline"></a></h2>
2020-10-07 17:56:09 +00:00
<dl class="py function">
<dt id="composer.http_client.api_url">
2020-10-07 17:56:09 +00:00
<code class="sig-prename descclassname">composer.http_client.</code><code class="sig-name descname">api_url</code><span class="sig-paren">(</span><em class="sig-param"><span class="n">api_version</span></em>, <em class="sig-param"><span class="n">url</span></em><span class="sig-paren">)</span><a class="reference internal" href="_modules/composer/http_client.html#api_url"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#composer.http_client.api_url" title="Permalink to this definition"></a></dt>
<dd><p>Return the versioned path to the API route</p>
2019-03-27 23:44:17 +00:00
<dl class="field-list simple">
<dt class="field-odd">Parameters</dt>
<dd class="field-odd"><ul class="simple">
2019-10-16 23:14:02 +00:00
<li><p><strong>api_version</strong> (<a class="reference external" href="https://docs.python.org/3/library/stdtypes.html#str" title="(in Python v3.8)"><em>str</em></a>) -- The version of the API to talk to. eg. &quot;0&quot;</p></li>
<li><p><strong>url</strong> (<a class="reference external" href="https://docs.python.org/3/library/stdtypes.html#str" title="(in Python v3.8)"><em>str</em></a>) -- The API route to talk to</p></li>
</ul>
2019-03-27 23:44:17 +00:00
</dd>
<dt class="field-even">Returns</dt>
<dd class="field-even"><p>The full url to use for the route and API version</p>
</dd>
<dt class="field-odd">Return type</dt>
2019-10-16 23:14:02 +00:00
<dd class="field-odd"><p><a class="reference external" href="https://docs.python.org/3/library/stdtypes.html#str" title="(in Python v3.8)">str</a></p>
2019-03-27 23:44:17 +00:00
</dd>
</dl>
</dd></dl>
2020-10-07 17:56:09 +00:00
<dl class="py function">
2018-09-06 17:40:16 +00:00
<dt id="composer.http_client.append_query">
2020-10-07 17:56:09 +00:00
<code class="sig-prename descclassname">composer.http_client.</code><code class="sig-name descname">append_query</code><span class="sig-paren">(</span><em class="sig-param"><span class="n">url</span></em>, <em class="sig-param"><span class="n">query</span></em><span class="sig-paren">)</span><a class="reference internal" href="_modules/composer/http_client.html#append_query"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#composer.http_client.append_query" title="Permalink to this definition"></a></dt>
2018-09-06 17:40:16 +00:00
<dd><p>Add a query argument to a URL</p>
2019-03-27 23:44:17 +00:00
<p>The query should be of the form &quot;param1=what&amp;param2=ever&quot;, i.e., no
leading '?'. The new query data will be appended to any existing
2018-09-06 17:40:16 +00:00
query string.</p>
2019-03-27 23:44:17 +00:00
<dl class="field-list simple">
<dt class="field-odd">Parameters</dt>
<dd class="field-odd"><ul class="simple">
2019-10-16 23:14:02 +00:00
<li><p><strong>url</strong> (<a class="reference external" href="https://docs.python.org/3/library/stdtypes.html#str" title="(in Python v3.8)"><em>str</em></a>) -- The original URL</p></li>
<li><p><strong>query</strong> (<a class="reference external" href="https://docs.python.org/3/library/stdtypes.html#str" title="(in Python v3.8)"><em>str</em></a>) -- The query to append</p></li>
2018-09-06 17:40:16 +00:00
</ul>
2019-03-27 23:44:17 +00:00
</dd>
<dt class="field-even">Returns</dt>
<dd class="field-even"><p>The new URL with the query argument included</p>
</dd>
<dt class="field-odd">Return type</dt>
2019-10-16 23:14:02 +00:00
<dd class="field-odd"><p><a class="reference external" href="https://docs.python.org/3/library/stdtypes.html#str" title="(in Python v3.8)">str</a></p>
2019-03-27 23:44:17 +00:00
</dd>
</dl>
2018-09-06 17:40:16 +00:00
</dd></dl>
2020-10-07 17:56:09 +00:00
<dl class="py function">
<dt id="composer.http_client.delete_url_json">
2020-10-07 17:56:09 +00:00
<code class="sig-prename descclassname">composer.http_client.</code><code class="sig-name descname">delete_url_json</code><span class="sig-paren">(</span><em class="sig-param"><span class="n">socket_path</span></em>, <em class="sig-param"><span class="n">url</span></em><span class="sig-paren">)</span><a class="reference internal" href="_modules/composer/http_client.html#delete_url_json"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#composer.http_client.delete_url_json" title="Permalink to this definition"></a></dt>
<dd><p>Send a DELETE request to the url and return JSON response</p>
2019-03-27 23:44:17 +00:00
<dl class="field-list simple">
<dt class="field-odd">Parameters</dt>
<dd class="field-odd"><ul class="simple">
2019-10-16 23:14:02 +00:00
<li><p><strong>socket_path</strong> (<a class="reference external" href="https://docs.python.org/3/library/stdtypes.html#str" title="(in Python v3.8)"><em>str</em></a>) -- Path to the Unix socket to use for API communication</p></li>
<li><p><strong>url</strong> (<a class="reference external" href="https://docs.python.org/3/library/stdtypes.html#str" title="(in Python v3.8)"><em>str</em></a>) -- URL to send DELETE to</p></li>
</ul>
2019-03-27 23:44:17 +00:00
</dd>
<dt class="field-even">Returns</dt>
<dd class="field-even"><p>The json response from the server</p>
</dd>
<dt class="field-odd">Return type</dt>
2019-10-16 23:14:02 +00:00
<dd class="field-odd"><p><a class="reference external" href="https://docs.python.org/3/library/stdtypes.html#dict" title="(in Python v3.8)">dict</a></p>
2019-03-27 23:44:17 +00:00
</dd>
</dl>
</dd></dl>
2020-10-07 17:56:09 +00:00
<dl class="py function">
<dt id="composer.http_client.download_file">
2020-10-07 17:56:09 +00:00
<code class="sig-prename descclassname">composer.http_client.</code><code class="sig-name descname">download_file</code><span class="sig-paren">(</span><em class="sig-param"><span class="n">socket_path</span></em>, <em class="sig-param"><span class="n">url</span></em>, <em class="sig-param"><span class="n">progress</span><span class="o">=</span><span class="default_value">True</span></em><span class="sig-paren">)</span><a class="reference internal" href="_modules/composer/http_client.html#download_file"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#composer.http_client.download_file" title="Permalink to this definition"></a></dt>
<dd><p>Download a file, saving it to the CWD with the included filename</p>
2019-03-27 23:44:17 +00:00
<dl class="field-list simple">
<dt class="field-odd">Parameters</dt>
<dd class="field-odd"><ul class="simple">
2019-10-16 23:14:02 +00:00
<li><p><strong>socket_path</strong> (<a class="reference external" href="https://docs.python.org/3/library/stdtypes.html#str" title="(in Python v3.8)"><em>str</em></a>) -- Path to the Unix socket to use for API communication</p></li>
<li><p><strong>url</strong> (<a class="reference external" href="https://docs.python.org/3/library/stdtypes.html#str" title="(in Python v3.8)"><em>str</em></a>) -- URL to send POST to</p></li>
</ul>
2019-03-27 23:44:17 +00:00
</dd>
</dl>
</dd></dl>
2020-10-07 17:56:09 +00:00
<dl class="py function">
<dt id="composer.http_client.get_filename">
2020-10-07 17:56:09 +00:00
<code class="sig-prename descclassname">composer.http_client.</code><code class="sig-name descname">get_filename</code><span class="sig-paren">(</span><em class="sig-param"><span class="n">headers</span></em><span class="sig-paren">)</span><a class="reference internal" href="_modules/composer/http_client.html#get_filename"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#composer.http_client.get_filename" title="Permalink to this definition"></a></dt>
<dd><p>Get the filename from the response header</p>
2019-03-27 23:44:17 +00:00
<dl class="field-list simple">
<dt class="field-odd">Parameters</dt>
<dd class="field-odd"><p><strong>response</strong> (<em>Response</em>) -- The urllib3 response object</p>
</dd>
<dt class="field-even">Raises</dt>
<dd class="field-even"><p>RuntimeError if it cannot find a filename in the header</p>
</dd>
<dt class="field-odd">Returns</dt>
<dd class="field-odd"><p>Filename from content-disposition header</p>
</dd>
<dt class="field-even">Return type</dt>
2019-10-16 23:14:02 +00:00
<dd class="field-even"><p><a class="reference external" href="https://docs.python.org/3/library/stdtypes.html#str" title="(in Python v3.8)">str</a></p>
2019-03-27 23:44:17 +00:00
</dd>
</dl>
</dd></dl>
2020-10-07 17:56:09 +00:00
<dl class="py function">
<dt id="composer.http_client.get_url_json">
2020-10-07 17:56:09 +00:00
<code class="sig-prename descclassname">composer.http_client.</code><code class="sig-name descname">get_url_json</code><span class="sig-paren">(</span><em class="sig-param"><span class="n">socket_path</span></em>, <em class="sig-param"><span class="n">url</span></em><span class="sig-paren">)</span><a class="reference internal" href="_modules/composer/http_client.html#get_url_json"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#composer.http_client.get_url_json" title="Permalink to this definition"></a></dt>
<dd><p>Return the JSON results of a GET request</p>
2019-03-27 23:44:17 +00:00
<dl class="field-list simple">
<dt class="field-odd">Parameters</dt>
<dd class="field-odd"><ul class="simple">
2019-10-16 23:14:02 +00:00
<li><p><strong>socket_path</strong> (<a class="reference external" href="https://docs.python.org/3/library/stdtypes.html#str" title="(in Python v3.8)"><em>str</em></a>) -- Path to the Unix socket to use for API communication</p></li>
<li><p><strong>url</strong> (<a class="reference external" href="https://docs.python.org/3/library/stdtypes.html#str" title="(in Python v3.8)"><em>str</em></a>) -- URL to request</p></li>
</ul>
2019-03-27 23:44:17 +00:00
</dd>
<dt class="field-even">Returns</dt>
<dd class="field-even"><p>The json response from the server</p>
</dd>
<dt class="field-odd">Return type</dt>
2019-10-16 23:14:02 +00:00
<dd class="field-odd"><p><a class="reference external" href="https://docs.python.org/3/library/stdtypes.html#dict" title="(in Python v3.8)">dict</a></p>
2019-03-27 23:44:17 +00:00
</dd>
</dl>
</dd></dl>
2020-10-07 17:56:09 +00:00
<dl class="py function">
2018-09-06 17:40:16 +00:00
<dt id="composer.http_client.get_url_json_unlimited">
2020-10-07 17:56:09 +00:00
<code class="sig-prename descclassname">composer.http_client.</code><code class="sig-name descname">get_url_json_unlimited</code><span class="sig-paren">(</span><em class="sig-param"><span class="n">socket_path</span></em>, <em class="sig-param"><span class="n">url</span></em>, <em class="sig-param"><span class="n">total_fn</span><span class="o">=</span><span class="default_value">None</span></em><span class="sig-paren">)</span><a class="reference internal" href="_modules/composer/http_client.html#get_url_json_unlimited"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#composer.http_client.get_url_json_unlimited" title="Permalink to this definition"></a></dt>
2018-09-06 17:40:16 +00:00
<dd><p>Return the JSON results of a GET request</p>
<p>For URLs that use offset/limit arguments, this command will
fetch all results for the given request.</p>
2019-03-27 23:44:17 +00:00
<dl class="field-list simple">
<dt class="field-odd">Parameters</dt>
<dd class="field-odd"><ul class="simple">
2019-10-16 23:14:02 +00:00
<li><p><strong>socket_path</strong> (<a class="reference external" href="https://docs.python.org/3/library/stdtypes.html#str" title="(in Python v3.8)"><em>str</em></a>) -- Path to the Unix socket to use for API communication</p></li>
<li><p><strong>url</strong> (<a class="reference external" href="https://docs.python.org/3/library/stdtypes.html#str" title="(in Python v3.8)"><em>str</em></a>) -- URL to request</p></li>
2018-09-06 17:40:16 +00:00
</ul>
2019-03-27 23:44:17 +00:00
</dd>
<dt class="field-even">Returns</dt>
<dd class="field-even"><p>The json response from the server</p>
</dd>
<dt class="field-odd">Return type</dt>
2019-10-16 23:14:02 +00:00
<dd class="field-odd"><p><a class="reference external" href="https://docs.python.org/3/library/stdtypes.html#dict" title="(in Python v3.8)">dict</a></p>
2019-03-27 23:44:17 +00:00
</dd>
</dl>
2018-09-06 17:40:16 +00:00
</dd></dl>
2020-10-07 17:56:09 +00:00
<dl class="py function">
<dt id="composer.http_client.get_url_raw">
2020-10-07 17:56:09 +00:00
<code class="sig-prename descclassname">composer.http_client.</code><code class="sig-name descname">get_url_raw</code><span class="sig-paren">(</span><em class="sig-param"><span class="n">socket_path</span></em>, <em class="sig-param"><span class="n">url</span></em><span class="sig-paren">)</span><a class="reference internal" href="_modules/composer/http_client.html#get_url_raw"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#composer.http_client.get_url_raw" title="Permalink to this definition"></a></dt>
<dd><p>Return the raw results of a GET request</p>
2019-03-27 23:44:17 +00:00
<dl class="field-list simple">
<dt class="field-odd">Parameters</dt>
<dd class="field-odd"><ul class="simple">
2019-10-16 23:14:02 +00:00
<li><p><strong>socket_path</strong> (<a class="reference external" href="https://docs.python.org/3/library/stdtypes.html#str" title="(in Python v3.8)"><em>str</em></a>) -- Path to the Unix socket to use for API communication</p></li>
<li><p><strong>url</strong> (<a class="reference external" href="https://docs.python.org/3/library/stdtypes.html#str" title="(in Python v3.8)"><em>str</em></a>) -- URL to request</p></li>
</ul>
2019-03-27 23:44:17 +00:00
</dd>
<dt class="field-even">Returns</dt>
<dd class="field-even"><p>The raw response from the server</p>
</dd>
<dt class="field-odd">Return type</dt>
2019-10-16 23:14:02 +00:00
<dd class="field-odd"><p><a class="reference external" href="https://docs.python.org/3/library/stdtypes.html#str" title="(in Python v3.8)">str</a></p>
2019-03-27 23:44:17 +00:00
</dd>
</dl>
</dd></dl>
2020-10-07 17:56:09 +00:00
<dl class="py function">
<dt id="composer.http_client.post_url">
2020-10-07 17:56:09 +00:00
<code class="sig-prename descclassname">composer.http_client.</code><code class="sig-name descname">post_url</code><span class="sig-paren">(</span><em class="sig-param"><span class="n">socket_path</span></em>, <em class="sig-param"><span class="n">url</span></em>, <em class="sig-param"><span class="n">body</span></em><span class="sig-paren">)</span><a class="reference internal" href="_modules/composer/http_client.html#post_url"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#composer.http_client.post_url" title="Permalink to this definition"></a></dt>
<dd><p>POST raw data to the URL</p>
2019-03-27 23:44:17 +00:00
<dl class="field-list simple">
<dt class="field-odd">Parameters</dt>
<dd class="field-odd"><ul class="simple">
2019-10-16 23:14:02 +00:00
<li><p><strong>socket_path</strong> (<a class="reference external" href="https://docs.python.org/3/library/stdtypes.html#str" title="(in Python v3.8)"><em>str</em></a>) -- Path to the Unix socket to use for API communication</p></li>
<li><p><strong>url</strong> (<a class="reference external" href="https://docs.python.org/3/library/stdtypes.html#str" title="(in Python v3.8)"><em>str</em></a>) -- URL to send POST to</p></li>
<li><p><strong>body</strong> (<a class="reference external" href="https://docs.python.org/3/library/stdtypes.html#str" title="(in Python v3.8)"><em>str</em></a>) -- The data for the body of the POST</p></li>
</ul>
2019-03-27 23:44:17 +00:00
</dd>
<dt class="field-even">Returns</dt>
<dd class="field-even"><p>The json response from the server</p>
</dd>
<dt class="field-odd">Return type</dt>
2019-10-16 23:14:02 +00:00
<dd class="field-odd"><p><a class="reference external" href="https://docs.python.org/3/library/stdtypes.html#dict" title="(in Python v3.8)">dict</a></p>
2019-03-27 23:44:17 +00:00
</dd>
</dl>
</dd></dl>
2020-10-07 17:56:09 +00:00
<dl class="py function">
<dt id="composer.http_client.post_url_json">
2020-10-07 17:56:09 +00:00
<code class="sig-prename descclassname">composer.http_client.</code><code class="sig-name descname">post_url_json</code><span class="sig-paren">(</span><em class="sig-param"><span class="n">socket_path</span></em>, <em class="sig-param"><span class="n">url</span></em>, <em class="sig-param"><span class="n">body</span></em><span class="sig-paren">)</span><a class="reference internal" href="_modules/composer/http_client.html#post_url_json"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#composer.http_client.post_url_json" title="Permalink to this definition"></a></dt>
<dd><p>POST some JSON data to the URL</p>
2019-03-27 23:44:17 +00:00
<dl class="field-list simple">
<dt class="field-odd">Parameters</dt>
<dd class="field-odd"><ul class="simple">
2019-10-16 23:14:02 +00:00
<li><p><strong>socket_path</strong> (<a class="reference external" href="https://docs.python.org/3/library/stdtypes.html#str" title="(in Python v3.8)"><em>str</em></a>) -- Path to the Unix socket to use for API communication</p></li>
<li><p><strong>url</strong> (<a class="reference external" href="https://docs.python.org/3/library/stdtypes.html#str" title="(in Python v3.8)"><em>str</em></a>) -- URL to send POST to</p></li>
<li><p><strong>body</strong> (<a class="reference external" href="https://docs.python.org/3/library/stdtypes.html#str" title="(in Python v3.8)"><em>str</em></a>) -- The data for the body of the POST</p></li>
</ul>
2019-03-27 23:44:17 +00:00
</dd>
<dt class="field-even">Returns</dt>
<dd class="field-even"><p>The json response from the server</p>
</dd>
<dt class="field-odd">Return type</dt>
2019-10-16 23:14:02 +00:00
<dd class="field-odd"><p><a class="reference external" href="https://docs.python.org/3/library/stdtypes.html#dict" title="(in Python v3.8)">dict</a></p>
2019-03-27 23:44:17 +00:00
</dd>
</dl>
</dd></dl>
2020-10-07 17:56:09 +00:00
<dl class="py function">
<dt id="composer.http_client.post_url_toml">
2020-10-07 17:56:09 +00:00
<code class="sig-prename descclassname">composer.http_client.</code><code class="sig-name descname">post_url_toml</code><span class="sig-paren">(</span><em class="sig-param"><span class="n">socket_path</span></em>, <em class="sig-param"><span class="n">url</span></em>, <em class="sig-param"><span class="n">body</span></em><span class="sig-paren">)</span><a class="reference internal" href="_modules/composer/http_client.html#post_url_toml"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#composer.http_client.post_url_toml" title="Permalink to this definition"></a></dt>
<dd><p>POST a TOML string to the URL</p>
2019-03-27 23:44:17 +00:00
<dl class="field-list simple">
<dt class="field-odd">Parameters</dt>
<dd class="field-odd"><ul class="simple">
2019-10-16 23:14:02 +00:00
<li><p><strong>socket_path</strong> (<a class="reference external" href="https://docs.python.org/3/library/stdtypes.html#str" title="(in Python v3.8)"><em>str</em></a>) -- Path to the Unix socket to use for API communication</p></li>
<li><p><strong>url</strong> (<a class="reference external" href="https://docs.python.org/3/library/stdtypes.html#str" title="(in Python v3.8)"><em>str</em></a>) -- URL to send POST to</p></li>
<li><p><strong>body</strong> (<a class="reference external" href="https://docs.python.org/3/library/stdtypes.html#str" title="(in Python v3.8)"><em>str</em></a>) -- The data for the body of the POST</p></li>
</ul>
2019-03-27 23:44:17 +00:00
</dd>
<dt class="field-even">Returns</dt>
<dd class="field-even"><p>The json response from the server</p>
</dd>
<dt class="field-odd">Return type</dt>
2019-10-16 23:14:02 +00:00
<dd class="field-odd"><p><a class="reference external" href="https://docs.python.org/3/library/stdtypes.html#dict" title="(in Python v3.8)">dict</a></p>
2019-03-27 23:44:17 +00:00
</dd>
</dl>
</dd></dl>
</div>
<div class="section" id="module-composer.unix_socket">
<span id="composer-unix-socket-module"></span><h2>composer.unix_socket module<a class="headerlink" href="#module-composer.unix_socket" title="Permalink to this headline"></a></h2>
2020-10-07 17:56:09 +00:00
<dl class="py class">
<dt id="composer.unix_socket.UnixHTTPConnection">
2020-10-07 17:56:09 +00:00
<em class="property">class </em><code class="sig-prename descclassname">composer.unix_socket.</code><code class="sig-name descname">UnixHTTPConnection</code><span class="sig-paren">(</span><em class="sig-param"><span class="n">socket_path</span></em>, <em class="sig-param"><span class="n">timeout</span><span class="o">=</span><span class="default_value">300</span></em><span class="sig-paren">)</span><a class="reference internal" href="_modules/composer/unix_socket.html#UnixHTTPConnection"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#composer.unix_socket.UnixHTTPConnection" title="Permalink to this definition"></a></dt>
2019-10-16 23:14:02 +00:00
<dd><p>Bases: <a class="reference external" href="https://docs.python.org/3/library/http.client.html#http.client.HTTPConnection" title="(in Python v3.8)"><code class="xref py py-class docutils literal notranslate"><span class="pre">http.client.HTTPConnection</span></code></a>, <a class="reference external" href="https://docs.python.org/3/library/functions.html#object" title="(in Python v3.8)"><code class="xref py py-class docutils literal notranslate"><span class="pre">object</span></code></a></p>
2020-10-07 17:56:09 +00:00
<dl class="py method">
<dt id="composer.unix_socket.UnixHTTPConnection.connect">
2019-07-30 22:48:40 +00:00
<code class="sig-name descname">connect</code><span class="sig-paren">(</span><span class="sig-paren">)</span><a class="reference internal" href="_modules/composer/unix_socket.html#UnixHTTPConnection.connect"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#composer.unix_socket.UnixHTTPConnection.connect" title="Permalink to this definition"></a></dt>
<dd><p>Connect to the host and port specified in __init__.</p>
</dd></dl>
</dd></dl>
2020-10-07 17:56:09 +00:00
<dl class="py class">
<dt id="composer.unix_socket.UnixHTTPConnectionPool">
2020-10-07 17:56:09 +00:00
<em class="property">class </em><code class="sig-prename descclassname">composer.unix_socket.</code><code class="sig-name descname">UnixHTTPConnectionPool</code><span class="sig-paren">(</span><em class="sig-param"><span class="n">socket_path</span></em>, <em class="sig-param"><span class="n">timeout</span><span class="o">=</span><span class="default_value">300</span></em><span class="sig-paren">)</span><a class="reference internal" href="_modules/composer/unix_socket.html#UnixHTTPConnectionPool"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#composer.unix_socket.UnixHTTPConnectionPool" title="Permalink to this definition"></a></dt>
<dd><p>Bases: <code class="xref py py-class docutils literal notranslate"><span class="pre">urllib3.connectionpool.HTTPConnectionPool</span></code></p>
</dd></dl>
</div>
<div class="section" id="module-composer">
<span id="module-contents"></span><h2>Module contents<a class="headerlink" href="#module-composer" title="Permalink to this headline"></a></h2>
</div>
</div>
</div>
</div>
<footer>
<div class="rst-footer-buttons" role="navigation" aria-label="footer navigation">
<a href="composer.cli.html" class="btn btn-neutral float-right" title="composer.cli package" accesskey="n" rel="next">Next <span class="fa fa-arrow-circle-right"></span></a>
2019-03-27 23:44:17 +00:00
<a href="modules.html" class="btn btn-neutral float-left" title="src" accesskey="p" rel="prev"><span class="fa fa-arrow-circle-left"></span> Previous</a>
</div>
<hr/>
<div role="contentinfo">
<p>
2019-03-27 23:44:17 +00:00
&copy; Copyright 2018, Red Hat, Inc.
</p>
</div>
Built with <a href="http://sphinx-doc.org/">Sphinx</a> using a <a href="https://github.com/rtfd/sphinx_rtd_theme">theme</a> provided by <a href="https://readthedocs.org">Read the Docs</a>.
</footer>
</div>
</div>
</section>
</div>
<script type="text/javascript">
jQuery(function () {
2018-06-04 23:34:57 +00:00
SphinxRtdTheme.Navigation.enable(true);
});
2019-03-27 23:44:17 +00:00
</script>
</body>
</html>