Update lorax 19.7.11 (lorax-composer) Documentation
This commit is contained in:
parent
dda4242918
commit
807ee72228
@ -1,4 +1,4 @@
|
||||
# Sphinx build info version 1
|
||||
# This file hashes the configuration used when building these files. When it is not found, a full rebuild will be done.
|
||||
config: 972a8f4b79671d03d004b6b084c1be20
|
||||
config: d0036b060ae50548427b7f3aa21363e9
|
||||
tags: fbb0d17656682115ca4d033fb2f83ba1
|
||||
|
BIN
lorax-composer/.doctrees/composer.cli.doctree
Normal file
BIN
lorax-composer/.doctrees/composer.cli.doctree
Normal file
Binary file not shown.
BIN
lorax-composer/.doctrees/composer.doctree
Normal file
BIN
lorax-composer/.doctrees/composer.doctree
Normal file
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
BIN
lorax-composer/.doctrees/livemedia-creator.doctree
Normal file
BIN
lorax-composer/.doctrees/livemedia-creator.doctree
Normal file
Binary file not shown.
Binary file not shown.
BIN
lorax-composer/.doctrees/lorax.doctree
Normal file
BIN
lorax-composer/.doctrees/lorax.doctree
Normal file
Binary file not shown.
Binary file not shown.
BIN
lorax-composer/.doctrees/product-images.doctree
Normal file
BIN
lorax-composer/.doctrees/product-images.doctree
Normal file
Binary file not shown.
Binary file not shown.
Binary file not shown.
150
lorax-composer/_modules/composer/cli.html
Normal file
150
lorax-composer/_modules/composer/cli.html
Normal file
@ -0,0 +1,150 @@
|
||||
|
||||
|
||||
<!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>composer.cli — Lorax 19.7.11 documentation</title>
|
||||
|
||||
<link rel="stylesheet" href="../../_static/default.css" type="text/css" />
|
||||
<link rel="stylesheet" href="../../_static/pygments.css" type="text/css" />
|
||||
|
||||
<script type="text/javascript">
|
||||
var DOCUMENTATION_OPTIONS = {
|
||||
URL_ROOT: '../../',
|
||||
VERSION: '19.7.11',
|
||||
COLLAPSE_INDEX: false,
|
||||
FILE_SUFFIX: '.html',
|
||||
HAS_SOURCE: true
|
||||
};
|
||||
</script>
|
||||
<script type="text/javascript" src="../../_static/jquery.js"></script>
|
||||
<script type="text/javascript" src="../../_static/underscore.js"></script>
|
||||
<script type="text/javascript" src="../../_static/doctools.js"></script>
|
||||
<link rel="top" title="Lorax 19.7.11 documentation" href="../../index.html" />
|
||||
<link rel="up" title="Module code" href="../index.html" />
|
||||
</head>
|
||||
<body>
|
||||
<div class="related">
|
||||
<h3>Navigation</h3>
|
||||
<ul>
|
||||
<li class="right" style="margin-right: 10px">
|
||||
<a href="../../genindex.html" title="General Index"
|
||||
accesskey="I">index</a></li>
|
||||
<li class="right" >
|
||||
<a href="../../py-modindex.html" title="Python Module Index"
|
||||
>modules</a> |</li>
|
||||
<li><a href="../../index.html">Lorax 19.7.11 documentation</a> »</li>
|
||||
<li><a href="../index.html" accesskey="U">Module code</a> »</li>
|
||||
</ul>
|
||||
</div>
|
||||
|
||||
<div class="document">
|
||||
<div class="documentwrapper">
|
||||
<div class="bodywrapper">
|
||||
<div class="body">
|
||||
|
||||
<h1>Source code for composer.cli</h1><div class="highlight"><pre>
|
||||
<span class="c">#!/usr/bin/python</span>
|
||||
<span class="c">#</span>
|
||||
<span class="c"># composer-cli</span>
|
||||
<span class="c">#</span>
|
||||
<span class="c"># Copyright (C) 2018 Red Hat, Inc.</span>
|
||||
<span class="c">#</span>
|
||||
<span class="c"># This program is free software; you can redistribute it and/or modify</span>
|
||||
<span class="c"># it under the terms of the GNU General Public License as published by</span>
|
||||
<span class="c"># the Free Software Foundation; either version 2 of the License, or</span>
|
||||
<span class="c"># (at your option) any later version.</span>
|
||||
<span class="c">#</span>
|
||||
<span class="c"># This program is distributed in the hope that it will be useful,</span>
|
||||
<span class="c"># but WITHOUT ANY WARRANTY; without even the implied warranty of</span>
|
||||
<span class="c"># MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the</span>
|
||||
<span class="c"># GNU General Public License for more details.</span>
|
||||
<span class="c">#</span>
|
||||
<span class="c"># You should have received a copy of the GNU General Public License</span>
|
||||
<span class="c"># along with this program. If not, see <http://www.gnu.org/licenses/>.</span>
|
||||
<span class="c">#</span>
|
||||
<span class="kn">import</span> <span class="nn">logging</span>
|
||||
<span class="n">log</span> <span class="o">=</span> <span class="n">logging</span><span class="o">.</span><span class="n">getLogger</span><span class="p">(</span><span class="s">"composer-cli"</span><span class="p">)</span>
|
||||
|
||||
<span class="kn">from</span> <span class="nn">composer.cli.recipes</span> <span class="kn">import</span> <span class="n">recipes_cmd</span>
|
||||
<span class="kn">from</span> <span class="nn">composer.cli.modules</span> <span class="kn">import</span> <span class="n">modules_cmd</span>
|
||||
<span class="kn">from</span> <span class="nn">composer.cli.projects</span> <span class="kn">import</span> <span class="n">projects_cmd</span>
|
||||
<span class="kn">from</span> <span class="nn">composer.cli.compose</span> <span class="kn">import</span> <span class="n">compose_cmd</span>
|
||||
|
||||
<span class="n">command_map</span> <span class="o">=</span> <span class="p">{</span>
|
||||
<span class="s">"recipes"</span><span class="p">:</span> <span class="n">recipes_cmd</span><span class="p">,</span>
|
||||
<span class="s">"modules"</span><span class="p">:</span> <span class="n">modules_cmd</span><span class="p">,</span>
|
||||
<span class="s">"projects"</span><span class="p">:</span> <span class="n">projects_cmd</span><span class="p">,</span>
|
||||
<span class="s">"compose"</span><span class="p">:</span> <span class="n">compose_cmd</span>
|
||||
<span class="p">}</span>
|
||||
|
||||
|
||||
<div class="viewcode-block" id="main"><a class="viewcode-back" href="../../composer.cli.html#composer.cli.main">[docs]</a><span class="k">def</span> <span class="nf">main</span><span class="p">(</span><span class="n">opts</span><span class="p">):</span>
|
||||
<span class="sd">""" Main program execution</span>
|
||||
|
||||
<span class="sd"> :param opts: Cmdline arguments</span>
|
||||
<span class="sd"> :type opts: argparse.Namespace</span>
|
||||
<span class="sd"> """</span>
|
||||
<span class="k">if</span> <span class="nb">len</span><span class="p">(</span><span class="n">opts</span><span class="o">.</span><span class="n">args</span><span class="p">)</span> <span class="o">==</span> <span class="mi">0</span><span class="p">:</span>
|
||||
<span class="n">log</span><span class="o">.</span><span class="n">error</span><span class="p">(</span><span class="s">"Missing command"</span><span class="p">)</span>
|
||||
<span class="k">return</span> <span class="mi">1</span>
|
||||
<span class="k">elif</span> <span class="n">opts</span><span class="o">.</span><span class="n">args</span><span class="p">[</span><span class="mi">0</span><span class="p">]</span> <span class="ow">not</span> <span class="ow">in</span> <span class="n">command_map</span><span class="p">:</span>
|
||||
<span class="n">log</span><span class="o">.</span><span class="n">error</span><span class="p">(</span><span class="s">"Unknown command </span><span class="si">%s</span><span class="s">"</span><span class="p">,</span> <span class="n">opts</span><span class="o">.</span><span class="n">args</span><span class="p">[</span><span class="mi">0</span><span class="p">])</span>
|
||||
<span class="k">return</span> <span class="mi">1</span>
|
||||
<span class="k">if</span> <span class="nb">len</span><span class="p">(</span><span class="n">opts</span><span class="o">.</span><span class="n">args</span><span class="p">)</span> <span class="o">==</span> <span class="mi">1</span><span class="p">:</span>
|
||||
<span class="n">log</span><span class="o">.</span><span class="n">error</span><span class="p">(</span><span class="s">"Missing </span><span class="si">%s</span><span class="s"> sub-command"</span><span class="p">,</span> <span class="n">opts</span><span class="o">.</span><span class="n">args</span><span class="p">[</span><span class="mi">0</span><span class="p">])</span>
|
||||
<span class="k">return</span> <span class="mi">1</span>
|
||||
<span class="k">else</span><span class="p">:</span>
|
||||
<span class="k">try</span><span class="p">:</span>
|
||||
<span class="k">return</span> <span class="n">command_map</span><span class="p">[</span><span class="n">opts</span><span class="o">.</span><span class="n">args</span><span class="p">[</span><span class="mi">0</span><span class="p">]](</span><span class="n">opts</span><span class="p">)</span>
|
||||
<span class="k">except</span> <span class="ne">Exception</span> <span class="k">as</span> <span class="n">e</span><span class="p">:</span>
|
||||
<span class="n">log</span><span class="o">.</span><span class="n">error</span><span class="p">(</span><span class="nb">str</span><span class="p">(</span><span class="n">e</span><span class="p">))</span>
|
||||
<span class="k">return</span> <span class="mi">1</span></div>
|
||||
</pre></div>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="sphinxsidebar">
|
||||
<div class="sphinxsidebarwrapper">
|
||||
<div id="searchbox" style="display: none">
|
||||
<h3>Quick search</h3>
|
||||
<form class="search" action="../../search.html" method="get">
|
||||
<input type="text" name="q" />
|
||||
<input type="submit" value="Go" />
|
||||
<input type="hidden" name="check_keywords" value="yes" />
|
||||
<input type="hidden" name="area" value="default" />
|
||||
</form>
|
||||
<p class="searchtip" style="font-size: 90%">
|
||||
Enter search terms or a module, class or function name.
|
||||
</p>
|
||||
</div>
|
||||
<script type="text/javascript">$('#searchbox').show(0);</script>
|
||||
</div>
|
||||
</div>
|
||||
<div class="clearer"></div>
|
||||
</div>
|
||||
<div class="related">
|
||||
<h3>Navigation</h3>
|
||||
<ul>
|
||||
<li class="right" style="margin-right: 10px">
|
||||
<a href="../../genindex.html" title="General Index"
|
||||
>index</a></li>
|
||||
<li class="right" >
|
||||
<a href="../../py-modindex.html" title="Python Module Index"
|
||||
>modules</a> |</li>
|
||||
<li><a href="../../index.html">Lorax 19.7.11 documentation</a> »</li>
|
||||
<li><a href="../index.html" >Module code</a> »</li>
|
||||
</ul>
|
||||
</div>
|
||||
<div class="footer">
|
||||
© Copyright 2018, Red Hat, Inc..
|
||||
Created using <a href="http://sphinx.pocoo.org/">Sphinx</a> 1.1.3.
|
||||
</div>
|
||||
</body>
|
||||
</html>
|
506
lorax-composer/_modules/composer/cli/compose.html
Normal file
506
lorax-composer/_modules/composer/cli/compose.html
Normal file
@ -0,0 +1,506 @@
|
||||
|
||||
|
||||
<!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>composer.cli.compose — Lorax 19.7.11 documentation</title>
|
||||
|
||||
<link rel="stylesheet" href="../../../_static/default.css" type="text/css" />
|
||||
<link rel="stylesheet" href="../../../_static/pygments.css" type="text/css" />
|
||||
|
||||
<script type="text/javascript">
|
||||
var DOCUMENTATION_OPTIONS = {
|
||||
URL_ROOT: '../../../',
|
||||
VERSION: '19.7.11',
|
||||
COLLAPSE_INDEX: false,
|
||||
FILE_SUFFIX: '.html',
|
||||
HAS_SOURCE: true
|
||||
};
|
||||
</script>
|
||||
<script type="text/javascript" src="../../../_static/jquery.js"></script>
|
||||
<script type="text/javascript" src="../../../_static/underscore.js"></script>
|
||||
<script type="text/javascript" src="../../../_static/doctools.js"></script>
|
||||
<link rel="top" title="Lorax 19.7.11 documentation" href="../../../index.html" />
|
||||
<link rel="up" title="composer.cli" href="../cli.html" />
|
||||
</head>
|
||||
<body>
|
||||
<div class="related">
|
||||
<h3>Navigation</h3>
|
||||
<ul>
|
||||
<li class="right" style="margin-right: 10px">
|
||||
<a href="../../../genindex.html" title="General Index"
|
||||
accesskey="I">index</a></li>
|
||||
<li class="right" >
|
||||
<a href="../../../py-modindex.html" title="Python Module Index"
|
||||
>modules</a> |</li>
|
||||
<li><a href="../../../index.html">Lorax 19.7.11 documentation</a> »</li>
|
||||
<li><a href="../../index.html" >Module code</a> »</li>
|
||||
<li><a href="../cli.html" accesskey="U">composer.cli</a> »</li>
|
||||
</ul>
|
||||
</div>
|
||||
|
||||
<div class="document">
|
||||
<div class="documentwrapper">
|
||||
<div class="bodywrapper">
|
||||
<div class="body">
|
||||
|
||||
<h1>Source code for composer.cli.compose</h1><div class="highlight"><pre>
|
||||
<span class="c">#</span>
|
||||
<span class="c"># Copyright (C) 2018 Red Hat, Inc.</span>
|
||||
<span class="c">#</span>
|
||||
<span class="c"># This program is free software; you can redistribute it and/or modify</span>
|
||||
<span class="c"># it under the terms of the GNU General Public License as published by</span>
|
||||
<span class="c"># the Free Software Foundation; either version 2 of the License, or</span>
|
||||
<span class="c"># (at your option) any later version.</span>
|
||||
<span class="c">#</span>
|
||||
<span class="c"># This program is distributed in the hope that it will be useful,</span>
|
||||
<span class="c"># but WITHOUT ANY WARRANTY; without even the implied warranty of</span>
|
||||
<span class="c"># MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the</span>
|
||||
<span class="c"># GNU General Public License for more details.</span>
|
||||
<span class="c">#</span>
|
||||
<span class="c"># You should have received a copy of the GNU General Public License</span>
|
||||
<span class="c"># along with this program. If not, see <http://www.gnu.org/licenses/>.</span>
|
||||
<span class="c">#</span>
|
||||
<span class="kn">import</span> <span class="nn">logging</span>
|
||||
<span class="n">log</span> <span class="o">=</span> <span class="n">logging</span><span class="o">.</span><span class="n">getLogger</span><span class="p">(</span><span class="s">"composer-cli"</span><span class="p">)</span>
|
||||
|
||||
<span class="kn">import</span> <span class="nn">sys</span>
|
||||
<span class="kn">import</span> <span class="nn">json</span>
|
||||
|
||||
<span class="kn">from</span> <span class="nn">composer</span> <span class="kn">import</span> <span class="n">http_client</span> <span class="k">as</span> <span class="n">client</span>
|
||||
<span class="kn">from</span> <span class="nn">composer.cli.utilities</span> <span class="kn">import</span> <span class="n">argify</span><span class="p">,</span> <span class="n">handle_api_result</span><span class="p">,</span> <span class="n">packageNEVRA</span>
|
||||
|
||||
<div class="viewcode-block" id="compose_cmd"><a class="viewcode-back" href="../../../composer.cli.html#composer.cli.compose.compose_cmd">[docs]</a><span class="k">def</span> <span class="nf">compose_cmd</span><span class="p">(</span><span class="n">opts</span><span class="p">):</span>
|
||||
<span class="sd">"""Process compose commands</span>
|
||||
|
||||
<span class="sd"> :param opts: Cmdline arguments</span>
|
||||
<span class="sd"> :type opts: argparse.Namespace</span>
|
||||
<span class="sd"> :returns: Value to return from sys.exit()</span>
|
||||
<span class="sd"> :rtype: int</span>
|
||||
|
||||
<span class="sd"> This dispatches the compose commands to a function</span>
|
||||
<span class="sd"> """</span>
|
||||
<span class="n">cmd_map</span> <span class="o">=</span> <span class="p">{</span>
|
||||
<span class="s">"status"</span><span class="p">:</span> <span class="n">compose_status</span><span class="p">,</span>
|
||||
<span class="s">"types"</span><span class="p">:</span> <span class="n">compose_types</span><span class="p">,</span>
|
||||
<span class="s">"start"</span><span class="p">:</span> <span class="n">compose_start</span><span class="p">,</span>
|
||||
<span class="s">"log"</span><span class="p">:</span> <span class="n">compose_log</span><span class="p">,</span>
|
||||
<span class="s">"cancel"</span><span class="p">:</span> <span class="n">compose_cancel</span><span class="p">,</span>
|
||||
<span class="s">"delete"</span><span class="p">:</span> <span class="n">compose_delete</span><span class="p">,</span>
|
||||
<span class="s">"details"</span><span class="p">:</span> <span class="n">compose_details</span><span class="p">,</span>
|
||||
<span class="s">"metadata"</span><span class="p">:</span> <span class="n">compose_metadata</span><span class="p">,</span>
|
||||
<span class="s">"results"</span><span class="p">:</span> <span class="n">compose_results</span><span class="p">,</span>
|
||||
<span class="s">"logs"</span><span class="p">:</span> <span class="n">compose_logs</span><span class="p">,</span>
|
||||
<span class="s">"image"</span><span class="p">:</span> <span class="n">compose_image</span><span class="p">,</span>
|
||||
<span class="p">}</span>
|
||||
<span class="k">if</span> <span class="n">opts</span><span class="o">.</span><span class="n">args</span><span class="p">[</span><span class="mi">1</span><span class="p">]</span> <span class="ow">not</span> <span class="ow">in</span> <span class="n">cmd_map</span><span class="p">:</span>
|
||||
<span class="n">log</span><span class="o">.</span><span class="n">error</span><span class="p">(</span><span class="s">"Unknown compose command: </span><span class="si">%s</span><span class="s">"</span><span class="p">,</span> <span class="n">opts</span><span class="o">.</span><span class="n">args</span><span class="p">[</span><span class="mi">1</span><span class="p">])</span>
|
||||
<span class="k">return</span> <span class="mi">1</span>
|
||||
|
||||
<span class="k">return</span> <span class="n">cmd_map</span><span class="p">[</span><span class="n">opts</span><span class="o">.</span><span class="n">args</span><span class="p">[</span><span class="mi">1</span><span class="p">]](</span><span class="n">opts</span><span class="o">.</span><span class="n">socket</span><span class="p">,</span> <span class="n">opts</span><span class="o">.</span><span class="n">api_version</span><span class="p">,</span> <span class="n">opts</span><span class="o">.</span><span class="n">args</span><span class="p">[</span><span class="mi">2</span><span class="p">:],</span> <span class="n">opts</span><span class="o">.</span><span class="n">json</span><span class="p">,</span> <span class="n">opts</span><span class="o">.</span><span class="n">testmode</span><span class="p">)</span>
|
||||
</div>
|
||||
<div class="viewcode-block" id="compose_status"><a class="viewcode-back" href="../../../composer.cli.html#composer.cli.compose.compose_status">[docs]</a><span class="k">def</span> <span class="nf">compose_status</span><span class="p">(</span><span class="n">socket_path</span><span class="p">,</span> <span class="n">api_version</span><span class="p">,</span> <span class="n">args</span><span class="p">,</span> <span class="n">show_json</span><span class="o">=</span><span class="bp">False</span><span class="p">,</span> <span class="n">testmode</span><span class="o">=</span><span class="mi">0</span><span class="p">):</span>
|
||||
<span class="sd">"""Return the status of all known composes</span>
|
||||
|
||||
<span class="sd"> :param socket_path: Path to the Unix socket to use for API communication</span>
|
||||
<span class="sd"> :type socket_path: str</span>
|
||||
<span class="sd"> :param api_version: Version of the API to talk to. eg. "0"</span>
|
||||
<span class="sd"> :type api_version: str</span>
|
||||
<span class="sd"> :param args: List of remaining arguments from the cmdline</span>
|
||||
<span class="sd"> :type args: list of str</span>
|
||||
<span class="sd"> :param show_json: Set to True to show the JSON output instead of the human readable output</span>
|
||||
<span class="sd"> :type show_json: bool</span>
|
||||
|
||||
<span class="sd"> This doesn't map directly to an API command, it combines the results from queue, finished,</span>
|
||||
<span class="sd"> and failed so raw JSON output is not available.</span>
|
||||
<span class="sd"> """</span>
|
||||
<span class="k">def</span> <span class="nf">get_status</span><span class="p">(</span><span class="n">compose</span><span class="p">):</span>
|
||||
<span class="k">return</span> <span class="p">{</span><span class="s">"id"</span><span class="p">:</span> <span class="n">compose</span><span class="p">[</span><span class="s">"id"</span><span class="p">],</span>
|
||||
<span class="s">"recipe"</span><span class="p">:</span> <span class="n">compose</span><span class="p">[</span><span class="s">"recipe"</span><span class="p">],</span>
|
||||
<span class="s">"version"</span><span class="p">:</span> <span class="n">compose</span><span class="p">[</span><span class="s">"version"</span><span class="p">],</span>
|
||||
<span class="s">"status"</span><span class="p">:</span> <span class="n">compose</span><span class="p">[</span><span class="s">"queue_status"</span><span class="p">]}</span>
|
||||
|
||||
<span class="c"># Sort the status in a specific order</span>
|
||||
<span class="k">def</span> <span class="nf">sort_status</span><span class="p">(</span><span class="n">a</span><span class="p">):</span>
|
||||
<span class="n">order</span> <span class="o">=</span> <span class="p">[</span><span class="s">"RUNNING"</span><span class="p">,</span> <span class="s">"WAITING"</span><span class="p">,</span> <span class="s">"FINISHED"</span><span class="p">,</span> <span class="s">"FAILED"</span><span class="p">]</span>
|
||||
<span class="k">return</span> <span class="p">(</span><span class="n">order</span><span class="o">.</span><span class="n">index</span><span class="p">(</span><span class="n">a</span><span class="p">[</span><span class="s">"status"</span><span class="p">]),</span> <span class="n">a</span><span class="p">[</span><span class="s">"recipe"</span><span class="p">],</span> <span class="n">a</span><span class="p">[</span><span class="s">"version"</span><span class="p">])</span>
|
||||
|
||||
<span class="n">status</span> <span class="o">=</span> <span class="p">[]</span>
|
||||
|
||||
<span class="c"># Get the composes currently in the queue</span>
|
||||
<span class="n">api_route</span> <span class="o">=</span> <span class="n">client</span><span class="o">.</span><span class="n">api_url</span><span class="p">(</span><span class="n">api_version</span><span class="p">,</span> <span class="s">"/compose/queue"</span><span class="p">)</span>
|
||||
<span class="n">result</span> <span class="o">=</span> <span class="n">client</span><span class="o">.</span><span class="n">get_url_json</span><span class="p">(</span><span class="n">socket_path</span><span class="p">,</span> <span class="n">api_route</span><span class="p">)</span>
|
||||
<span class="n">status</span><span class="o">.</span><span class="n">extend</span><span class="p">(</span><span class="nb">map</span><span class="p">(</span><span class="n">get_status</span><span class="p">,</span> <span class="n">result</span><span class="p">[</span><span class="s">"run"</span><span class="p">]</span> <span class="o">+</span> <span class="n">result</span><span class="p">[</span><span class="s">"new"</span><span class="p">]))</span>
|
||||
|
||||
<span class="c"># Get the list of finished composes</span>
|
||||
<span class="n">api_route</span> <span class="o">=</span> <span class="n">client</span><span class="o">.</span><span class="n">api_url</span><span class="p">(</span><span class="n">api_version</span><span class="p">,</span> <span class="s">"/compose/finished"</span><span class="p">)</span>
|
||||
<span class="n">result</span> <span class="o">=</span> <span class="n">client</span><span class="o">.</span><span class="n">get_url_json</span><span class="p">(</span><span class="n">socket_path</span><span class="p">,</span> <span class="n">api_route</span><span class="p">)</span>
|
||||
<span class="n">status</span><span class="o">.</span><span class="n">extend</span><span class="p">(</span><span class="nb">map</span><span class="p">(</span><span class="n">get_status</span><span class="p">,</span> <span class="n">result</span><span class="p">[</span><span class="s">"finished"</span><span class="p">]))</span>
|
||||
|
||||
<span class="c"># Get the list of failed composes</span>
|
||||
<span class="n">api_route</span> <span class="o">=</span> <span class="n">client</span><span class="o">.</span><span class="n">api_url</span><span class="p">(</span><span class="n">api_version</span><span class="p">,</span> <span class="s">"/compose/failed"</span><span class="p">)</span>
|
||||
<span class="n">result</span> <span class="o">=</span> <span class="n">client</span><span class="o">.</span><span class="n">get_url_json</span><span class="p">(</span><span class="n">socket_path</span><span class="p">,</span> <span class="n">api_route</span><span class="p">)</span>
|
||||
<span class="n">status</span><span class="o">.</span><span class="n">extend</span><span class="p">(</span><span class="nb">map</span><span class="p">(</span><span class="n">get_status</span><span class="p">,</span> <span class="n">result</span><span class="p">[</span><span class="s">"failed"</span><span class="p">]))</span>
|
||||
|
||||
<span class="c"># Sort them by status (running, waiting, finished, failed) and then by name and version.</span>
|
||||
<span class="n">status</span><span class="o">.</span><span class="n">sort</span><span class="p">(</span><span class="n">key</span><span class="o">=</span><span class="n">sort_status</span><span class="p">)</span>
|
||||
|
||||
<span class="k">if</span> <span class="n">show_json</span><span class="p">:</span>
|
||||
<span class="k">print</span><span class="p">(</span><span class="n">json</span><span class="o">.</span><span class="n">dumps</span><span class="p">(</span><span class="n">status</span><span class="p">,</span> <span class="n">indent</span><span class="o">=</span><span class="mi">4</span><span class="p">))</span>
|
||||
<span class="k">return</span> <span class="mi">0</span>
|
||||
|
||||
<span class="c"># Print them as UUID RECIPE STATUS</span>
|
||||
<span class="k">for</span> <span class="n">c</span> <span class="ow">in</span> <span class="n">status</span><span class="p">:</span>
|
||||
<span class="k">print</span><span class="p">(</span><span class="s">"</span><span class="si">%s</span><span class="s"> </span><span class="si">%-8s</span><span class="s"> </span><span class="si">%-15s</span><span class="s"> </span><span class="si">%s</span><span class="s">"</span> <span class="o">%</span> <span class="p">(</span><span class="n">c</span><span class="p">[</span><span class="s">"id"</span><span class="p">],</span> <span class="n">c</span><span class="p">[</span><span class="s">"status"</span><span class="p">],</span> <span class="n">c</span><span class="p">[</span><span class="s">"recipe"</span><span class="p">],</span> <span class="n">c</span><span class="p">[</span><span class="s">"version"</span><span class="p">]))</span>
|
||||
|
||||
</div>
|
||||
<div class="viewcode-block" id="compose_types"><a class="viewcode-back" href="../../../composer.cli.html#composer.cli.compose.compose_types">[docs]</a><span class="k">def</span> <span class="nf">compose_types</span><span class="p">(</span><span class="n">socket_path</span><span class="p">,</span> <span class="n">api_version</span><span class="p">,</span> <span class="n">args</span><span class="p">,</span> <span class="n">show_json</span><span class="o">=</span><span class="bp">False</span><span class="p">):</span>
|
||||
<span class="sd">"""Return information about the supported compose types</span>
|
||||
|
||||
<span class="sd"> :param socket_path: Path to the Unix socket to use for API communication</span>
|
||||
<span class="sd"> :type socket_path: str</span>
|
||||
<span class="sd"> :param api_version: Version of the API to talk to. eg. "0"</span>
|
||||
<span class="sd"> :type api_version: str</span>
|
||||
<span class="sd"> :param args: List of remaining arguments from the cmdline</span>
|
||||
<span class="sd"> :type args: list of str</span>
|
||||
<span class="sd"> :param show_json: Set to True to show the JSON output instead of the human readable output</span>
|
||||
<span class="sd"> :type show_json: bool</span>
|
||||
|
||||
<span class="sd"> Add additional details to types that are known to composer-cli. Raw JSON output does not</span>
|
||||
<span class="sd"> include this extra information.</span>
|
||||
<span class="sd"> """</span>
|
||||
<span class="n">api_route</span> <span class="o">=</span> <span class="n">client</span><span class="o">.</span><span class="n">api_url</span><span class="p">(</span><span class="n">api_version</span><span class="p">,</span> <span class="s">"/compose/types"</span><span class="p">)</span>
|
||||
<span class="n">result</span> <span class="o">=</span> <span class="n">client</span><span class="o">.</span><span class="n">get_url_json</span><span class="p">(</span><span class="n">socket_path</span><span class="p">,</span> <span class="n">api_route</span><span class="p">)</span>
|
||||
<span class="k">if</span> <span class="n">show_json</span><span class="p">:</span>
|
||||
<span class="k">print</span><span class="p">(</span><span class="n">json</span><span class="o">.</span><span class="n">dumps</span><span class="p">(</span><span class="n">result</span><span class="p">,</span> <span class="n">indent</span><span class="o">=</span><span class="mi">4</span><span class="p">))</span>
|
||||
<span class="k">return</span> <span class="mi">0</span>
|
||||
|
||||
<span class="k">print</span><span class="p">(</span><span class="s">"Compose Types: "</span> <span class="o">+</span> <span class="s">", "</span><span class="o">.</span><span class="n">join</span><span class="p">([</span><span class="n">t</span><span class="p">[</span><span class="s">"name"</span><span class="p">]</span> <span class="k">for</span> <span class="n">t</span> <span class="ow">in</span> <span class="n">result</span><span class="p">[</span><span class="s">"types"</span><span class="p">]]))</span>
|
||||
</div>
|
||||
<div class="viewcode-block" id="compose_start"><a class="viewcode-back" href="../../../composer.cli.html#composer.cli.compose.compose_start">[docs]</a><span class="k">def</span> <span class="nf">compose_start</span><span class="p">(</span><span class="n">socket_path</span><span class="p">,</span> <span class="n">api_version</span><span class="p">,</span> <span class="n">args</span><span class="p">,</span> <span class="n">show_json</span><span class="o">=</span><span class="bp">False</span><span class="p">,</span> <span class="n">testmode</span><span class="o">=</span><span class="mi">0</span><span class="p">):</span>
|
||||
<span class="sd">"""Start a new compose using the selected recipe and type</span>
|
||||
|
||||
<span class="sd"> :param socket_path: Path to the Unix socket to use for API communication</span>
|
||||
<span class="sd"> :type socket_path: str</span>
|
||||
<span class="sd"> :param api_version: Version of the API to talk to. eg. "0"</span>
|
||||
<span class="sd"> :type api_version: str</span>
|
||||
<span class="sd"> :param args: List of remaining arguments from the cmdline</span>
|
||||
<span class="sd"> :type args: list of str</span>
|
||||
<span class="sd"> :param show_json: Set to True to show the JSON output instead of the human readable output</span>
|
||||
<span class="sd"> :type show_json: bool</span>
|
||||
|
||||
<span class="sd"> compose start <recipe-name> <compose-type></span>
|
||||
<span class="sd"> """</span>
|
||||
<span class="k">if</span> <span class="nb">len</span><span class="p">(</span><span class="n">args</span><span class="p">)</span> <span class="o">==</span> <span class="mi">0</span><span class="p">:</span>
|
||||
<span class="n">log</span><span class="o">.</span><span class="n">error</span><span class="p">(</span><span class="s">"start is missing the recipe name and output type"</span><span class="p">)</span>
|
||||
<span class="k">return</span> <span class="mi">1</span>
|
||||
<span class="k">if</span> <span class="nb">len</span><span class="p">(</span><span class="n">args</span><span class="p">)</span> <span class="o">==</span> <span class="mi">1</span><span class="p">:</span>
|
||||
<span class="n">log</span><span class="o">.</span><span class="n">error</span><span class="p">(</span><span class="s">"start is missing the output type"</span><span class="p">)</span>
|
||||
<span class="k">return</span> <span class="mi">1</span>
|
||||
|
||||
<span class="n">config</span> <span class="o">=</span> <span class="p">{</span>
|
||||
<span class="s">"recipe_name"</span><span class="p">:</span> <span class="n">args</span><span class="p">[</span><span class="mi">0</span><span class="p">],</span>
|
||||
<span class="s">"compose_type"</span><span class="p">:</span> <span class="n">args</span><span class="p">[</span><span class="mi">1</span><span class="p">],</span>
|
||||
<span class="s">"branch"</span><span class="p">:</span> <span class="s">"master"</span>
|
||||
<span class="p">}</span>
|
||||
<span class="k">if</span> <span class="n">testmode</span><span class="p">:</span>
|
||||
<span class="n">test_url</span> <span class="o">=</span> <span class="s">"?test=</span><span class="si">%d</span><span class="s">"</span> <span class="o">%</span> <span class="n">testmode</span>
|
||||
<span class="k">else</span><span class="p">:</span>
|
||||
<span class="n">test_url</span> <span class="o">=</span> <span class="s">""</span>
|
||||
<span class="n">api_route</span> <span class="o">=</span> <span class="n">client</span><span class="o">.</span><span class="n">api_url</span><span class="p">(</span><span class="n">api_version</span><span class="p">,</span> <span class="s">"/compose"</span> <span class="o">+</span> <span class="n">test_url</span><span class="p">)</span>
|
||||
<span class="n">result</span> <span class="o">=</span> <span class="n">client</span><span class="o">.</span><span class="n">post_url_json</span><span class="p">(</span><span class="n">socket_path</span><span class="p">,</span> <span class="n">api_route</span><span class="p">,</span> <span class="n">json</span><span class="o">.</span><span class="n">dumps</span><span class="p">(</span><span class="n">config</span><span class="p">))</span>
|
||||
|
||||
<span class="k">if</span> <span class="n">show_json</span><span class="p">:</span>
|
||||
<span class="k">print</span><span class="p">(</span><span class="n">json</span><span class="o">.</span><span class="n">dumps</span><span class="p">(</span><span class="n">result</span><span class="p">,</span> <span class="n">indent</span><span class="o">=</span><span class="mi">4</span><span class="p">))</span>
|
||||
<span class="k">return</span> <span class="mi">0</span>
|
||||
|
||||
<span class="k">if</span> <span class="n">result</span><span class="o">.</span><span class="n">get</span><span class="p">(</span><span class="s">"error"</span><span class="p">,</span> <span class="bp">False</span><span class="p">):</span>
|
||||
<span class="n">log</span><span class="o">.</span><span class="n">error</span><span class="p">(</span><span class="n">result</span><span class="p">[</span><span class="s">"error"</span><span class="p">][</span><span class="s">"msg"</span><span class="p">])</span>
|
||||
<span class="k">return</span> <span class="mi">1</span>
|
||||
|
||||
<span class="k">if</span> <span class="n">result</span><span class="p">[</span><span class="s">"status"</span><span class="p">]</span> <span class="o">==</span> <span class="bp">False</span><span class="p">:</span>
|
||||
<span class="k">return</span> <span class="mi">1</span>
|
||||
|
||||
<span class="k">print</span><span class="p">(</span><span class="s">"Compose </span><span class="si">%s</span><span class="s"> added to the queue"</span> <span class="o">%</span> <span class="n">result</span><span class="p">[</span><span class="s">"build_id"</span><span class="p">])</span>
|
||||
<span class="k">return</span> <span class="mi">0</span>
|
||||
</div>
|
||||
<div class="viewcode-block" id="compose_log"><a class="viewcode-back" href="../../../composer.cli.html#composer.cli.compose.compose_log">[docs]</a><span class="k">def</span> <span class="nf">compose_log</span><span class="p">(</span><span class="n">socket_path</span><span class="p">,</span> <span class="n">api_version</span><span class="p">,</span> <span class="n">args</span><span class="p">,</span> <span class="n">show_json</span><span class="o">=</span><span class="bp">False</span><span class="p">,</span> <span class="n">testmode</span><span class="o">=</span><span class="mi">0</span><span class="p">):</span>
|
||||
<span class="sd">"""Show the last part of the compose log</span>
|
||||
|
||||
<span class="sd"> :param socket_path: Path to the Unix socket to use for API communication</span>
|
||||
<span class="sd"> :type socket_path: str</span>
|
||||
<span class="sd"> :param api_version: Version of the API to talk to. eg. "0"</span>
|
||||
<span class="sd"> :type api_version: str</span>
|
||||
<span class="sd"> :param args: List of remaining arguments from the cmdline</span>
|
||||
<span class="sd"> :type args: list of str</span>
|
||||
<span class="sd"> :param show_json: Set to True to show the JSON output instead of the human readable output</span>
|
||||
<span class="sd"> :type show_json: bool</span>
|
||||
|
||||
<span class="sd"> compose log <uuid> [<size>kB]</span>
|
||||
|
||||
<span class="sd"> This will display the last 1kB of the compose's log file. Can be used to follow progress</span>
|
||||
<span class="sd"> during the build.</span>
|
||||
<span class="sd"> """</span>
|
||||
<span class="k">if</span> <span class="nb">len</span><span class="p">(</span><span class="n">args</span><span class="p">)</span> <span class="o">==</span> <span class="mi">0</span><span class="p">:</span>
|
||||
<span class="n">log</span><span class="o">.</span><span class="n">error</span><span class="p">(</span><span class="s">"log is missing the compose build id"</span><span class="p">)</span>
|
||||
<span class="k">return</span> <span class="mi">1</span>
|
||||
<span class="k">if</span> <span class="nb">len</span><span class="p">(</span><span class="n">args</span><span class="p">)</span> <span class="o">==</span> <span class="mi">2</span><span class="p">:</span>
|
||||
<span class="k">try</span><span class="p">:</span>
|
||||
<span class="n">log_size</span> <span class="o">=</span> <span class="nb">int</span><span class="p">(</span><span class="n">args</span><span class="p">[</span><span class="mi">1</span><span class="p">])</span>
|
||||
<span class="k">except</span> <span class="ne">ValueError</span><span class="p">:</span>
|
||||
<span class="n">log</span><span class="o">.</span><span class="n">error</span><span class="p">(</span><span class="s">"Log size must be an integer."</span><span class="p">)</span>
|
||||
<span class="k">return</span> <span class="mi">1</span>
|
||||
<span class="k">else</span><span class="p">:</span>
|
||||
<span class="n">log_size</span> <span class="o">=</span> <span class="mi">1024</span>
|
||||
|
||||
<span class="n">api_route</span> <span class="o">=</span> <span class="n">client</span><span class="o">.</span><span class="n">api_url</span><span class="p">(</span><span class="n">api_version</span><span class="p">,</span> <span class="s">"/compose/log/</span><span class="si">%s</span><span class="s">?size=</span><span class="si">%d</span><span class="s">"</span> <span class="o">%</span> <span class="p">(</span><span class="n">args</span><span class="p">[</span><span class="mi">0</span><span class="p">],</span> <span class="n">log_size</span><span class="p">))</span>
|
||||
<span class="n">result</span> <span class="o">=</span> <span class="n">client</span><span class="o">.</span><span class="n">get_url_raw</span><span class="p">(</span><span class="n">socket_path</span><span class="p">,</span> <span class="n">api_route</span><span class="p">)</span>
|
||||
|
||||
<span class="k">print</span><span class="p">(</span><span class="n">result</span><span class="p">)</span>
|
||||
</div>
|
||||
<div class="viewcode-block" id="compose_cancel"><a class="viewcode-back" href="../../../composer.cli.html#composer.cli.compose.compose_cancel">[docs]</a><span class="k">def</span> <span class="nf">compose_cancel</span><span class="p">(</span><span class="n">socket_path</span><span class="p">,</span> <span class="n">api_version</span><span class="p">,</span> <span class="n">args</span><span class="p">,</span> <span class="n">show_json</span><span class="o">=</span><span class="bp">False</span><span class="p">,</span> <span class="n">testmode</span><span class="o">=</span><span class="mi">0</span><span class="p">):</span>
|
||||
<span class="sd">"""Cancel a running compose</span>
|
||||
|
||||
<span class="sd"> :param socket_path: Path to the Unix socket to use for API communication</span>
|
||||
<span class="sd"> :type socket_path: str</span>
|
||||
<span class="sd"> :param api_version: Version of the API to talk to. eg. "0"</span>
|
||||
<span class="sd"> :type api_version: str</span>
|
||||
<span class="sd"> :param args: List of remaining arguments from the cmdline</span>
|
||||
<span class="sd"> :type args: list of str</span>
|
||||
<span class="sd"> :param show_json: Set to True to show the JSON output instead of the human readable output</span>
|
||||
<span class="sd"> :type show_json: bool</span>
|
||||
|
||||
<span class="sd"> compose cancel <uuid></span>
|
||||
|
||||
<span class="sd"> This will cancel a running compose. It does nothing if the compose has finished.</span>
|
||||
<span class="sd"> """</span>
|
||||
<span class="k">if</span> <span class="nb">len</span><span class="p">(</span><span class="n">args</span><span class="p">)</span> <span class="o">==</span> <span class="mi">0</span><span class="p">:</span>
|
||||
<span class="n">log</span><span class="o">.</span><span class="n">error</span><span class="p">(</span><span class="s">"cancel is missing the compose build id"</span><span class="p">)</span>
|
||||
<span class="k">return</span> <span class="mi">1</span>
|
||||
|
||||
<span class="n">api_route</span> <span class="o">=</span> <span class="n">client</span><span class="o">.</span><span class="n">api_url</span><span class="p">(</span><span class="n">api_version</span><span class="p">,</span> <span class="s">"/compose/cancel/</span><span class="si">%s</span><span class="s">"</span> <span class="o">%</span> <span class="n">args</span><span class="p">[</span><span class="mi">0</span><span class="p">])</span>
|
||||
<span class="n">result</span> <span class="o">=</span> <span class="n">client</span><span class="o">.</span><span class="n">delete_url_json</span><span class="p">(</span><span class="n">socket_path</span><span class="p">,</span> <span class="n">api_route</span><span class="p">)</span>
|
||||
<span class="k">return</span> <span class="n">handle_api_result</span><span class="p">(</span><span class="n">result</span><span class="p">,</span> <span class="n">show_json</span><span class="p">)</span>
|
||||
</div>
|
||||
<div class="viewcode-block" id="compose_delete"><a class="viewcode-back" href="../../../composer.cli.html#composer.cli.compose.compose_delete">[docs]</a><span class="k">def</span> <span class="nf">compose_delete</span><span class="p">(</span><span class="n">socket_path</span><span class="p">,</span> <span class="n">api_version</span><span class="p">,</span> <span class="n">args</span><span class="p">,</span> <span class="n">show_json</span><span class="o">=</span><span class="bp">False</span><span class="p">,</span> <span class="n">testmode</span><span class="o">=</span><span class="mi">0</span><span class="p">):</span>
|
||||
<span class="sd">"""Delete a finished compose's results</span>
|
||||
|
||||
<span class="sd"> :param socket_path: Path to the Unix socket to use for API communication</span>
|
||||
<span class="sd"> :type socket_path: str</span>
|
||||
<span class="sd"> :param api_version: Version of the API to talk to. eg. "0"</span>
|
||||
<span class="sd"> :type api_version: str</span>
|
||||
<span class="sd"> :param args: List of remaining arguments from the cmdline</span>
|
||||
<span class="sd"> :type args: list of str</span>
|
||||
<span class="sd"> :param show_json: Set to True to show the JSON output instead of the human readable output</span>
|
||||
<span class="sd"> :type show_json: bool</span>
|
||||
|
||||
<span class="sd"> compose delete <uuid,...></span>
|
||||
|
||||
<span class="sd"> Delete the listed compose results. It will only delete results for composes that have finished</span>
|
||||
<span class="sd"> or failed, not a running compose.</span>
|
||||
<span class="sd"> """</span>
|
||||
<span class="k">if</span> <span class="nb">len</span><span class="p">(</span><span class="n">args</span><span class="p">)</span> <span class="o">==</span> <span class="mi">0</span><span class="p">:</span>
|
||||
<span class="n">log</span><span class="o">.</span><span class="n">error</span><span class="p">(</span><span class="s">"delete is missing the compose build id"</span><span class="p">)</span>
|
||||
<span class="k">return</span> <span class="mi">1</span>
|
||||
|
||||
<span class="n">api_route</span> <span class="o">=</span> <span class="n">client</span><span class="o">.</span><span class="n">api_url</span><span class="p">(</span><span class="n">api_version</span><span class="p">,</span> <span class="s">"/compose/delete/</span><span class="si">%s</span><span class="s">"</span> <span class="o">%</span> <span class="p">(</span><span class="s">","</span><span class="o">.</span><span class="n">join</span><span class="p">(</span><span class="n">argify</span><span class="p">(</span><span class="n">args</span><span class="p">))))</span>
|
||||
<span class="n">result</span> <span class="o">=</span> <span class="n">client</span><span class="o">.</span><span class="n">delete_url_json</span><span class="p">(</span><span class="n">socket_path</span><span class="p">,</span> <span class="n">api_route</span><span class="p">)</span>
|
||||
|
||||
<span class="k">if</span> <span class="n">show_json</span><span class="p">:</span>
|
||||
<span class="k">print</span><span class="p">(</span><span class="n">json</span><span class="o">.</span><span class="n">dumps</span><span class="p">(</span><span class="n">result</span><span class="p">,</span> <span class="n">indent</span><span class="o">=</span><span class="mi">4</span><span class="p">))</span>
|
||||
<span class="k">return</span> <span class="mi">0</span>
|
||||
|
||||
<span class="c"># Print any errors</span>
|
||||
<span class="k">for</span> <span class="n">err</span> <span class="ow">in</span> <span class="n">result</span><span class="o">.</span><span class="n">get</span><span class="p">(</span><span class="s">"errors"</span><span class="p">,</span> <span class="p">[]):</span>
|
||||
<span class="n">log</span><span class="o">.</span><span class="n">error</span><span class="p">(</span><span class="s">"</span><span class="si">%s</span><span class="s">: </span><span class="si">%s</span><span class="s">"</span><span class="p">,</span> <span class="n">err</span><span class="p">[</span><span class="s">"uuid"</span><span class="p">],</span> <span class="n">err</span><span class="p">[</span><span class="s">"msg"</span><span class="p">])</span>
|
||||
|
||||
<span class="k">if</span> <span class="n">result</span><span class="o">.</span><span class="n">get</span><span class="p">(</span><span class="s">"errors"</span><span class="p">,</span> <span class="p">[]):</span>
|
||||
<span class="k">return</span> <span class="mi">1</span>
|
||||
<span class="k">else</span><span class="p">:</span>
|
||||
<span class="k">return</span> <span class="mi">0</span>
|
||||
</div>
|
||||
<div class="viewcode-block" id="compose_details"><a class="viewcode-back" href="../../../composer.cli.html#composer.cli.compose.compose_details">[docs]</a><span class="k">def</span> <span class="nf">compose_details</span><span class="p">(</span><span class="n">socket_path</span><span class="p">,</span> <span class="n">api_version</span><span class="p">,</span> <span class="n">args</span><span class="p">,</span> <span class="n">show_json</span><span class="o">=</span><span class="bp">False</span><span class="p">,</span> <span class="n">testmode</span><span class="o">=</span><span class="mi">0</span><span class="p">):</span>
|
||||
<span class="sd">"""Return detailed information about the compose</span>
|
||||
|
||||
<span class="sd"> :param socket_path: Path to the Unix socket to use for API communication</span>
|
||||
<span class="sd"> :type socket_path: str</span>
|
||||
<span class="sd"> :param api_version: Version of the API to talk to. eg. "0"</span>
|
||||
<span class="sd"> :type api_version: str</span>
|
||||
<span class="sd"> :param args: List of remaining arguments from the cmdline</span>
|
||||
<span class="sd"> :type args: list of str</span>
|
||||
<span class="sd"> :param show_json: Set to True to show the JSON output instead of the human readable output</span>
|
||||
<span class="sd"> :type show_json: bool</span>
|
||||
|
||||
<span class="sd"> compose details <uuid></span>
|
||||
|
||||
<span class="sd"> This returns information about the compose, including the recipe and the dependencies.</span>
|
||||
<span class="sd"> """</span>
|
||||
<span class="k">if</span> <span class="nb">len</span><span class="p">(</span><span class="n">args</span><span class="p">)</span> <span class="o">==</span> <span class="mi">0</span><span class="p">:</span>
|
||||
<span class="n">log</span><span class="o">.</span><span class="n">error</span><span class="p">(</span><span class="s">"details is missing the compose build id"</span><span class="p">)</span>
|
||||
<span class="k">return</span> <span class="mi">1</span>
|
||||
|
||||
<span class="n">api_route</span> <span class="o">=</span> <span class="n">client</span><span class="o">.</span><span class="n">api_url</span><span class="p">(</span><span class="n">api_version</span><span class="p">,</span> <span class="s">"/compose/info/</span><span class="si">%s</span><span class="s">"</span> <span class="o">%</span> <span class="n">args</span><span class="p">[</span><span class="mi">0</span><span class="p">])</span>
|
||||
<span class="n">result</span> <span class="o">=</span> <span class="n">client</span><span class="o">.</span><span class="n">get_url_json</span><span class="p">(</span><span class="n">socket_path</span><span class="p">,</span> <span class="n">api_route</span><span class="p">)</span>
|
||||
<span class="k">if</span> <span class="n">show_json</span><span class="p">:</span>
|
||||
<span class="k">print</span><span class="p">(</span><span class="n">json</span><span class="o">.</span><span class="n">dumps</span><span class="p">(</span><span class="n">result</span><span class="p">,</span> <span class="n">indent</span><span class="o">=</span><span class="mi">4</span><span class="p">))</span>
|
||||
<span class="k">return</span> <span class="mi">0</span>
|
||||
|
||||
<span class="k">print</span><span class="p">(</span><span class="s">"</span><span class="si">%s</span><span class="s"> </span><span class="si">%-8s</span><span class="s"> </span><span class="si">%-15s</span><span class="s"> </span><span class="si">%s</span><span class="s"> </span><span class="si">%s</span><span class="s">"</span> <span class="o">%</span> <span class="p">(</span><span class="n">result</span><span class="p">[</span><span class="s">"id"</span><span class="p">],</span>
|
||||
<span class="n">result</span><span class="p">[</span><span class="s">"queue_status"</span><span class="p">],</span>
|
||||
<span class="n">result</span><span class="p">[</span><span class="s">"recipe"</span><span class="p">][</span><span class="s">"name"</span><span class="p">],</span>
|
||||
<span class="n">result</span><span class="p">[</span><span class="s">"recipe"</span><span class="p">][</span><span class="s">"version"</span><span class="p">],</span>
|
||||
<span class="n">result</span><span class="p">[</span><span class="s">"compose_type"</span><span class="p">]))</span>
|
||||
<span class="k">print</span><span class="p">(</span><span class="s">"Recipe Packages:"</span><span class="p">)</span>
|
||||
<span class="k">for</span> <span class="n">p</span> <span class="ow">in</span> <span class="n">result</span><span class="p">[</span><span class="s">"recipe"</span><span class="p">][</span><span class="s">"packages"</span><span class="p">]:</span>
|
||||
<span class="k">print</span><span class="p">(</span><span class="s">" </span><span class="si">%s</span><span class="s">-</span><span class="si">%s</span><span class="s">"</span> <span class="o">%</span> <span class="p">(</span><span class="n">p</span><span class="p">[</span><span class="s">"name"</span><span class="p">],</span> <span class="n">p</span><span class="p">[</span><span class="s">"version"</span><span class="p">]))</span>
|
||||
|
||||
<span class="k">print</span><span class="p">(</span><span class="s">"Recipe Modules:"</span><span class="p">)</span>
|
||||
<span class="k">for</span> <span class="n">m</span> <span class="ow">in</span> <span class="n">result</span><span class="p">[</span><span class="s">"recipe"</span><span class="p">][</span><span class="s">"modules"</span><span class="p">]:</span>
|
||||
<span class="k">print</span><span class="p">(</span><span class="s">" </span><span class="si">%s</span><span class="s">-</span><span class="si">%s</span><span class="s">"</span> <span class="o">%</span> <span class="p">(</span><span class="n">m</span><span class="p">[</span><span class="s">"name"</span><span class="p">],</span> <span class="n">m</span><span class="p">[</span><span class="s">"version"</span><span class="p">]))</span>
|
||||
|
||||
<span class="k">print</span><span class="p">(</span><span class="s">"Dependencies:"</span><span class="p">)</span>
|
||||
<span class="k">for</span> <span class="n">d</span> <span class="ow">in</span> <span class="n">result</span><span class="p">[</span><span class="s">"deps"</span><span class="p">][</span><span class="s">"packages"</span><span class="p">]:</span>
|
||||
<span class="k">print</span><span class="p">(</span><span class="s">" "</span> <span class="o">+</span> <span class="n">packageNEVRA</span><span class="p">(</span><span class="n">d</span><span class="p">))</span>
|
||||
</div>
|
||||
<div class="viewcode-block" id="compose_metadata"><a class="viewcode-back" href="../../../composer.cli.html#composer.cli.compose.compose_metadata">[docs]</a><span class="k">def</span> <span class="nf">compose_metadata</span><span class="p">(</span><span class="n">socket_path</span><span class="p">,</span> <span class="n">api_version</span><span class="p">,</span> <span class="n">args</span><span class="p">,</span> <span class="n">show_json</span><span class="o">=</span><span class="bp">False</span><span class="p">,</span> <span class="n">testmode</span><span class="o">=</span><span class="mi">0</span><span class="p">):</span>
|
||||
<span class="sd">"""Download a tar file of the compose's metadata</span>
|
||||
|
||||
<span class="sd"> :param socket_path: Path to the Unix socket to use for API communication</span>
|
||||
<span class="sd"> :type socket_path: str</span>
|
||||
<span class="sd"> :param api_version: Version of the API to talk to. eg. "0"</span>
|
||||
<span class="sd"> :type api_version: str</span>
|
||||
<span class="sd"> :param args: List of remaining arguments from the cmdline</span>
|
||||
<span class="sd"> :type args: list of str</span>
|
||||
<span class="sd"> :param show_json: Set to True to show the JSON output instead of the human readable output</span>
|
||||
<span class="sd"> :type show_json: bool</span>
|
||||
|
||||
<span class="sd"> compose metadata <uuid></span>
|
||||
|
||||
<span class="sd"> Saves the metadata as uuid-metadata.tar</span>
|
||||
<span class="sd"> """</span>
|
||||
<span class="k">if</span> <span class="nb">len</span><span class="p">(</span><span class="n">args</span><span class="p">)</span> <span class="o">==</span> <span class="mi">0</span><span class="p">:</span>
|
||||
<span class="n">log</span><span class="o">.</span><span class="n">error</span><span class="p">(</span><span class="s">"metadata is missing the compose build id"</span><span class="p">)</span>
|
||||
<span class="k">return</span> <span class="mi">1</span>
|
||||
|
||||
<span class="n">api_route</span> <span class="o">=</span> <span class="n">client</span><span class="o">.</span><span class="n">api_url</span><span class="p">(</span><span class="n">api_version</span><span class="p">,</span> <span class="s">"/compose/metadata/</span><span class="si">%s</span><span class="s">"</span> <span class="o">%</span> <span class="n">args</span><span class="p">[</span><span class="mi">0</span><span class="p">])</span>
|
||||
<span class="k">return</span> <span class="n">client</span><span class="o">.</span><span class="n">download_file</span><span class="p">(</span><span class="n">socket_path</span><span class="p">,</span> <span class="n">api_route</span><span class="p">)</span>
|
||||
</div>
|
||||
<div class="viewcode-block" id="compose_results"><a class="viewcode-back" href="../../../composer.cli.html#composer.cli.compose.compose_results">[docs]</a><span class="k">def</span> <span class="nf">compose_results</span><span class="p">(</span><span class="n">socket_path</span><span class="p">,</span> <span class="n">api_version</span><span class="p">,</span> <span class="n">args</span><span class="p">,</span> <span class="n">show_json</span><span class="o">=</span><span class="bp">False</span><span class="p">,</span> <span class="n">testmode</span><span class="o">=</span><span class="mi">0</span><span class="p">):</span>
|
||||
<span class="sd">"""Download a tar file of the compose's results</span>
|
||||
|
||||
<span class="sd"> :param socket_path: Path to the Unix socket to use for API communication</span>
|
||||
<span class="sd"> :type socket_path: str</span>
|
||||
<span class="sd"> :param api_version: Version of the API to talk to. eg. "0"</span>
|
||||
<span class="sd"> :type api_version: str</span>
|
||||
<span class="sd"> :param args: List of remaining arguments from the cmdline</span>
|
||||
<span class="sd"> :type args: list of str</span>
|
||||
<span class="sd"> :param show_json: Set to True to show the JSON output instead of the human readable output</span>
|
||||
<span class="sd"> :type show_json: bool</span>
|
||||
|
||||
<span class="sd"> compose results <uuid></span>
|
||||
|
||||
<span class="sd"> The results includes the metadata, output image, and logs.</span>
|
||||
<span class="sd"> It is saved as uuid.tar</span>
|
||||
<span class="sd"> """</span>
|
||||
<span class="k">if</span> <span class="nb">len</span><span class="p">(</span><span class="n">args</span><span class="p">)</span> <span class="o">==</span> <span class="mi">0</span><span class="p">:</span>
|
||||
<span class="n">log</span><span class="o">.</span><span class="n">error</span><span class="p">(</span><span class="s">"results is missing the compose build id"</span><span class="p">)</span>
|
||||
<span class="k">return</span> <span class="mi">1</span>
|
||||
|
||||
<span class="n">api_route</span> <span class="o">=</span> <span class="n">client</span><span class="o">.</span><span class="n">api_url</span><span class="p">(</span><span class="n">api_version</span><span class="p">,</span> <span class="s">"/compose/results/</span><span class="si">%s</span><span class="s">"</span> <span class="o">%</span> <span class="n">args</span><span class="p">[</span><span class="mi">0</span><span class="p">])</span>
|
||||
<span class="k">return</span> <span class="n">client</span><span class="o">.</span><span class="n">download_file</span><span class="p">(</span><span class="n">socket_path</span><span class="p">,</span> <span class="n">api_route</span><span class="p">,</span> <span class="n">sys</span><span class="o">.</span><span class="n">stdout</span><span class="o">.</span><span class="n">isatty</span><span class="p">())</span>
|
||||
</div>
|
||||
<div class="viewcode-block" id="compose_logs"><a class="viewcode-back" href="../../../composer.cli.html#composer.cli.compose.compose_logs">[docs]</a><span class="k">def</span> <span class="nf">compose_logs</span><span class="p">(</span><span class="n">socket_path</span><span class="p">,</span> <span class="n">api_version</span><span class="p">,</span> <span class="n">args</span><span class="p">,</span> <span class="n">show_json</span><span class="o">=</span><span class="bp">False</span><span class="p">,</span> <span class="n">testmode</span><span class="o">=</span><span class="mi">0</span><span class="p">):</span>
|
||||
<span class="sd">"""Download a tar of the compose's logs</span>
|
||||
|
||||
<span class="sd"> :param socket_path: Path to the Unix socket to use for API communication</span>
|
||||
<span class="sd"> :type socket_path: str</span>
|
||||
<span class="sd"> :param api_version: Version of the API to talk to. eg. "0"</span>
|
||||
<span class="sd"> :type api_version: str</span>
|
||||
<span class="sd"> :param args: List of remaining arguments from the cmdline</span>
|
||||
<span class="sd"> :type args: list of str</span>
|
||||
<span class="sd"> :param show_json: Set to True to show the JSON output instead of the human readable output</span>
|
||||
<span class="sd"> :type show_json: bool</span>
|
||||
|
||||
<span class="sd"> compose logs <uuid></span>
|
||||
|
||||
<span class="sd"> Saves the logs as uuid-logs.tar</span>
|
||||
<span class="sd"> """</span>
|
||||
<span class="k">if</span> <span class="nb">len</span><span class="p">(</span><span class="n">args</span><span class="p">)</span> <span class="o">==</span> <span class="mi">0</span><span class="p">:</span>
|
||||
<span class="n">log</span><span class="o">.</span><span class="n">error</span><span class="p">(</span><span class="s">"logs is missing the compose build id"</span><span class="p">)</span>
|
||||
<span class="k">return</span> <span class="mi">1</span>
|
||||
|
||||
<span class="n">api_route</span> <span class="o">=</span> <span class="n">client</span><span class="o">.</span><span class="n">api_url</span><span class="p">(</span><span class="n">api_version</span><span class="p">,</span> <span class="s">"/compose/logs/</span><span class="si">%s</span><span class="s">"</span> <span class="o">%</span> <span class="n">args</span><span class="p">[</span><span class="mi">0</span><span class="p">])</span>
|
||||
<span class="k">return</span> <span class="n">client</span><span class="o">.</span><span class="n">download_file</span><span class="p">(</span><span class="n">socket_path</span><span class="p">,</span> <span class="n">api_route</span><span class="p">,</span> <span class="n">sys</span><span class="o">.</span><span class="n">stdout</span><span class="o">.</span><span class="n">isatty</span><span class="p">())</span>
|
||||
</div>
|
||||
<div class="viewcode-block" id="compose_image"><a class="viewcode-back" href="../../../composer.cli.html#composer.cli.compose.compose_image">[docs]</a><span class="k">def</span> <span class="nf">compose_image</span><span class="p">(</span><span class="n">socket_path</span><span class="p">,</span> <span class="n">api_version</span><span class="p">,</span> <span class="n">args</span><span class="p">,</span> <span class="n">show_json</span><span class="o">=</span><span class="bp">False</span><span class="p">,</span> <span class="n">testmode</span><span class="o">=</span><span class="mi">0</span><span class="p">):</span>
|
||||
<span class="sd">"""Download the compose's output image</span>
|
||||
|
||||
<span class="sd"> :param socket_path: Path to the Unix socket to use for API communication</span>
|
||||
<span class="sd"> :type socket_path: str</span>
|
||||
<span class="sd"> :param api_version: Version of the API to talk to. eg. "0"</span>
|
||||
<span class="sd"> :type api_version: str</span>
|
||||
<span class="sd"> :param args: List of remaining arguments from the cmdline</span>
|
||||
<span class="sd"> :type args: list of str</span>
|
||||
<span class="sd"> :param show_json: Set to True to show the JSON output instead of the human readable output</span>
|
||||
<span class="sd"> :type show_json: bool</span>
|
||||
|
||||
<span class="sd"> compose image <uuid></span>
|
||||
|
||||
<span class="sd"> This downloads only the result image, saving it as the image name, which depends on the type</span>
|
||||
<span class="sd"> of compose that was selected.</span>
|
||||
<span class="sd"> """</span>
|
||||
<span class="k">if</span> <span class="nb">len</span><span class="p">(</span><span class="n">args</span><span class="p">)</span> <span class="o">==</span> <span class="mi">0</span><span class="p">:</span>
|
||||
<span class="n">log</span><span class="o">.</span><span class="n">error</span><span class="p">(</span><span class="s">"logs is missing the compose build id"</span><span class="p">)</span>
|
||||
<span class="k">return</span> <span class="mi">1</span>
|
||||
|
||||
<span class="n">api_route</span> <span class="o">=</span> <span class="n">client</span><span class="o">.</span><span class="n">api_url</span><span class="p">(</span><span class="n">api_version</span><span class="p">,</span> <span class="s">"/compose/image/</span><span class="si">%s</span><span class="s">"</span> <span class="o">%</span> <span class="n">args</span><span class="p">[</span><span class="mi">0</span><span class="p">])</span>
|
||||
<span class="k">return</span> <span class="n">client</span><span class="o">.</span><span class="n">download_file</span><span class="p">(</span><span class="n">socket_path</span><span class="p">,</span> <span class="n">api_route</span><span class="p">,</span> <span class="n">sys</span><span class="o">.</span><span class="n">stdout</span><span class="o">.</span><span class="n">isatty</span><span class="p">())</span></div>
|
||||
</pre></div>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="sphinxsidebar">
|
||||
<div class="sphinxsidebarwrapper">
|
||||
<div id="searchbox" style="display: none">
|
||||
<h3>Quick search</h3>
|
||||
<form class="search" action="../../../search.html" method="get">
|
||||
<input type="text" name="q" />
|
||||
<input type="submit" value="Go" />
|
||||
<input type="hidden" name="check_keywords" value="yes" />
|
||||
<input type="hidden" name="area" value="default" />
|
||||
</form>
|
||||
<p class="searchtip" style="font-size: 90%">
|
||||
Enter search terms or a module, class or function name.
|
||||
</p>
|
||||
</div>
|
||||
<script type="text/javascript">$('#searchbox').show(0);</script>
|
||||
</div>
|
||||
</div>
|
||||
<div class="clearer"></div>
|
||||
</div>
|
||||
<div class="related">
|
||||
<h3>Navigation</h3>
|
||||
<ul>
|
||||
<li class="right" style="margin-right: 10px">
|
||||
<a href="../../../genindex.html" title="General Index"
|
||||
>index</a></li>
|
||||
<li class="right" >
|
||||
<a href="../../../py-modindex.html" title="Python Module Index"
|
||||
>modules</a> |</li>
|
||||
<li><a href="../../../index.html">Lorax 19.7.11 documentation</a> »</li>
|
||||
<li><a href="../../index.html" >Module code</a> »</li>
|
||||
<li><a href="../cli.html" >composer.cli</a> »</li>
|
||||
</ul>
|
||||
</div>
|
||||
<div class="footer">
|
||||
© Copyright 2018, Red Hat, Inc..
|
||||
Created using <a href="http://sphinx.pocoo.org/">Sphinx</a> 1.1.3.
|
||||
</div>
|
||||
</body>
|
||||
</html>
|
140
lorax-composer/_modules/composer/cli/modules.html
Normal file
140
lorax-composer/_modules/composer/cli/modules.html
Normal file
@ -0,0 +1,140 @@
|
||||
|
||||
|
||||
<!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>composer.cli.modules — Lorax 19.7.11 documentation</title>
|
||||
|
||||
<link rel="stylesheet" href="../../../_static/default.css" type="text/css" />
|
||||
<link rel="stylesheet" href="../../../_static/pygments.css" type="text/css" />
|
||||
|
||||
<script type="text/javascript">
|
||||
var DOCUMENTATION_OPTIONS = {
|
||||
URL_ROOT: '../../../',
|
||||
VERSION: '19.7.11',
|
||||
COLLAPSE_INDEX: false,
|
||||
FILE_SUFFIX: '.html',
|
||||
HAS_SOURCE: true
|
||||
};
|
||||
</script>
|
||||
<script type="text/javascript" src="../../../_static/jquery.js"></script>
|
||||
<script type="text/javascript" src="../../../_static/underscore.js"></script>
|
||||
<script type="text/javascript" src="../../../_static/doctools.js"></script>
|
||||
<link rel="top" title="Lorax 19.7.11 documentation" href="../../../index.html" />
|
||||
<link rel="up" title="composer.cli" href="../cli.html" />
|
||||
</head>
|
||||
<body>
|
||||
<div class="related">
|
||||
<h3>Navigation</h3>
|
||||
<ul>
|
||||
<li class="right" style="margin-right: 10px">
|
||||
<a href="../../../genindex.html" title="General Index"
|
||||
accesskey="I">index</a></li>
|
||||
<li class="right" >
|
||||
<a href="../../../py-modindex.html" title="Python Module Index"
|
||||
>modules</a> |</li>
|
||||
<li><a href="../../../index.html">Lorax 19.7.11 documentation</a> »</li>
|
||||
<li><a href="../../index.html" >Module code</a> »</li>
|
||||
<li><a href="../cli.html" accesskey="U">composer.cli</a> »</li>
|
||||
</ul>
|
||||
</div>
|
||||
|
||||
<div class="document">
|
||||
<div class="documentwrapper">
|
||||
<div class="bodywrapper">
|
||||
<div class="body">
|
||||
|
||||
<h1>Source code for composer.cli.modules</h1><div class="highlight"><pre>
|
||||
<span class="c">#</span>
|
||||
<span class="c"># Copyright (C) 2018 Red Hat, Inc.</span>
|
||||
<span class="c">#</span>
|
||||
<span class="c"># This program is free software; you can redistribute it and/or modify</span>
|
||||
<span class="c"># it under the terms of the GNU General Public License as published by</span>
|
||||
<span class="c"># the Free Software Foundation; either version 2 of the License, or</span>
|
||||
<span class="c"># (at your option) any later version.</span>
|
||||
<span class="c">#</span>
|
||||
<span class="c"># This program is distributed in the hope that it will be useful,</span>
|
||||
<span class="c"># but WITHOUT ANY WARRANTY; without even the implied warranty of</span>
|
||||
<span class="c"># MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the</span>
|
||||
<span class="c"># GNU General Public License for more details.</span>
|
||||
<span class="c">#</span>
|
||||
<span class="c"># You should have received a copy of the GNU General Public License</span>
|
||||
<span class="c"># along with this program. If not, see <http://www.gnu.org/licenses/>.</span>
|
||||
<span class="c">#</span>
|
||||
<span class="kn">import</span> <span class="nn">logging</span>
|
||||
<span class="n">log</span> <span class="o">=</span> <span class="n">logging</span><span class="o">.</span><span class="n">getLogger</span><span class="p">(</span><span class="s">"composer-cli"</span><span class="p">)</span>
|
||||
|
||||
<span class="kn">import</span> <span class="nn">json</span>
|
||||
|
||||
<span class="kn">from</span> <span class="nn">composer</span> <span class="kn">import</span> <span class="n">http_client</span> <span class="k">as</span> <span class="n">client</span>
|
||||
|
||||
<div class="viewcode-block" id="modules_cmd"><a class="viewcode-back" href="../../../composer.cli.html#composer.cli.modules.modules_cmd">[docs]</a><span class="k">def</span> <span class="nf">modules_cmd</span><span class="p">(</span><span class="n">opts</span><span class="p">):</span>
|
||||
<span class="sd">"""Process modules commands</span>
|
||||
|
||||
<span class="sd"> :param opts: Cmdline arguments</span>
|
||||
<span class="sd"> :type opts: argparse.Namespace</span>
|
||||
<span class="sd"> :returns: Value to return from sys.exit()</span>
|
||||
<span class="sd"> :rtype: int</span>
|
||||
<span class="sd"> """</span>
|
||||
<span class="k">if</span> <span class="n">opts</span><span class="o">.</span><span class="n">args</span><span class="p">[</span><span class="mi">1</span><span class="p">]</span> <span class="o">!=</span> <span class="s">"list"</span><span class="p">:</span>
|
||||
<span class="n">log</span><span class="o">.</span><span class="n">error</span><span class="p">(</span><span class="s">"Unknown modules command: </span><span class="si">%s</span><span class="s">"</span><span class="p">,</span> <span class="n">opts</span><span class="o">.</span><span class="n">args</span><span class="p">[</span><span class="mi">1</span><span class="p">])</span>
|
||||
<span class="k">return</span> <span class="mi">1</span>
|
||||
|
||||
<span class="n">api_route</span> <span class="o">=</span> <span class="n">client</span><span class="o">.</span><span class="n">api_url</span><span class="p">(</span><span class="n">opts</span><span class="o">.</span><span class="n">api_version</span><span class="p">,</span> <span class="s">"/modules/list"</span><span class="p">)</span>
|
||||
<span class="n">result</span> <span class="o">=</span> <span class="n">client</span><span class="o">.</span><span class="n">get_url_json</span><span class="p">(</span><span class="n">opts</span><span class="o">.</span><span class="n">socket</span><span class="p">,</span> <span class="n">api_route</span><span class="p">)</span>
|
||||
<span class="k">if</span> <span class="n">opts</span><span class="o">.</span><span class="n">json</span><span class="p">:</span>
|
||||
<span class="k">print</span><span class="p">(</span><span class="n">json</span><span class="o">.</span><span class="n">dumps</span><span class="p">(</span><span class="n">result</span><span class="p">,</span> <span class="n">indent</span><span class="o">=</span><span class="mi">4</span><span class="p">))</span>
|
||||
<span class="k">return</span> <span class="mi">0</span>
|
||||
|
||||
<span class="k">print</span><span class="p">(</span><span class="s">"Modules:</span><span class="se">\n</span><span class="s">"</span> <span class="o">+</span> <span class="s">"</span><span class="se">\n</span><span class="s">"</span><span class="o">.</span><span class="n">join</span><span class="p">([</span><span class="s">" "</span><span class="o">+</span><span class="n">r</span><span class="p">[</span><span class="s">"name"</span><span class="p">]</span> <span class="k">for</span> <span class="n">r</span> <span class="ow">in</span> <span class="n">result</span><span class="p">[</span><span class="s">"modules"</span><span class="p">]]))</span>
|
||||
|
||||
<span class="k">return</span> <span class="mi">0</span></div>
|
||||
</pre></div>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="sphinxsidebar">
|
||||
<div class="sphinxsidebarwrapper">
|
||||
<div id="searchbox" style="display: none">
|
||||
<h3>Quick search</h3>
|
||||
<form class="search" action="../../../search.html" method="get">
|
||||
<input type="text" name="q" />
|
||||
<input type="submit" value="Go" />
|
||||
<input type="hidden" name="check_keywords" value="yes" />
|
||||
<input type="hidden" name="area" value="default" />
|
||||
</form>
|
||||
<p class="searchtip" style="font-size: 90%">
|
||||
Enter search terms or a module, class or function name.
|
||||
</p>
|
||||
</div>
|
||||
<script type="text/javascript">$('#searchbox').show(0);</script>
|
||||
</div>
|
||||
</div>
|
||||
<div class="clearer"></div>
|
||||
</div>
|
||||
<div class="related">
|
||||
<h3>Navigation</h3>
|
||||
<ul>
|
||||
<li class="right" style="margin-right: 10px">
|
||||
<a href="../../../genindex.html" title="General Index"
|
||||
>index</a></li>
|
||||
<li class="right" >
|
||||
<a href="../../../py-modindex.html" title="Python Module Index"
|
||||
>modules</a> |</li>
|
||||
<li><a href="../../../index.html">Lorax 19.7.11 documentation</a> »</li>
|
||||
<li><a href="../../index.html" >Module code</a> »</li>
|
||||
<li><a href="../cli.html" >composer.cli</a> »</li>
|
||||
</ul>
|
||||
</div>
|
||||
<div class="footer">
|
||||
© Copyright 2018, Red Hat, Inc..
|
||||
Created using <a href="http://sphinx.pocoo.org/">Sphinx</a> 1.1.3.
|
||||
</div>
|
||||
</body>
|
||||
</html>
|
202
lorax-composer/_modules/composer/cli/projects.html
Normal file
202
lorax-composer/_modules/composer/cli/projects.html
Normal file
@ -0,0 +1,202 @@
|
||||
|
||||
|
||||
<!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>composer.cli.projects — Lorax 19.7.11 documentation</title>
|
||||
|
||||
<link rel="stylesheet" href="../../../_static/default.css" type="text/css" />
|
||||
<link rel="stylesheet" href="../../../_static/pygments.css" type="text/css" />
|
||||
|
||||
<script type="text/javascript">
|
||||
var DOCUMENTATION_OPTIONS = {
|
||||
URL_ROOT: '../../../',
|
||||
VERSION: '19.7.11',
|
||||
COLLAPSE_INDEX: false,
|
||||
FILE_SUFFIX: '.html',
|
||||
HAS_SOURCE: true
|
||||
};
|
||||
</script>
|
||||
<script type="text/javascript" src="../../../_static/jquery.js"></script>
|
||||
<script type="text/javascript" src="../../../_static/underscore.js"></script>
|
||||
<script type="text/javascript" src="../../../_static/doctools.js"></script>
|
||||
<link rel="top" title="Lorax 19.7.11 documentation" href="../../../index.html" />
|
||||
<link rel="up" title="composer.cli" href="../cli.html" />
|
||||
</head>
|
||||
<body>
|
||||
<div class="related">
|
||||
<h3>Navigation</h3>
|
||||
<ul>
|
||||
<li class="right" style="margin-right: 10px">
|
||||
<a href="../../../genindex.html" title="General Index"
|
||||
accesskey="I">index</a></li>
|
||||
<li class="right" >
|
||||
<a href="../../../py-modindex.html" title="Python Module Index"
|
||||
>modules</a> |</li>
|
||||
<li><a href="../../../index.html">Lorax 19.7.11 documentation</a> »</li>
|
||||
<li><a href="../../index.html" >Module code</a> »</li>
|
||||
<li><a href="../cli.html" accesskey="U">composer.cli</a> »</li>
|
||||
</ul>
|
||||
</div>
|
||||
|
||||
<div class="document">
|
||||
<div class="documentwrapper">
|
||||
<div class="bodywrapper">
|
||||
<div class="body">
|
||||
|
||||
<h1>Source code for composer.cli.projects</h1><div class="highlight"><pre>
|
||||
<span class="c">#</span>
|
||||
<span class="c"># Copyright (C) 2018 Red Hat, Inc.</span>
|
||||
<span class="c">#</span>
|
||||
<span class="c"># This program is free software; you can redistribute it and/or modify</span>
|
||||
<span class="c"># it under the terms of the GNU General Public License as published by</span>
|
||||
<span class="c"># the Free Software Foundation; either version 2 of the License, or</span>
|
||||
<span class="c"># (at your option) any later version.</span>
|
||||
<span class="c">#</span>
|
||||
<span class="c"># This program is distributed in the hope that it will be useful,</span>
|
||||
<span class="c"># but WITHOUT ANY WARRANTY; without even the implied warranty of</span>
|
||||
<span class="c"># MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the</span>
|
||||
<span class="c"># GNU General Public License for more details.</span>
|
||||
<span class="c">#</span>
|
||||
<span class="c"># You should have received a copy of the GNU General Public License</span>
|
||||
<span class="c"># along with this program. If not, see <http://www.gnu.org/licenses/>.</span>
|
||||
<span class="c">#</span>
|
||||
<span class="kn">import</span> <span class="nn">logging</span>
|
||||
<span class="n">log</span> <span class="o">=</span> <span class="n">logging</span><span class="o">.</span><span class="n">getLogger</span><span class="p">(</span><span class="s">"composer-cli"</span><span class="p">)</span>
|
||||
|
||||
<span class="kn">import</span> <span class="nn">json</span>
|
||||
<span class="kn">import</span> <span class="nn">textwrap</span>
|
||||
|
||||
<span class="kn">from</span> <span class="nn">composer</span> <span class="kn">import</span> <span class="n">http_client</span> <span class="k">as</span> <span class="n">client</span>
|
||||
|
||||
<div class="viewcode-block" id="projects_cmd"><a class="viewcode-back" href="../../../composer.cli.html#composer.cli.projects.projects_cmd">[docs]</a><span class="k">def</span> <span class="nf">projects_cmd</span><span class="p">(</span><span class="n">opts</span><span class="p">):</span>
|
||||
<span class="sd">"""Process projects commands</span>
|
||||
|
||||
<span class="sd"> :param opts: Cmdline arguments</span>
|
||||
<span class="sd"> :type opts: argparse.Namespace</span>
|
||||
<span class="sd"> :returns: Value to return from sys.exit()</span>
|
||||
<span class="sd"> :rtype: int</span>
|
||||
<span class="sd"> """</span>
|
||||
<span class="n">cmd_map</span> <span class="o">=</span> <span class="p">{</span>
|
||||
<span class="s">"list"</span><span class="p">:</span> <span class="n">projects_list</span><span class="p">,</span>
|
||||
<span class="s">"info"</span><span class="p">:</span> <span class="n">projects_info</span><span class="p">,</span>
|
||||
<span class="p">}</span>
|
||||
<span class="k">if</span> <span class="n">opts</span><span class="o">.</span><span class="n">args</span><span class="p">[</span><span class="mi">1</span><span class="p">]</span> <span class="ow">not</span> <span class="ow">in</span> <span class="n">cmd_map</span><span class="p">:</span>
|
||||
<span class="n">log</span><span class="o">.</span><span class="n">error</span><span class="p">(</span><span class="s">"Unknown projects command: </span><span class="si">%s</span><span class="s">"</span><span class="p">,</span> <span class="n">opts</span><span class="o">.</span><span class="n">args</span><span class="p">[</span><span class="mi">1</span><span class="p">])</span>
|
||||
<span class="k">return</span> <span class="mi">1</span>
|
||||
|
||||
<span class="k">return</span> <span class="n">cmd_map</span><span class="p">[</span><span class="n">opts</span><span class="o">.</span><span class="n">args</span><span class="p">[</span><span class="mi">1</span><span class="p">]](</span><span class="n">opts</span><span class="o">.</span><span class="n">socket</span><span class="p">,</span> <span class="n">opts</span><span class="o">.</span><span class="n">api_version</span><span class="p">,</span> <span class="n">opts</span><span class="o">.</span><span class="n">args</span><span class="p">[</span><span class="mi">2</span><span class="p">:],</span> <span class="n">opts</span><span class="o">.</span><span class="n">json</span><span class="p">)</span>
|
||||
</div>
|
||||
<div class="viewcode-block" id="projects_list"><a class="viewcode-back" href="../../../composer.cli.html#composer.cli.projects.projects_list">[docs]</a><span class="k">def</span> <span class="nf">projects_list</span><span class="p">(</span><span class="n">socket_path</span><span class="p">,</span> <span class="n">api_version</span><span class="p">,</span> <span class="n">args</span><span class="p">,</span> <span class="n">show_json</span><span class="o">=</span><span class="bp">False</span><span class="p">):</span>
|
||||
<span class="sd">"""Output the list of available projects</span>
|
||||
|
||||
<span class="sd"> :param socket_path: Path to the Unix socket to use for API communication</span>
|
||||
<span class="sd"> :type socket_path: str</span>
|
||||
<span class="sd"> :param api_version: Version of the API to talk to. eg. "0"</span>
|
||||
<span class="sd"> :type api_version: str</span>
|
||||
<span class="sd"> :param args: List of remaining arguments from the cmdline</span>
|
||||
<span class="sd"> :type args: list of str</span>
|
||||
<span class="sd"> :param show_json: Set to True to show the JSON output instead of the human readable output</span>
|
||||
<span class="sd"> :type show_json: bool</span>
|
||||
|
||||
<span class="sd"> projects list</span>
|
||||
<span class="sd"> """</span>
|
||||
<span class="n">api_route</span> <span class="o">=</span> <span class="n">client</span><span class="o">.</span><span class="n">api_url</span><span class="p">(</span><span class="n">api_version</span><span class="p">,</span> <span class="s">"/projects/list"</span><span class="p">)</span>
|
||||
<span class="n">result</span> <span class="o">=</span> <span class="n">client</span><span class="o">.</span><span class="n">get_url_json</span><span class="p">(</span><span class="n">socket_path</span><span class="p">,</span> <span class="n">api_route</span><span class="p">)</span>
|
||||
<span class="k">if</span> <span class="n">show_json</span><span class="p">:</span>
|
||||
<span class="k">print</span><span class="p">(</span><span class="n">json</span><span class="o">.</span><span class="n">dumps</span><span class="p">(</span><span class="n">result</span><span class="p">,</span> <span class="n">indent</span><span class="o">=</span><span class="mi">4</span><span class="p">))</span>
|
||||
<span class="k">return</span> <span class="mi">0</span>
|
||||
|
||||
<span class="k">for</span> <span class="n">proj</span> <span class="ow">in</span> <span class="n">result</span><span class="p">[</span><span class="s">"projects"</span><span class="p">]:</span>
|
||||
<span class="k">for</span> <span class="n">k</span> <span class="ow">in</span> <span class="p">[</span><span class="s">"name"</span><span class="p">,</span> <span class="s">"summary"</span><span class="p">,</span> <span class="s">"homepage"</span><span class="p">,</span> <span class="s">"description"</span><span class="p">]:</span>
|
||||
<span class="k">print</span><span class="p">(</span><span class="s">"</span><span class="si">%s</span><span class="s">: </span><span class="si">%s</span><span class="s">"</span> <span class="o">%</span> <span class="p">(</span><span class="n">k</span><span class="o">.</span><span class="n">title</span><span class="p">(),</span> <span class="n">textwrap</span><span class="o">.</span><span class="n">fill</span><span class="p">(</span><span class="n">proj</span><span class="p">[</span><span class="n">k</span><span class="p">],</span> <span class="n">subsequent_indent</span><span class="o">=</span><span class="s">" "</span> <span class="o">*</span> <span class="p">(</span><span class="nb">len</span><span class="p">(</span><span class="n">k</span><span class="p">)</span><span class="o">+</span><span class="mi">2</span><span class="p">))))</span>
|
||||
<span class="k">print</span><span class="p">(</span><span class="s">"</span><span class="se">\n\n</span><span class="s">"</span><span class="p">)</span>
|
||||
|
||||
<span class="k">return</span> <span class="mi">0</span>
|
||||
</div>
|
||||
<div class="viewcode-block" id="projects_info"><a class="viewcode-back" href="../../../composer.cli.html#composer.cli.projects.projects_info">[docs]</a><span class="k">def</span> <span class="nf">projects_info</span><span class="p">(</span><span class="n">socket_path</span><span class="p">,</span> <span class="n">api_version</span><span class="p">,</span> <span class="n">args</span><span class="p">,</span> <span class="n">show_json</span><span class="o">=</span><span class="bp">False</span><span class="p">):</span>
|
||||
<span class="sd">"""Output info on a list of projects</span>
|
||||
|
||||
<span class="sd"> :param socket_path: Path to the Unix socket to use for API communication</span>
|
||||
<span class="sd"> :type socket_path: str</span>
|
||||
<span class="sd"> :param api_version: Version of the API to talk to. eg. "0"</span>
|
||||
<span class="sd"> :type api_version: str</span>
|
||||
<span class="sd"> :param args: List of remaining arguments from the cmdline</span>
|
||||
<span class="sd"> :type args: list of str</span>
|
||||
<span class="sd"> :param show_json: Set to True to show the JSON output instead of the human readable output</span>
|
||||
<span class="sd"> :type show_json: bool</span>
|
||||
|
||||
<span class="sd"> projects info <project,...></span>
|
||||
<span class="sd"> """</span>
|
||||
<span class="k">if</span> <span class="nb">len</span><span class="p">(</span><span class="n">args</span><span class="p">)</span> <span class="o">==</span> <span class="mi">0</span><span class="p">:</span>
|
||||
<span class="n">log</span><span class="o">.</span><span class="n">error</span><span class="p">(</span><span class="s">"projects info is missing the packages"</span><span class="p">)</span>
|
||||
<span class="k">return</span> <span class="mi">1</span>
|
||||
|
||||
<span class="n">api_route</span> <span class="o">=</span> <span class="n">client</span><span class="o">.</span><span class="n">api_url</span><span class="p">(</span><span class="n">api_version</span><span class="p">,</span> <span class="s">"/projects/info/</span><span class="si">%s</span><span class="s">"</span> <span class="o">%</span> <span class="s">","</span><span class="o">.</span><span class="n">join</span><span class="p">(</span><span class="n">args</span><span class="p">))</span>
|
||||
<span class="n">result</span> <span class="o">=</span> <span class="n">client</span><span class="o">.</span><span class="n">get_url_json</span><span class="p">(</span><span class="n">socket_path</span><span class="p">,</span> <span class="n">api_route</span><span class="p">)</span>
|
||||
<span class="k">if</span> <span class="n">show_json</span><span class="p">:</span>
|
||||
<span class="k">print</span><span class="p">(</span><span class="n">json</span><span class="o">.</span><span class="n">dumps</span><span class="p">(</span><span class="n">result</span><span class="p">,</span> <span class="n">indent</span><span class="o">=</span><span class="mi">4</span><span class="p">))</span>
|
||||
<span class="k">return</span> <span class="mi">0</span>
|
||||
|
||||
<span class="k">for</span> <span class="n">proj</span> <span class="ow">in</span> <span class="n">result</span><span class="p">[</span><span class="s">"projects"</span><span class="p">]:</span>
|
||||
<span class="k">for</span> <span class="n">k</span> <span class="ow">in</span> <span class="p">[</span><span class="s">"name"</span><span class="p">,</span> <span class="s">"summary"</span><span class="p">,</span> <span class="s">"homepage"</span><span class="p">,</span> <span class="s">"description"</span><span class="p">]:</span>
|
||||
<span class="k">print</span><span class="p">(</span><span class="s">"</span><span class="si">%s</span><span class="s">: </span><span class="si">%s</span><span class="s">"</span> <span class="o">%</span> <span class="p">(</span><span class="n">k</span><span class="o">.</span><span class="n">title</span><span class="p">(),</span> <span class="n">textwrap</span><span class="o">.</span><span class="n">fill</span><span class="p">(</span><span class="n">proj</span><span class="p">[</span><span class="n">k</span><span class="p">],</span> <span class="n">subsequent_indent</span><span class="o">=</span><span class="s">" "</span> <span class="o">*</span> <span class="p">(</span><span class="nb">len</span><span class="p">(</span><span class="n">k</span><span class="p">)</span><span class="o">+</span><span class="mi">2</span><span class="p">))))</span>
|
||||
<span class="k">print</span><span class="p">(</span><span class="s">"Builds: "</span><span class="p">)</span>
|
||||
<span class="k">for</span> <span class="n">build</span> <span class="ow">in</span> <span class="n">proj</span><span class="p">[</span><span class="s">"builds"</span><span class="p">]:</span>
|
||||
<span class="k">print</span><span class="p">(</span><span class="s">" </span><span class="si">%s%s</span><span class="s">-</span><span class="si">%s</span><span class="s">.</span><span class="si">%s</span><span class="s"> at </span><span class="si">%s</span><span class="s"> for </span><span class="si">%s</span><span class="s">"</span> <span class="o">%</span> <span class="p">(</span><span class="s">""</span> <span class="k">if</span> <span class="ow">not</span> <span class="n">build</span><span class="p">[</span><span class="s">"epoch"</span><span class="p">]</span> <span class="k">else</span> <span class="n">build</span><span class="p">[</span><span class="s">"epoch"</span><span class="p">]</span> <span class="o">+</span> <span class="s">":"</span><span class="p">,</span>
|
||||
<span class="n">build</span><span class="p">[</span><span class="s">"source"</span><span class="p">][</span><span class="s">"version"</span><span class="p">],</span>
|
||||
<span class="n">build</span><span class="p">[</span><span class="s">"release"</span><span class="p">],</span>
|
||||
<span class="n">build</span><span class="p">[</span><span class="s">"arch"</span><span class="p">],</span>
|
||||
<span class="n">build</span><span class="p">[</span><span class="s">"build_time"</span><span class="p">],</span>
|
||||
<span class="n">build</span><span class="p">[</span><span class="s">"changelog"</span><span class="p">]))</span>
|
||||
<span class="k">print</span><span class="p">(</span><span class="s">""</span><span class="p">)</span>
|
||||
<span class="k">return</span> <span class="mi">0</span></div>
|
||||
</pre></div>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="sphinxsidebar">
|
||||
<div class="sphinxsidebarwrapper">
|
||||
<div id="searchbox" style="display: none">
|
||||
<h3>Quick search</h3>
|
||||
<form class="search" action="../../../search.html" method="get">
|
||||
<input type="text" name="q" />
|
||||
<input type="submit" value="Go" />
|
||||
<input type="hidden" name="check_keywords" value="yes" />
|
||||
<input type="hidden" name="area" value="default" />
|
||||
</form>
|
||||
<p class="searchtip" style="font-size: 90%">
|
||||
Enter search terms or a module, class or function name.
|
||||
</p>
|
||||
</div>
|
||||
<script type="text/javascript">$('#searchbox').show(0);</script>
|
||||
</div>
|
||||
</div>
|
||||
<div class="clearer"></div>
|
||||
</div>
|
||||
<div class="related">
|
||||
<h3>Navigation</h3>
|
||||
<ul>
|
||||
<li class="right" style="margin-right: 10px">
|
||||
<a href="../../../genindex.html" title="General Index"
|
||||
>index</a></li>
|
||||
<li class="right" >
|
||||
<a href="../../../py-modindex.html" title="Python Module Index"
|
||||
>modules</a> |</li>
|
||||
<li><a href="../../../index.html">Lorax 19.7.11 documentation</a> »</li>
|
||||
<li><a href="../../index.html" >Module code</a> »</li>
|
||||
<li><a href="../cli.html" >composer.cli</a> »</li>
|
||||
</ul>
|
||||
</div>
|
||||
<div class="footer">
|
||||
© Copyright 2018, Red Hat, Inc..
|
||||
Created using <a href="http://sphinx.pocoo.org/">Sphinx</a> 1.1.3.
|
||||
</div>
|
||||
</body>
|
||||
</html>
|
613
lorax-composer/_modules/composer/cli/recipes.html
Normal file
613
lorax-composer/_modules/composer/cli/recipes.html
Normal file
@ -0,0 +1,613 @@
|
||||
|
||||
|
||||
<!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>composer.cli.recipes — Lorax 19.7.11 documentation</title>
|
||||
|
||||
<link rel="stylesheet" href="../../../_static/default.css" type="text/css" />
|
||||
<link rel="stylesheet" href="../../../_static/pygments.css" type="text/css" />
|
||||
|
||||
<script type="text/javascript">
|
||||
var DOCUMENTATION_OPTIONS = {
|
||||
URL_ROOT: '../../../',
|
||||
VERSION: '19.7.11',
|
||||
COLLAPSE_INDEX: false,
|
||||
FILE_SUFFIX: '.html',
|
||||
HAS_SOURCE: true
|
||||
};
|
||||
</script>
|
||||
<script type="text/javascript" src="../../../_static/jquery.js"></script>
|
||||
<script type="text/javascript" src="../../../_static/underscore.js"></script>
|
||||
<script type="text/javascript" src="../../../_static/doctools.js"></script>
|
||||
<link rel="top" title="Lorax 19.7.11 documentation" href="../../../index.html" />
|
||||
<link rel="up" title="composer.cli" href="../cli.html" />
|
||||
</head>
|
||||
<body>
|
||||
<div class="related">
|
||||
<h3>Navigation</h3>
|
||||
<ul>
|
||||
<li class="right" style="margin-right: 10px">
|
||||
<a href="../../../genindex.html" title="General Index"
|
||||
accesskey="I">index</a></li>
|
||||
<li class="right" >
|
||||
<a href="../../../py-modindex.html" title="Python Module Index"
|
||||
>modules</a> |</li>
|
||||
<li><a href="../../../index.html">Lorax 19.7.11 documentation</a> »</li>
|
||||
<li><a href="../../index.html" >Module code</a> »</li>
|
||||
<li><a href="../cli.html" accesskey="U">composer.cli</a> »</li>
|
||||
</ul>
|
||||
</div>
|
||||
|
||||
<div class="document">
|
||||
<div class="documentwrapper">
|
||||
<div class="bodywrapper">
|
||||
<div class="body">
|
||||
|
||||
<h1>Source code for composer.cli.recipes</h1><div class="highlight"><pre>
|
||||
<span class="c">#</span>
|
||||
<span class="c"># Copyright (C) 2018 Red Hat, Inc.</span>
|
||||
<span class="c">#</span>
|
||||
<span class="c"># This program is free software; you can redistribute it and/or modify</span>
|
||||
<span class="c"># it under the terms of the GNU General Public License as published by</span>
|
||||
<span class="c"># the Free Software Foundation; either version 2 of the License, or</span>
|
||||
<span class="c"># (at your option) any later version.</span>
|
||||
<span class="c">#</span>
|
||||
<span class="c"># This program is distributed in the hope that it will be useful,</span>
|
||||
<span class="c"># but WITHOUT ANY WARRANTY; without even the implied warranty of</span>
|
||||
<span class="c"># MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the</span>
|
||||
<span class="c"># GNU General Public License for more details.</span>
|
||||
<span class="c">#</span>
|
||||
<span class="c"># You should have received a copy of the GNU General Public License</span>
|
||||
<span class="c"># along with this program. If not, see <http://www.gnu.org/licenses/>.</span>
|
||||
<span class="c">#</span>
|
||||
<span class="kn">import</span> <span class="nn">logging</span>
|
||||
<span class="n">log</span> <span class="o">=</span> <span class="n">logging</span><span class="o">.</span><span class="n">getLogger</span><span class="p">(</span><span class="s">"composer-cli"</span><span class="p">)</span>
|
||||
|
||||
<span class="kn">import</span> <span class="nn">os</span>
|
||||
<span class="kn">import</span> <span class="nn">json</span>
|
||||
|
||||
<span class="kn">from</span> <span class="nn">composer</span> <span class="kn">import</span> <span class="n">http_client</span> <span class="k">as</span> <span class="n">client</span>
|
||||
<span class="kn">from</span> <span class="nn">composer.cli.utilities</span> <span class="kn">import</span> <span class="n">argify</span><span class="p">,</span> <span class="n">frozen_toml_filename</span><span class="p">,</span> <span class="n">toml_filename</span><span class="p">,</span> <span class="n">handle_api_result</span>
|
||||
<span class="kn">from</span> <span class="nn">composer.cli.utilities</span> <span class="kn">import</span> <span class="n">packageNEVRA</span>
|
||||
|
||||
<div class="viewcode-block" id="recipes_cmd"><a class="viewcode-back" href="../../../composer.cli.html#composer.cli.recipes.recipes_cmd">[docs]</a><span class="k">def</span> <span class="nf">recipes_cmd</span><span class="p">(</span><span class="n">opts</span><span class="p">):</span>
|
||||
<span class="sd">"""Process recipes commands</span>
|
||||
|
||||
<span class="sd"> :param opts: Cmdline arguments</span>
|
||||
<span class="sd"> :type opts: argparse.Namespace</span>
|
||||
<span class="sd"> :returns: Value to return from sys.exit()</span>
|
||||
<span class="sd"> :rtype: int</span>
|
||||
|
||||
<span class="sd"> This dispatches the recipes commands to a function</span>
|
||||
<span class="sd"> """</span>
|
||||
<span class="n">cmd_map</span> <span class="o">=</span> <span class="p">{</span>
|
||||
<span class="s">"list"</span><span class="p">:</span> <span class="n">recipes_list</span><span class="p">,</span>
|
||||
<span class="s">"show"</span><span class="p">:</span> <span class="n">recipes_show</span><span class="p">,</span>
|
||||
<span class="s">"changes"</span><span class="p">:</span> <span class="n">recipes_changes</span><span class="p">,</span>
|
||||
<span class="s">"diff"</span><span class="p">:</span> <span class="n">recipes_diff</span><span class="p">,</span>
|
||||
<span class="s">"save"</span><span class="p">:</span> <span class="n">recipes_save</span><span class="p">,</span>
|
||||
<span class="s">"delete"</span><span class="p">:</span> <span class="n">recipes_delete</span><span class="p">,</span>
|
||||
<span class="s">"depsolve"</span><span class="p">:</span> <span class="n">recipes_depsolve</span><span class="p">,</span>
|
||||
<span class="s">"push"</span><span class="p">:</span> <span class="n">recipes_push</span><span class="p">,</span>
|
||||
<span class="s">"freeze"</span><span class="p">:</span> <span class="n">recipes_freeze</span><span class="p">,</span>
|
||||
<span class="s">"tag"</span><span class="p">:</span> <span class="n">recipes_tag</span><span class="p">,</span>
|
||||
<span class="s">"undo"</span><span class="p">:</span> <span class="n">recipes_undo</span><span class="p">,</span>
|
||||
<span class="s">"workspace"</span><span class="p">:</span> <span class="n">recipes_workspace</span>
|
||||
<span class="p">}</span>
|
||||
<span class="k">if</span> <span class="n">opts</span><span class="o">.</span><span class="n">args</span><span class="p">[</span><span class="mi">1</span><span class="p">]</span> <span class="ow">not</span> <span class="ow">in</span> <span class="n">cmd_map</span><span class="p">:</span>
|
||||
<span class="n">log</span><span class="o">.</span><span class="n">error</span><span class="p">(</span><span class="s">"Unknown recipes command: </span><span class="si">%s</span><span class="s">"</span><span class="p">,</span> <span class="n">opts</span><span class="o">.</span><span class="n">args</span><span class="p">[</span><span class="mi">1</span><span class="p">])</span>
|
||||
<span class="k">return</span> <span class="mi">1</span>
|
||||
|
||||
<span class="k">return</span> <span class="n">cmd_map</span><span class="p">[</span><span class="n">opts</span><span class="o">.</span><span class="n">args</span><span class="p">[</span><span class="mi">1</span><span class="p">]](</span><span class="n">opts</span><span class="o">.</span><span class="n">socket</span><span class="p">,</span> <span class="n">opts</span><span class="o">.</span><span class="n">api_version</span><span class="p">,</span> <span class="n">opts</span><span class="o">.</span><span class="n">args</span><span class="p">[</span><span class="mi">2</span><span class="p">:],</span> <span class="n">opts</span><span class="o">.</span><span class="n">json</span><span class="p">)</span>
|
||||
</div>
|
||||
<div class="viewcode-block" id="recipes_list"><a class="viewcode-back" href="../../../composer.cli.html#composer.cli.recipes.recipes_list">[docs]</a><span class="k">def</span> <span class="nf">recipes_list</span><span class="p">(</span><span class="n">socket_path</span><span class="p">,</span> <span class="n">api_version</span><span class="p">,</span> <span class="n">args</span><span class="p">,</span> <span class="n">show_json</span><span class="o">=</span><span class="bp">False</span><span class="p">):</span>
|
||||
<span class="sd">"""Output the list of available recipes</span>
|
||||
|
||||
<span class="sd"> :param socket_path: Path to the Unix socket to use for API communication</span>
|
||||
<span class="sd"> :type socket_path: str</span>
|
||||
<span class="sd"> :param api_version: Version of the API to talk to. eg. "0"</span>
|
||||
<span class="sd"> :type api_version: str</span>
|
||||
<span class="sd"> :param args: List of remaining arguments from the cmdline</span>
|
||||
<span class="sd"> :type args: list of str</span>
|
||||
<span class="sd"> :param show_json: Set to True to show the JSON output instead of the human readable output</span>
|
||||
<span class="sd"> :type show_json: bool</span>
|
||||
|
||||
<span class="sd"> recipes list</span>
|
||||
<span class="sd"> """</span>
|
||||
<span class="n">api_route</span> <span class="o">=</span> <span class="n">client</span><span class="o">.</span><span class="n">api_url</span><span class="p">(</span><span class="n">api_version</span><span class="p">,</span> <span class="s">"/recipes/list"</span><span class="p">)</span>
|
||||
<span class="n">result</span> <span class="o">=</span> <span class="n">client</span><span class="o">.</span><span class="n">get_url_json</span><span class="p">(</span><span class="n">socket_path</span><span class="p">,</span> <span class="n">api_route</span><span class="p">)</span>
|
||||
<span class="k">if</span> <span class="n">show_json</span><span class="p">:</span>
|
||||
<span class="k">print</span><span class="p">(</span><span class="n">json</span><span class="o">.</span><span class="n">dumps</span><span class="p">(</span><span class="n">result</span><span class="p">,</span> <span class="n">indent</span><span class="o">=</span><span class="mi">4</span><span class="p">))</span>
|
||||
<span class="k">return</span> <span class="mi">0</span>
|
||||
|
||||
<span class="k">print</span><span class="p">(</span><span class="s">"Recipes: "</span> <span class="o">+</span> <span class="s">", "</span><span class="o">.</span><span class="n">join</span><span class="p">([</span><span class="n">r</span> <span class="k">for</span> <span class="n">r</span> <span class="ow">in</span> <span class="n">result</span><span class="p">[</span><span class="s">"recipes"</span><span class="p">]]))</span>
|
||||
|
||||
<span class="k">return</span> <span class="mi">0</span>
|
||||
</div>
|
||||
<div class="viewcode-block" id="recipes_show"><a class="viewcode-back" href="../../../composer.cli.html#composer.cli.recipes.recipes_show">[docs]</a><span class="k">def</span> <span class="nf">recipes_show</span><span class="p">(</span><span class="n">socket_path</span><span class="p">,</span> <span class="n">api_version</span><span class="p">,</span> <span class="n">args</span><span class="p">,</span> <span class="n">show_json</span><span class="o">=</span><span class="bp">False</span><span class="p">):</span>
|
||||
<span class="sd">"""Show the recipes, in TOML format</span>
|
||||
|
||||
<span class="sd"> :param socket_path: Path to the Unix socket to use for API communication</span>
|
||||
<span class="sd"> :type socket_path: str</span>
|
||||
<span class="sd"> :param api_version: Version of the API to talk to. eg. "0"</span>
|
||||
<span class="sd"> :type api_version: str</span>
|
||||
<span class="sd"> :param args: List of remaining arguments from the cmdline</span>
|
||||
<span class="sd"> :type args: list of str</span>
|
||||
<span class="sd"> :param show_json: Set to True to show the JSON output instead of the human readable output</span>
|
||||
<span class="sd"> :type show_json: bool</span>
|
||||
|
||||
<span class="sd"> recipes show <recipe,...> Display the recipe in TOML format.</span>
|
||||
|
||||
<span class="sd"> Multiple recipes will be separated by \n\n</span>
|
||||
<span class="sd"> """</span>
|
||||
<span class="k">for</span> <span class="n">recipe</span> <span class="ow">in</span> <span class="n">argify</span><span class="p">(</span><span class="n">args</span><span class="p">):</span>
|
||||
<span class="n">api_route</span> <span class="o">=</span> <span class="n">client</span><span class="o">.</span><span class="n">api_url</span><span class="p">(</span><span class="n">api_version</span><span class="p">,</span> <span class="s">"/recipes/info/</span><span class="si">%s</span><span class="s">?format=toml"</span> <span class="o">%</span> <span class="n">recipe</span><span class="p">)</span>
|
||||
<span class="k">print</span><span class="p">(</span><span class="n">client</span><span class="o">.</span><span class="n">get_url_raw</span><span class="p">(</span><span class="n">socket_path</span><span class="p">,</span> <span class="n">api_route</span><span class="p">)</span> <span class="o">+</span> <span class="s">"</span><span class="se">\n\n</span><span class="s">"</span><span class="p">)</span>
|
||||
|
||||
<span class="k">return</span> <span class="mi">0</span>
|
||||
</div>
|
||||
<div class="viewcode-block" id="recipes_changes"><a class="viewcode-back" href="../../../composer.cli.html#composer.cli.recipes.recipes_changes">[docs]</a><span class="k">def</span> <span class="nf">recipes_changes</span><span class="p">(</span><span class="n">socket_path</span><span class="p">,</span> <span class="n">api_version</span><span class="p">,</span> <span class="n">args</span><span class="p">,</span> <span class="n">show_json</span><span class="o">=</span><span class="bp">False</span><span class="p">):</span>
|
||||
<span class="sd">"""Display the changes for each of the recipes</span>
|
||||
|
||||
<span class="sd"> :param socket_path: Path to the Unix socket to use for API communication</span>
|
||||
<span class="sd"> :type socket_path: str</span>
|
||||
<span class="sd"> :param api_version: Version of the API to talk to. eg. "0"</span>
|
||||
<span class="sd"> :type api_version: str</span>
|
||||
<span class="sd"> :param args: List of remaining arguments from the cmdline</span>
|
||||
<span class="sd"> :type args: list of str</span>
|
||||
<span class="sd"> :param show_json: Set to True to show the JSON output instead of the human readable output</span>
|
||||
<span class="sd"> :type show_json: bool</span>
|
||||
|
||||
<span class="sd"> recipes changes <recipe,...> Display the changes for each recipe.</span>
|
||||
<span class="sd"> """</span>
|
||||
<span class="n">api_route</span> <span class="o">=</span> <span class="n">client</span><span class="o">.</span><span class="n">api_url</span><span class="p">(</span><span class="n">api_version</span><span class="p">,</span> <span class="s">"/recipes/changes/</span><span class="si">%s</span><span class="s">"</span> <span class="o">%</span> <span class="p">(</span><span class="s">","</span><span class="o">.</span><span class="n">join</span><span class="p">(</span><span class="n">argify</span><span class="p">(</span><span class="n">args</span><span class="p">))))</span>
|
||||
<span class="n">result</span> <span class="o">=</span> <span class="n">client</span><span class="o">.</span><span class="n">get_url_json</span><span class="p">(</span><span class="n">socket_path</span><span class="p">,</span> <span class="n">api_route</span><span class="p">)</span>
|
||||
<span class="k">if</span> <span class="n">show_json</span><span class="p">:</span>
|
||||
<span class="k">print</span><span class="p">(</span><span class="n">json</span><span class="o">.</span><span class="n">dumps</span><span class="p">(</span><span class="n">result</span><span class="p">,</span> <span class="n">indent</span><span class="o">=</span><span class="mi">4</span><span class="p">))</span>
|
||||
<span class="k">return</span> <span class="mi">0</span>
|
||||
|
||||
<span class="k">for</span> <span class="n">recipe</span> <span class="ow">in</span> <span class="n">result</span><span class="p">[</span><span class="s">"recipes"</span><span class="p">]:</span>
|
||||
<span class="k">print</span><span class="p">(</span><span class="n">recipe</span><span class="p">[</span><span class="s">"name"</span><span class="p">])</span>
|
||||
<span class="k">for</span> <span class="n">change</span> <span class="ow">in</span> <span class="n">recipe</span><span class="p">[</span><span class="s">"changes"</span><span class="p">]:</span>
|
||||
<span class="n">prettyCommitDetails</span><span class="p">(</span><span class="n">change</span><span class="p">)</span>
|
||||
|
||||
<span class="k">return</span> <span class="mi">0</span>
|
||||
</div>
|
||||
<div class="viewcode-block" id="prettyCommitDetails"><a class="viewcode-back" href="../../../composer.cli.html#composer.cli.recipes.prettyCommitDetails">[docs]</a><span class="k">def</span> <span class="nf">prettyCommitDetails</span><span class="p">(</span><span class="n">change</span><span class="p">,</span> <span class="n">indent</span><span class="o">=</span><span class="mi">4</span><span class="p">):</span>
|
||||
<span class="sd">"""Print the recipe's change in a nice way</span>
|
||||
|
||||
<span class="sd"> :param change: The individual recipe change dict</span>
|
||||
<span class="sd"> :type change: dict</span>
|
||||
<span class="sd"> :param indent: Number of spaces to indent</span>
|
||||
<span class="sd"> :type indent: int</span>
|
||||
<span class="sd"> """</span>
|
||||
<span class="k">def</span> <span class="nf">revision</span><span class="p">():</span>
|
||||
<span class="k">if</span> <span class="n">change</span><span class="p">[</span><span class="s">"revision"</span><span class="p">]:</span>
|
||||
<span class="k">return</span> <span class="s">" revision </span><span class="si">%d</span><span class="s">"</span> <span class="o">%</span> <span class="n">change</span><span class="p">[</span><span class="s">"revision"</span><span class="p">]</span>
|
||||
<span class="k">else</span><span class="p">:</span>
|
||||
<span class="k">return</span> <span class="s">""</span>
|
||||
|
||||
<span class="k">print</span> <span class="s">" "</span> <span class="o">*</span> <span class="n">indent</span> <span class="o">+</span> <span class="n">change</span><span class="p">[</span><span class="s">"timestamp"</span><span class="p">]</span> <span class="o">+</span> <span class="s">" "</span> <span class="o">+</span> <span class="n">change</span><span class="p">[</span><span class="s">"commit"</span><span class="p">]</span> <span class="o">+</span> <span class="n">revision</span><span class="p">()</span>
|
||||
<span class="k">print</span> <span class="s">" "</span> <span class="o">*</span> <span class="n">indent</span> <span class="o">+</span> <span class="n">change</span><span class="p">[</span><span class="s">"message"</span><span class="p">]</span> <span class="o">+</span> <span class="s">"</span><span class="se">\n</span><span class="s">"</span>
|
||||
</div>
|
||||
<div class="viewcode-block" id="recipes_diff"><a class="viewcode-back" href="../../../composer.cli.html#composer.cli.recipes.recipes_diff">[docs]</a><span class="k">def</span> <span class="nf">recipes_diff</span><span class="p">(</span><span class="n">socket_path</span><span class="p">,</span> <span class="n">api_version</span><span class="p">,</span> <span class="n">args</span><span class="p">,</span> <span class="n">show_json</span><span class="o">=</span><span class="bp">False</span><span class="p">):</span>
|
||||
<span class="sd">"""Display the differences between 2 versions of a recipe</span>
|
||||
|
||||
<span class="sd"> :param socket_path: Path to the Unix socket to use for API communication</span>
|
||||
<span class="sd"> :type socket_path: str</span>
|
||||
<span class="sd"> :param api_version: Version of the API to talk to. eg. "0"</span>
|
||||
<span class="sd"> :type api_version: str</span>
|
||||
<span class="sd"> :param args: List of remaining arguments from the cmdline</span>
|
||||
<span class="sd"> :type args: list of str</span>
|
||||
<span class="sd"> :param show_json: Set to True to show the JSON output instead of the human readable output</span>
|
||||
<span class="sd"> :type show_json: bool</span>
|
||||
|
||||
<span class="sd"> recipes diff <recipe-name> Display the differences between 2 versions of a recipe.</span>
|
||||
<span class="sd"> <from-commit> Commit hash or NEWEST</span>
|
||||
<span class="sd"> <to-commit> Commit hash, NEWEST, or WORKSPACE</span>
|
||||
<span class="sd"> """</span>
|
||||
<span class="k">if</span> <span class="nb">len</span><span class="p">(</span><span class="n">args</span><span class="p">)</span> <span class="o">==</span> <span class="mi">0</span><span class="p">:</span>
|
||||
<span class="n">log</span><span class="o">.</span><span class="n">error</span><span class="p">(</span><span class="s">"recipes diff is missing the recipe name, from commit, and to commit"</span><span class="p">)</span>
|
||||
<span class="k">return</span> <span class="mi">1</span>
|
||||
<span class="k">elif</span> <span class="nb">len</span><span class="p">(</span><span class="n">args</span><span class="p">)</span> <span class="o">==</span> <span class="mi">1</span><span class="p">:</span>
|
||||
<span class="n">log</span><span class="o">.</span><span class="n">error</span><span class="p">(</span><span class="s">"recipes diff is missing the from commit, and the to commit"</span><span class="p">)</span>
|
||||
<span class="k">return</span> <span class="mi">1</span>
|
||||
<span class="k">elif</span> <span class="nb">len</span><span class="p">(</span><span class="n">args</span><span class="p">)</span> <span class="o">==</span> <span class="mi">2</span><span class="p">:</span>
|
||||
<span class="n">log</span><span class="o">.</span><span class="n">error</span><span class="p">(</span><span class="s">"recipes diff is missing the to commit"</span><span class="p">)</span>
|
||||
<span class="k">return</span> <span class="mi">1</span>
|
||||
|
||||
<span class="n">api_route</span> <span class="o">=</span> <span class="n">client</span><span class="o">.</span><span class="n">api_url</span><span class="p">(</span><span class="n">api_version</span><span class="p">,</span> <span class="s">"/recipes/diff/</span><span class="si">%s</span><span class="s">/</span><span class="si">%s</span><span class="s">/</span><span class="si">%s</span><span class="s">"</span> <span class="o">%</span> <span class="p">(</span><span class="n">args</span><span class="p">[</span><span class="mi">0</span><span class="p">],</span> <span class="n">args</span><span class="p">[</span><span class="mi">1</span><span class="p">],</span> <span class="n">args</span><span class="p">[</span><span class="mi">2</span><span class="p">]))</span>
|
||||
<span class="n">result</span> <span class="o">=</span> <span class="n">client</span><span class="o">.</span><span class="n">get_url_json</span><span class="p">(</span><span class="n">socket_path</span><span class="p">,</span> <span class="n">api_route</span><span class="p">)</span>
|
||||
|
||||
<span class="k">if</span> <span class="n">show_json</span><span class="p">:</span>
|
||||
<span class="k">print</span><span class="p">(</span><span class="n">json</span><span class="o">.</span><span class="n">dumps</span><span class="p">(</span><span class="n">result</span><span class="p">,</span> <span class="n">indent</span><span class="o">=</span><span class="mi">4</span><span class="p">))</span>
|
||||
<span class="k">return</span> <span class="mi">0</span>
|
||||
|
||||
<span class="k">if</span> <span class="n">result</span><span class="o">.</span><span class="n">get</span><span class="p">(</span><span class="s">"error"</span><span class="p">,</span> <span class="bp">False</span><span class="p">):</span>
|
||||
<span class="n">log</span><span class="o">.</span><span class="n">error</span><span class="p">(</span><span class="n">result</span><span class="p">[</span><span class="s">"error"</span><span class="p">][</span><span class="s">"msg"</span><span class="p">])</span>
|
||||
<span class="k">return</span> <span class="mi">1</span>
|
||||
|
||||
<span class="k">for</span> <span class="n">diff</span> <span class="ow">in</span> <span class="n">result</span><span class="p">[</span><span class="s">"diff"</span><span class="p">]:</span>
|
||||
<span class="k">print</span><span class="p">(</span><span class="n">prettyDiffEntry</span><span class="p">(</span><span class="n">diff</span><span class="p">))</span>
|
||||
|
||||
<span class="k">return</span> <span class="mi">0</span>
|
||||
</div>
|
||||
<div class="viewcode-block" id="prettyDiffEntry"><a class="viewcode-back" href="../../../composer.cli.html#composer.cli.recipes.prettyDiffEntry">[docs]</a><span class="k">def</span> <span class="nf">prettyDiffEntry</span><span class="p">(</span><span class="n">diff</span><span class="p">):</span>
|
||||
<span class="sd">"""Generate nice diff entry string.</span>
|
||||
|
||||
<span class="sd"> :param diff: Difference entry dict</span>
|
||||
<span class="sd"> :type diff: dict</span>
|
||||
<span class="sd"> :returns: Nice string</span>
|
||||
<span class="sd"> """</span>
|
||||
<span class="k">def</span> <span class="nf">change</span><span class="p">(</span><span class="n">diff</span><span class="p">):</span>
|
||||
<span class="k">if</span> <span class="n">diff</span><span class="p">[</span><span class="s">"old"</span><span class="p">]</span> <span class="ow">and</span> <span class="n">diff</span><span class="p">[</span><span class="s">"new"</span><span class="p">]:</span>
|
||||
<span class="k">return</span> <span class="s">"Changed"</span>
|
||||
<span class="k">elif</span> <span class="n">diff</span><span class="p">[</span><span class="s">"new"</span><span class="p">]</span> <span class="ow">and</span> <span class="ow">not</span> <span class="n">diff</span><span class="p">[</span><span class="s">"old"</span><span class="p">]:</span>
|
||||
<span class="k">return</span> <span class="s">"Added"</span>
|
||||
<span class="k">elif</span> <span class="n">diff</span><span class="p">[</span><span class="s">"old"</span><span class="p">]</span> <span class="ow">and</span> <span class="ow">not</span> <span class="n">diff</span><span class="p">[</span><span class="s">"new"</span><span class="p">]:</span>
|
||||
<span class="k">return</span> <span class="s">"Removed"</span>
|
||||
<span class="k">else</span><span class="p">:</span>
|
||||
<span class="k">return</span> <span class="s">"Unknown"</span>
|
||||
|
||||
<span class="k">def</span> <span class="nf">name</span><span class="p">(</span><span class="n">diff</span><span class="p">):</span>
|
||||
<span class="k">if</span> <span class="n">diff</span><span class="p">[</span><span class="s">"old"</span><span class="p">]:</span>
|
||||
<span class="k">return</span> <span class="n">diff</span><span class="p">[</span><span class="s">"old"</span><span class="p">]</span><span class="o">.</span><span class="n">keys</span><span class="p">()[</span><span class="mi">0</span><span class="p">]</span>
|
||||
<span class="k">elif</span> <span class="n">diff</span><span class="p">[</span><span class="s">"new"</span><span class="p">]:</span>
|
||||
<span class="k">return</span> <span class="n">diff</span><span class="p">[</span><span class="s">"new"</span><span class="p">]</span><span class="o">.</span><span class="n">keys</span><span class="p">()[</span><span class="mi">0</span><span class="p">]</span>
|
||||
<span class="k">else</span><span class="p">:</span>
|
||||
<span class="k">return</span> <span class="s">"Unknown"</span>
|
||||
|
||||
<span class="k">def</span> <span class="nf">details</span><span class="p">(</span><span class="n">diff</span><span class="p">):</span>
|
||||
<span class="k">if</span> <span class="n">change</span><span class="p">(</span><span class="n">diff</span><span class="p">)</span> <span class="o">==</span> <span class="s">"Changed"</span><span class="p">:</span>
|
||||
<span class="k">if</span> <span class="n">name</span><span class="p">(</span><span class="n">diff</span><span class="p">)</span> <span class="o">==</span> <span class="s">"Description"</span><span class="p">:</span>
|
||||
<span class="k">return</span> <span class="s">'"</span><span class="si">%s</span><span class="s">" -> "</span><span class="si">%s</span><span class="s">"'</span> <span class="o">%</span> <span class="p">(</span><span class="n">diff</span><span class="p">[</span><span class="s">"old"</span><span class="p">][</span><span class="n">name</span><span class="p">(</span><span class="n">diff</span><span class="p">)],</span> <span class="n">diff</span><span class="p">[</span><span class="s">"old"</span><span class="p">][</span><span class="n">name</span><span class="p">(</span><span class="n">diff</span><span class="p">)])</span>
|
||||
<span class="k">elif</span> <span class="n">name</span><span class="p">(</span><span class="n">diff</span><span class="p">)</span> <span class="o">==</span> <span class="s">"Version"</span><span class="p">:</span>
|
||||
<span class="k">return</span> <span class="s">"</span><span class="si">%s</span><span class="s"> -> </span><span class="si">%s</span><span class="s">"</span> <span class="o">%</span> <span class="p">(</span><span class="n">diff</span><span class="p">[</span><span class="s">"old"</span><span class="p">][</span><span class="n">name</span><span class="p">(</span><span class="n">diff</span><span class="p">)],</span> <span class="n">diff</span><span class="p">[</span><span class="s">"old"</span><span class="p">][</span><span class="n">name</span><span class="p">(</span><span class="n">diff</span><span class="p">)])</span>
|
||||
<span class="k">elif</span> <span class="n">name</span><span class="p">(</span><span class="n">diff</span><span class="p">)</span> <span class="ow">in</span> <span class="p">[</span><span class="s">"Module"</span><span class="p">,</span> <span class="s">"Package"</span><span class="p">]:</span>
|
||||
<span class="k">return</span> <span class="s">"</span><span class="si">%s</span><span class="s"> </span><span class="si">%s</span><span class="s"> -> </span><span class="si">%s</span><span class="s">"</span> <span class="o">%</span> <span class="p">(</span><span class="n">diff</span><span class="p">[</span><span class="s">"old"</span><span class="p">][</span><span class="n">name</span><span class="p">(</span><span class="n">diff</span><span class="p">)][</span><span class="s">"name"</span><span class="p">],</span> <span class="n">diff</span><span class="p">[</span><span class="s">"old"</span><span class="p">][</span><span class="n">name</span><span class="p">(</span><span class="n">diff</span><span class="p">)][</span><span class="s">"version"</span><span class="p">],</span>
|
||||
<span class="n">diff</span><span class="p">[</span><span class="s">"new"</span><span class="p">][</span><span class="n">name</span><span class="p">(</span><span class="n">diff</span><span class="p">)][</span><span class="s">"version"</span><span class="p">])</span>
|
||||
<span class="k">else</span><span class="p">:</span>
|
||||
<span class="k">return</span> <span class="s">"Unknown"</span>
|
||||
<span class="k">elif</span> <span class="n">change</span><span class="p">(</span><span class="n">diff</span><span class="p">)</span> <span class="o">==</span> <span class="s">"Added"</span><span class="p">:</span>
|
||||
<span class="k">if</span> <span class="n">name</span><span class="p">(</span><span class="n">diff</span><span class="p">)</span> <span class="ow">in</span> <span class="p">[</span><span class="s">"Module"</span><span class="p">,</span> <span class="s">"Package"</span><span class="p">]:</span>
|
||||
<span class="k">return</span> <span class="s">"</span><span class="si">%s</span><span class="s"> </span><span class="si">%s</span><span class="s">"</span> <span class="o">%</span> <span class="p">(</span><span class="n">diff</span><span class="p">[</span><span class="s">"new"</span><span class="p">][</span><span class="n">name</span><span class="p">(</span><span class="n">diff</span><span class="p">)][</span><span class="s">"name"</span><span class="p">],</span> <span class="n">diff</span><span class="p">[</span><span class="s">"new"</span><span class="p">][</span><span class="n">name</span><span class="p">(</span><span class="n">diff</span><span class="p">)][</span><span class="s">"version"</span><span class="p">])</span>
|
||||
<span class="k">else</span><span class="p">:</span>
|
||||
<span class="k">return</span> <span class="s">" "</span><span class="o">.</span><span class="n">join</span><span class="p">([</span><span class="n">diff</span><span class="p">[</span><span class="s">"new"</span><span class="p">][</span><span class="n">k</span><span class="p">]</span> <span class="k">for</span> <span class="n">k</span> <span class="ow">in</span> <span class="n">diff</span><span class="p">[</span><span class="s">"new"</span><span class="p">]])</span>
|
||||
<span class="k">elif</span> <span class="n">change</span><span class="p">(</span><span class="n">diff</span><span class="p">)</span> <span class="o">==</span> <span class="s">"Removed"</span><span class="p">:</span>
|
||||
<span class="k">if</span> <span class="n">name</span><span class="p">(</span><span class="n">diff</span><span class="p">)</span> <span class="ow">in</span> <span class="p">[</span><span class="s">"Module"</span><span class="p">,</span> <span class="s">"Package"</span><span class="p">]:</span>
|
||||
<span class="k">return</span> <span class="s">"</span><span class="si">%s</span><span class="s"> </span><span class="si">%s</span><span class="s">"</span> <span class="o">%</span> <span class="p">(</span><span class="n">diff</span><span class="p">[</span><span class="s">"old"</span><span class="p">][</span><span class="n">name</span><span class="p">(</span><span class="n">diff</span><span class="p">)][</span><span class="s">"name"</span><span class="p">],</span> <span class="n">diff</span><span class="p">[</span><span class="s">"old"</span><span class="p">][</span><span class="n">name</span><span class="p">(</span><span class="n">diff</span><span class="p">)][</span><span class="s">"version"</span><span class="p">])</span>
|
||||
<span class="k">else</span><span class="p">:</span>
|
||||
<span class="k">return</span> <span class="s">" "</span><span class="o">.</span><span class="n">join</span><span class="p">([</span><span class="n">diff</span><span class="p">[</span><span class="s">"old"</span><span class="p">][</span><span class="n">k</span><span class="p">]</span> <span class="k">for</span> <span class="n">k</span> <span class="ow">in</span> <span class="n">diff</span><span class="p">[</span><span class="s">"old"</span><span class="p">]])</span>
|
||||
|
||||
<span class="k">return</span> <span class="n">change</span><span class="p">(</span><span class="n">diff</span><span class="p">)</span> <span class="o">+</span> <span class="s">" "</span> <span class="o">+</span> <span class="n">name</span><span class="p">(</span><span class="n">diff</span><span class="p">)</span> <span class="o">+</span> <span class="s">" "</span> <span class="o">+</span> <span class="n">details</span><span class="p">(</span><span class="n">diff</span><span class="p">)</span>
|
||||
</div>
|
||||
<div class="viewcode-block" id="recipes_save"><a class="viewcode-back" href="../../../composer.cli.html#composer.cli.recipes.recipes_save">[docs]</a><span class="k">def</span> <span class="nf">recipes_save</span><span class="p">(</span><span class="n">socket_path</span><span class="p">,</span> <span class="n">api_version</span><span class="p">,</span> <span class="n">args</span><span class="p">,</span> <span class="n">show_json</span><span class="o">=</span><span class="bp">False</span><span class="p">):</span>
|
||||
<span class="sd">"""Save the recipe to a TOML file</span>
|
||||
|
||||
<span class="sd"> :param socket_path: Path to the Unix socket to use for API communication</span>
|
||||
<span class="sd"> :type socket_path: str</span>
|
||||
<span class="sd"> :param api_version: Version of the API to talk to. eg. "0"</span>
|
||||
<span class="sd"> :type api_version: str</span>
|
||||
<span class="sd"> :param args: List of remaining arguments from the cmdline</span>
|
||||
<span class="sd"> :type args: list of str</span>
|
||||
<span class="sd"> :param show_json: Set to True to show the JSON output instead of the human readable output</span>
|
||||
<span class="sd"> :type show_json: bool</span>
|
||||
|
||||
<span class="sd"> recipes save <recipe,...> Save the recipe to a file, <recipe-name>.toml</span>
|
||||
<span class="sd"> """</span>
|
||||
<span class="k">for</span> <span class="n">recipe</span> <span class="ow">in</span> <span class="n">argify</span><span class="p">(</span><span class="n">args</span><span class="p">):</span>
|
||||
<span class="n">api_route</span> <span class="o">=</span> <span class="n">client</span><span class="o">.</span><span class="n">api_url</span><span class="p">(</span><span class="n">api_version</span><span class="p">,</span> <span class="s">"/recipes/info/</span><span class="si">%s</span><span class="s">?format=toml"</span> <span class="o">%</span> <span class="n">recipe</span><span class="p">)</span>
|
||||
<span class="n">recipe_toml</span> <span class="o">=</span> <span class="n">client</span><span class="o">.</span><span class="n">get_url_raw</span><span class="p">(</span><span class="n">socket_path</span><span class="p">,</span> <span class="n">api_route</span><span class="p">)</span>
|
||||
<span class="nb">open</span><span class="p">(</span><span class="n">toml_filename</span><span class="p">(</span><span class="n">recipe</span><span class="p">),</span> <span class="s">"w"</span><span class="p">)</span><span class="o">.</span><span class="n">write</span><span class="p">(</span><span class="n">recipe_toml</span><span class="p">)</span>
|
||||
|
||||
<span class="k">return</span> <span class="mi">0</span>
|
||||
</div>
|
||||
<div class="viewcode-block" id="recipes_delete"><a class="viewcode-back" href="../../../composer.cli.html#composer.cli.recipes.recipes_delete">[docs]</a><span class="k">def</span> <span class="nf">recipes_delete</span><span class="p">(</span><span class="n">socket_path</span><span class="p">,</span> <span class="n">api_version</span><span class="p">,</span> <span class="n">args</span><span class="p">,</span> <span class="n">show_json</span><span class="o">=</span><span class="bp">False</span><span class="p">):</span>
|
||||
<span class="sd">"""Delete a recipe from the server</span>
|
||||
|
||||
<span class="sd"> :param socket_path: Path to the Unix socket to use for API communication</span>
|
||||
<span class="sd"> :type socket_path: str</span>
|
||||
<span class="sd"> :param api_version: Version of the API to talk to. eg. "0"</span>
|
||||
<span class="sd"> :type api_version: str</span>
|
||||
<span class="sd"> :param args: List of remaining arguments from the cmdline</span>
|
||||
<span class="sd"> :type args: list of str</span>
|
||||
<span class="sd"> :param show_json: Set to True to show the JSON output instead of the human readable output</span>
|
||||
<span class="sd"> :type show_json: bool</span>
|
||||
|
||||
<span class="sd"> delete <recipe> Delete a recipe from the server</span>
|
||||
<span class="sd"> """</span>
|
||||
<span class="n">api_route</span> <span class="o">=</span> <span class="n">client</span><span class="o">.</span><span class="n">api_url</span><span class="p">(</span><span class="n">api_version</span><span class="p">,</span> <span class="s">"/recipes/delete/</span><span class="si">%s</span><span class="s">"</span> <span class="o">%</span> <span class="n">args</span><span class="p">[</span><span class="mi">0</span><span class="p">])</span>
|
||||
<span class="n">result</span> <span class="o">=</span> <span class="n">client</span><span class="o">.</span><span class="n">delete_url_json</span><span class="p">(</span><span class="n">socket_path</span><span class="p">,</span> <span class="n">api_route</span><span class="p">)</span>
|
||||
|
||||
<span class="k">return</span> <span class="n">handle_api_result</span><span class="p">(</span><span class="n">result</span><span class="p">,</span> <span class="n">show_json</span><span class="p">)</span>
|
||||
</div>
|
||||
<div class="viewcode-block" id="recipes_depsolve"><a class="viewcode-back" href="../../../composer.cli.html#composer.cli.recipes.recipes_depsolve">[docs]</a><span class="k">def</span> <span class="nf">recipes_depsolve</span><span class="p">(</span><span class="n">socket_path</span><span class="p">,</span> <span class="n">api_version</span><span class="p">,</span> <span class="n">args</span><span class="p">,</span> <span class="n">show_json</span><span class="o">=</span><span class="bp">False</span><span class="p">):</span>
|
||||
<span class="sd">"""Display the packages needed to install the recipe</span>
|
||||
|
||||
<span class="sd"> :param socket_path: Path to the Unix socket to use for API communication</span>
|
||||
<span class="sd"> :type socket_path: str</span>
|
||||
<span class="sd"> :param api_version: Version of the API to talk to. eg. "0"</span>
|
||||
<span class="sd"> :type api_version: str</span>
|
||||
<span class="sd"> :param args: List of remaining arguments from the cmdline</span>
|
||||
<span class="sd"> :type args: list of str</span>
|
||||
<span class="sd"> :param show_json: Set to True to show the JSON output instead of the human readable output</span>
|
||||
<span class="sd"> :type show_json: bool</span>
|
||||
|
||||
<span class="sd"> recipes depsolve <recipe,...> Display the packages needed to install the recipe.</span>
|
||||
<span class="sd"> """</span>
|
||||
<span class="n">api_route</span> <span class="o">=</span> <span class="n">client</span><span class="o">.</span><span class="n">api_url</span><span class="p">(</span><span class="n">api_version</span><span class="p">,</span> <span class="s">"/recipes/depsolve/</span><span class="si">%s</span><span class="s">"</span> <span class="o">%</span> <span class="p">(</span><span class="s">","</span><span class="o">.</span><span class="n">join</span><span class="p">(</span><span class="n">argify</span><span class="p">(</span><span class="n">args</span><span class="p">))))</span>
|
||||
<span class="n">result</span> <span class="o">=</span> <span class="n">client</span><span class="o">.</span><span class="n">get_url_json</span><span class="p">(</span><span class="n">socket_path</span><span class="p">,</span> <span class="n">api_route</span><span class="p">)</span>
|
||||
|
||||
<span class="k">if</span> <span class="n">show_json</span><span class="p">:</span>
|
||||
<span class="k">print</span><span class="p">(</span><span class="n">json</span><span class="o">.</span><span class="n">dumps</span><span class="p">(</span><span class="n">result</span><span class="p">,</span> <span class="n">indent</span><span class="o">=</span><span class="mi">4</span><span class="p">))</span>
|
||||
<span class="k">return</span> <span class="mi">0</span>
|
||||
|
||||
<span class="k">for</span> <span class="n">recipe</span> <span class="ow">in</span> <span class="n">result</span><span class="p">[</span><span class="s">"recipes"</span><span class="p">]:</span>
|
||||
<span class="k">if</span> <span class="n">recipe</span><span class="p">[</span><span class="s">"recipe"</span><span class="p">]</span><span class="o">.</span><span class="n">get</span><span class="p">(</span><span class="s">"version"</span><span class="p">,</span> <span class="s">""</span><span class="p">):</span>
|
||||
<span class="k">print</span><span class="p">(</span><span class="s">"Recipe: </span><span class="si">%s</span><span class="s"> v</span><span class="si">%s</span><span class="s">"</span> <span class="o">%</span> <span class="p">(</span><span class="n">recipe</span><span class="p">[</span><span class="s">"recipe"</span><span class="p">][</span><span class="s">"name"</span><span class="p">],</span> <span class="n">recipe</span><span class="p">[</span><span class="s">"recipe"</span><span class="p">][</span><span class="s">"version"</span><span class="p">]))</span>
|
||||
<span class="k">else</span><span class="p">:</span>
|
||||
<span class="k">print</span><span class="p">(</span><span class="s">"Recipe: </span><span class="si">%s</span><span class="s">"</span> <span class="o">%</span> <span class="p">(</span><span class="n">recipe</span><span class="p">[</span><span class="s">"recipe"</span><span class="p">][</span><span class="s">"name"</span><span class="p">]))</span>
|
||||
<span class="k">for</span> <span class="n">dep</span> <span class="ow">in</span> <span class="n">recipe</span><span class="p">[</span><span class="s">"dependencies"</span><span class="p">]:</span>
|
||||
<span class="k">print</span><span class="p">(</span><span class="s">" "</span> <span class="o">+</span> <span class="n">packageNEVRA</span><span class="p">(</span><span class="n">dep</span><span class="p">))</span>
|
||||
|
||||
<span class="k">return</span> <span class="mi">0</span>
|
||||
</div>
|
||||
<div class="viewcode-block" id="recipes_push"><a class="viewcode-back" href="../../../composer.cli.html#composer.cli.recipes.recipes_push">[docs]</a><span class="k">def</span> <span class="nf">recipes_push</span><span class="p">(</span><span class="n">socket_path</span><span class="p">,</span> <span class="n">api_version</span><span class="p">,</span> <span class="n">args</span><span class="p">,</span> <span class="n">show_json</span><span class="o">=</span><span class="bp">False</span><span class="p">):</span>
|
||||
<span class="sd">"""Push a recipe TOML file to the server, updating the recipe</span>
|
||||
|
||||
<span class="sd"> :param socket_path: Path to the Unix socket to use for API communication</span>
|
||||
<span class="sd"> :type socket_path: str</span>
|
||||
<span class="sd"> :param api_version: Version of the API to talk to. eg. "0"</span>
|
||||
<span class="sd"> :type api_version: str</span>
|
||||
<span class="sd"> :param args: List of remaining arguments from the cmdline</span>
|
||||
<span class="sd"> :type args: list of str</span>
|
||||
<span class="sd"> :param show_json: Set to True to show the JSON output instead of the human readable output</span>
|
||||
<span class="sd"> :type show_json: bool</span>
|
||||
|
||||
<span class="sd"> push <recipe> Push a recipe TOML file to the server.</span>
|
||||
<span class="sd"> """</span>
|
||||
<span class="n">api_route</span> <span class="o">=</span> <span class="n">client</span><span class="o">.</span><span class="n">api_url</span><span class="p">(</span><span class="n">api_version</span><span class="p">,</span> <span class="s">"/recipes/new"</span><span class="p">)</span>
|
||||
<span class="n">rval</span> <span class="o">=</span> <span class="mi">0</span>
|
||||
<span class="k">for</span> <span class="n">recipe</span> <span class="ow">in</span> <span class="n">argify</span><span class="p">(</span><span class="n">args</span><span class="p">):</span>
|
||||
<span class="k">if</span> <span class="ow">not</span> <span class="n">os</span><span class="o">.</span><span class="n">path</span><span class="o">.</span><span class="n">exists</span><span class="p">(</span><span class="n">recipe</span><span class="p">):</span>
|
||||
<span class="n">log</span><span class="o">.</span><span class="n">error</span><span class="p">(</span><span class="s">"Missing recipe file: </span><span class="si">%s</span><span class="s">"</span><span class="p">,</span> <span class="n">recipe</span><span class="p">)</span>
|
||||
<span class="k">continue</span>
|
||||
<span class="n">recipe_toml</span> <span class="o">=</span> <span class="nb">open</span><span class="p">(</span><span class="n">recipe</span><span class="p">,</span> <span class="s">"r"</span><span class="p">)</span><span class="o">.</span><span class="n">read</span><span class="p">()</span>
|
||||
|
||||
<span class="n">result</span> <span class="o">=</span> <span class="n">client</span><span class="o">.</span><span class="n">post_url_toml</span><span class="p">(</span><span class="n">socket_path</span><span class="p">,</span> <span class="n">api_route</span><span class="p">,</span> <span class="n">recipe_toml</span><span class="p">)</span>
|
||||
<span class="k">if</span> <span class="n">handle_api_result</span><span class="p">(</span><span class="n">result</span><span class="p">,</span> <span class="n">show_json</span><span class="p">):</span>
|
||||
<span class="n">rval</span> <span class="o">=</span> <span class="mi">1</span>
|
||||
|
||||
<span class="k">return</span> <span class="n">rval</span>
|
||||
</div>
|
||||
<div class="viewcode-block" id="recipes_freeze"><a class="viewcode-back" href="../../../composer.cli.html#composer.cli.recipes.recipes_freeze">[docs]</a><span class="k">def</span> <span class="nf">recipes_freeze</span><span class="p">(</span><span class="n">socket_path</span><span class="p">,</span> <span class="n">api_version</span><span class="p">,</span> <span class="n">args</span><span class="p">,</span> <span class="n">show_json</span><span class="o">=</span><span class="bp">False</span><span class="p">):</span>
|
||||
<span class="sd">"""Handle the recipes freeze commands</span>
|
||||
|
||||
<span class="sd"> :param socket_path: Path to the Unix socket to use for API communication</span>
|
||||
<span class="sd"> :type socket_path: str</span>
|
||||
<span class="sd"> :param api_version: Version of the API to talk to. eg. "0"</span>
|
||||
<span class="sd"> :type api_version: str</span>
|
||||
<span class="sd"> :param args: List of remaining arguments from the cmdline</span>
|
||||
<span class="sd"> :type args: list of str</span>
|
||||
<span class="sd"> :param show_json: Set to True to show the JSON output instead of the human readable output</span>
|
||||
<span class="sd"> :type show_json: bool</span>
|
||||
|
||||
<span class="sd"> recipes freeze <recipe,...> Display the frozen recipe's modules and packages.</span>
|
||||
<span class="sd"> recipes freeze show <recipe,...> Display the frozen recipe in TOML format.</span>
|
||||
<span class="sd"> recipes freeze save <recipe,...> Save the frozen recipe to a file, <recipe-name>.frozen.toml.</span>
|
||||
<span class="sd"> """</span>
|
||||
<span class="k">if</span> <span class="n">args</span><span class="p">[</span><span class="mi">0</span><span class="p">]</span> <span class="o">==</span> <span class="s">"show"</span><span class="p">:</span>
|
||||
<span class="k">return</span> <span class="n">recipes_freeze_show</span><span class="p">(</span><span class="n">socket_path</span><span class="p">,</span> <span class="n">api_version</span><span class="p">,</span> <span class="n">args</span><span class="p">[</span><span class="mi">1</span><span class="p">:],</span> <span class="n">show_json</span><span class="p">)</span>
|
||||
<span class="k">elif</span> <span class="n">args</span><span class="p">[</span><span class="mi">0</span><span class="p">]</span> <span class="o">==</span> <span class="s">"save"</span><span class="p">:</span>
|
||||
<span class="k">return</span> <span class="n">recipes_freeze_save</span><span class="p">(</span><span class="n">socket_path</span><span class="p">,</span> <span class="n">api_version</span><span class="p">,</span> <span class="n">args</span><span class="p">[</span><span class="mi">1</span><span class="p">:],</span> <span class="n">show_json</span><span class="p">)</span>
|
||||
|
||||
<span class="k">if</span> <span class="nb">len</span><span class="p">(</span><span class="n">args</span><span class="p">)</span> <span class="o">==</span> <span class="mi">0</span><span class="p">:</span>
|
||||
<span class="n">log</span><span class="o">.</span><span class="n">error</span><span class="p">(</span><span class="s">"freeze is missing the recipe name"</span><span class="p">)</span>
|
||||
<span class="k">return</span> <span class="mi">1</span>
|
||||
|
||||
<span class="n">api_route</span> <span class="o">=</span> <span class="n">client</span><span class="o">.</span><span class="n">api_url</span><span class="p">(</span><span class="n">api_version</span><span class="p">,</span> <span class="s">"/recipes/freeze/</span><span class="si">%s</span><span class="s">"</span> <span class="o">%</span> <span class="p">(</span><span class="s">","</span><span class="o">.</span><span class="n">join</span><span class="p">(</span><span class="n">argify</span><span class="p">(</span><span class="n">args</span><span class="p">))))</span>
|
||||
<span class="n">result</span> <span class="o">=</span> <span class="n">client</span><span class="o">.</span><span class="n">get_url_json</span><span class="p">(</span><span class="n">socket_path</span><span class="p">,</span> <span class="n">api_route</span><span class="p">)</span>
|
||||
|
||||
<span class="k">if</span> <span class="n">show_json</span><span class="p">:</span>
|
||||
<span class="k">print</span><span class="p">(</span><span class="n">json</span><span class="o">.</span><span class="n">dumps</span><span class="p">(</span><span class="n">result</span><span class="p">,</span> <span class="n">indent</span><span class="o">=</span><span class="mi">4</span><span class="p">))</span>
|
||||
<span class="k">else</span><span class="p">:</span>
|
||||
<span class="k">for</span> <span class="n">entry</span> <span class="ow">in</span> <span class="n">result</span><span class="p">[</span><span class="s">"recipes"</span><span class="p">]:</span>
|
||||
<span class="n">recipe</span> <span class="o">=</span> <span class="n">entry</span><span class="p">[</span><span class="s">"recipe"</span><span class="p">]</span>
|
||||
<span class="k">if</span> <span class="n">recipe</span><span class="o">.</span><span class="n">get</span><span class="p">(</span><span class="s">"version"</span><span class="p">,</span> <span class="s">""</span><span class="p">):</span>
|
||||
<span class="k">print</span><span class="p">(</span><span class="s">"Recipe: </span><span class="si">%s</span><span class="s"> v</span><span class="si">%s</span><span class="s">"</span> <span class="o">%</span> <span class="p">(</span><span class="n">recipe</span><span class="p">[</span><span class="s">"name"</span><span class="p">],</span> <span class="n">recipe</span><span class="p">[</span><span class="s">"version"</span><span class="p">]))</span>
|
||||
<span class="k">else</span><span class="p">:</span>
|
||||
<span class="k">print</span><span class="p">(</span><span class="s">"Recipe: </span><span class="si">%s</span><span class="s">"</span> <span class="o">%</span> <span class="p">(</span><span class="n">recipe</span><span class="p">[</span><span class="s">"name"</span><span class="p">]))</span>
|
||||
|
||||
<span class="k">for</span> <span class="n">m</span> <span class="ow">in</span> <span class="n">recipe</span><span class="p">[</span><span class="s">"modules"</span><span class="p">]:</span>
|
||||
<span class="k">print</span><span class="p">(</span><span class="s">" </span><span class="si">%s</span><span class="s">-</span><span class="si">%s</span><span class="s">"</span> <span class="o">%</span> <span class="p">(</span><span class="n">m</span><span class="p">[</span><span class="s">"name"</span><span class="p">],</span> <span class="n">m</span><span class="p">[</span><span class="s">"version"</span><span class="p">]))</span>
|
||||
|
||||
<span class="k">for</span> <span class="n">p</span> <span class="ow">in</span> <span class="n">recipe</span><span class="p">[</span><span class="s">"packages"</span><span class="p">]:</span>
|
||||
<span class="k">print</span><span class="p">(</span><span class="s">" </span><span class="si">%s</span><span class="s">-</span><span class="si">%s</span><span class="s">"</span> <span class="o">%</span> <span class="p">(</span><span class="n">p</span><span class="p">[</span><span class="s">"name"</span><span class="p">],</span> <span class="n">p</span><span class="p">[</span><span class="s">"version"</span><span class="p">]))</span>
|
||||
|
||||
<span class="c"># Print any errors</span>
|
||||
<span class="k">for</span> <span class="n">err</span> <span class="ow">in</span> <span class="n">result</span><span class="o">.</span><span class="n">get</span><span class="p">(</span><span class="s">"errors"</span><span class="p">,</span> <span class="p">[]):</span>
|
||||
<span class="n">log</span><span class="o">.</span><span class="n">error</span><span class="p">(</span><span class="s">"</span><span class="si">%s</span><span class="s">: </span><span class="si">%s</span><span class="s">"</span><span class="p">,</span> <span class="n">err</span><span class="p">[</span><span class="s">"recipe"</span><span class="p">],</span> <span class="n">err</span><span class="p">[</span><span class="s">"msg"</span><span class="p">])</span>
|
||||
|
||||
<span class="c"># Return a 1 if there are any errors</span>
|
||||
<span class="k">if</span> <span class="n">result</span><span class="o">.</span><span class="n">get</span><span class="p">(</span><span class="s">"errors"</span><span class="p">,</span> <span class="p">[]):</span>
|
||||
<span class="k">return</span> <span class="mi">1</span>
|
||||
<span class="k">else</span><span class="p">:</span>
|
||||
<span class="k">return</span> <span class="mi">0</span>
|
||||
</div>
|
||||
<div class="viewcode-block" id="recipes_freeze_show"><a class="viewcode-back" href="../../../composer.cli.html#composer.cli.recipes.recipes_freeze_show">[docs]</a><span class="k">def</span> <span class="nf">recipes_freeze_show</span><span class="p">(</span><span class="n">socket_path</span><span class="p">,</span> <span class="n">api_version</span><span class="p">,</span> <span class="n">args</span><span class="p">,</span> <span class="n">show_json</span><span class="o">=</span><span class="bp">False</span><span class="p">):</span>
|
||||
<span class="sd">"""Show the frozen recipe in TOML format</span>
|
||||
|
||||
<span class="sd"> :param socket_path: Path to the Unix socket to use for API communication</span>
|
||||
<span class="sd"> :type socket_path: str</span>
|
||||
<span class="sd"> :param api_version: Version of the API to talk to. eg. "0"</span>
|
||||
<span class="sd"> :type api_version: str</span>
|
||||
<span class="sd"> :param args: List of remaining arguments from the cmdline</span>
|
||||
<span class="sd"> :type args: list of str</span>
|
||||
<span class="sd"> :param show_json: Set to True to show the JSON output instead of the human readable output</span>
|
||||
<span class="sd"> :type show_json: bool</span>
|
||||
|
||||
<span class="sd"> recipes freeze show <recipe,...> Display the frozen recipe in TOML format.</span>
|
||||
<span class="sd"> """</span>
|
||||
<span class="k">if</span> <span class="nb">len</span><span class="p">(</span><span class="n">args</span><span class="p">)</span> <span class="o">==</span> <span class="mi">0</span><span class="p">:</span>
|
||||
<span class="n">log</span><span class="o">.</span><span class="n">error</span><span class="p">(</span><span class="s">"freeze show is missing the recipe name"</span><span class="p">)</span>
|
||||
<span class="k">return</span> <span class="mi">1</span>
|
||||
|
||||
<span class="k">for</span> <span class="n">recipe</span> <span class="ow">in</span> <span class="n">argify</span><span class="p">(</span><span class="n">args</span><span class="p">):</span>
|
||||
<span class="n">api_route</span> <span class="o">=</span> <span class="n">client</span><span class="o">.</span><span class="n">api_url</span><span class="p">(</span><span class="n">api_version</span><span class="p">,</span> <span class="s">"/recipes/freeze/</span><span class="si">%s</span><span class="s">?format=toml"</span> <span class="o">%</span> <span class="n">recipe</span><span class="p">)</span>
|
||||
<span class="k">print</span><span class="p">(</span><span class="n">client</span><span class="o">.</span><span class="n">get_url_raw</span><span class="p">(</span><span class="n">socket_path</span><span class="p">,</span> <span class="n">api_route</span><span class="p">))</span>
|
||||
|
||||
<span class="k">return</span> <span class="mi">0</span>
|
||||
</div>
|
||||
<div class="viewcode-block" id="recipes_freeze_save"><a class="viewcode-back" href="../../../composer.cli.html#composer.cli.recipes.recipes_freeze_save">[docs]</a><span class="k">def</span> <span class="nf">recipes_freeze_save</span><span class="p">(</span><span class="n">socket_path</span><span class="p">,</span> <span class="n">api_version</span><span class="p">,</span> <span class="n">args</span><span class="p">,</span> <span class="n">show_json</span><span class="o">=</span><span class="bp">False</span><span class="p">):</span>
|
||||
<span class="sd">"""Save the frozen recipe to a TOML file</span>
|
||||
|
||||
<span class="sd"> :param socket_path: Path to the Unix socket to use for API communication</span>
|
||||
<span class="sd"> :type socket_path: str</span>
|
||||
<span class="sd"> :param api_version: Version of the API to talk to. eg. "0"</span>
|
||||
<span class="sd"> :type api_version: str</span>
|
||||
<span class="sd"> :param args: List of remaining arguments from the cmdline</span>
|
||||
<span class="sd"> :type args: list of str</span>
|
||||
<span class="sd"> :param show_json: Set to True to show the JSON output instead of the human readable output</span>
|
||||
<span class="sd"> :type show_json: bool</span>
|
||||
|
||||
<span class="sd"> recipes freeze save <recipe,...> Save the frozen recipe to a file, <recipe-name>.frozen.toml.</span>
|
||||
<span class="sd"> """</span>
|
||||
<span class="k">if</span> <span class="nb">len</span><span class="p">(</span><span class="n">args</span><span class="p">)</span> <span class="o">==</span> <span class="mi">0</span><span class="p">:</span>
|
||||
<span class="n">log</span><span class="o">.</span><span class="n">error</span><span class="p">(</span><span class="s">"freeze save is missing the recipe name"</span><span class="p">)</span>
|
||||
<span class="k">return</span> <span class="mi">1</span>
|
||||
|
||||
<span class="k">for</span> <span class="n">recipe</span> <span class="ow">in</span> <span class="n">argify</span><span class="p">(</span><span class="n">args</span><span class="p">):</span>
|
||||
<span class="n">api_route</span> <span class="o">=</span> <span class="n">client</span><span class="o">.</span><span class="n">api_url</span><span class="p">(</span><span class="n">api_version</span><span class="p">,</span> <span class="s">"/recipes/freeze/</span><span class="si">%s</span><span class="s">?format=toml"</span> <span class="o">%</span> <span class="n">recipe</span><span class="p">)</span>
|
||||
<span class="n">recipe_toml</span> <span class="o">=</span> <span class="n">client</span><span class="o">.</span><span class="n">get_url_raw</span><span class="p">(</span><span class="n">socket_path</span><span class="p">,</span> <span class="n">api_route</span><span class="p">)</span>
|
||||
<span class="nb">open</span><span class="p">(</span><span class="n">frozen_toml_filename</span><span class="p">(</span><span class="n">recipe</span><span class="p">),</span> <span class="s">"w"</span><span class="p">)</span><span class="o">.</span><span class="n">write</span><span class="p">(</span><span class="n">recipe_toml</span><span class="p">)</span>
|
||||
|
||||
<span class="k">return</span> <span class="mi">0</span>
|
||||
</div>
|
||||
<div class="viewcode-block" id="recipes_tag"><a class="viewcode-back" href="../../../composer.cli.html#composer.cli.recipes.recipes_tag">[docs]</a><span class="k">def</span> <span class="nf">recipes_tag</span><span class="p">(</span><span class="n">socket_path</span><span class="p">,</span> <span class="n">api_version</span><span class="p">,</span> <span class="n">args</span><span class="p">,</span> <span class="n">show_json</span><span class="o">=</span><span class="bp">False</span><span class="p">):</span>
|
||||
<span class="sd">"""Tag the most recent recipe commit as a release</span>
|
||||
|
||||
<span class="sd"> :param socket_path: Path to the Unix socket to use for API communication</span>
|
||||
<span class="sd"> :type socket_path: str</span>
|
||||
<span class="sd"> :param api_version: Version of the API to talk to. eg. "0"</span>
|
||||
<span class="sd"> :type api_version: str</span>
|
||||
<span class="sd"> :param args: List of remaining arguments from the cmdline</span>
|
||||
<span class="sd"> :type args: list of str</span>
|
||||
<span class="sd"> :param show_json: Set to True to show the JSON output instead of the human readable output</span>
|
||||
<span class="sd"> :type show_json: bool</span>
|
||||
|
||||
<span class="sd"> recipes tag <recipe> Tag the most recent recipe commit as a release.</span>
|
||||
<span class="sd"> """</span>
|
||||
<span class="n">api_route</span> <span class="o">=</span> <span class="n">client</span><span class="o">.</span><span class="n">api_url</span><span class="p">(</span><span class="n">api_version</span><span class="p">,</span> <span class="s">"/recipes/tag/</span><span class="si">%s</span><span class="s">"</span> <span class="o">%</span> <span class="n">args</span><span class="p">[</span><span class="mi">0</span><span class="p">])</span>
|
||||
<span class="n">result</span> <span class="o">=</span> <span class="n">client</span><span class="o">.</span><span class="n">post_url</span><span class="p">(</span><span class="n">socket_path</span><span class="p">,</span> <span class="n">api_route</span><span class="p">,</span> <span class="s">""</span><span class="p">)</span>
|
||||
|
||||
<span class="k">return</span> <span class="n">handle_api_result</span><span class="p">(</span><span class="n">result</span><span class="p">,</span> <span class="n">show_json</span><span class="p">)</span>
|
||||
</div>
|
||||
<div class="viewcode-block" id="recipes_undo"><a class="viewcode-back" href="../../../composer.cli.html#composer.cli.recipes.recipes_undo">[docs]</a><span class="k">def</span> <span class="nf">recipes_undo</span><span class="p">(</span><span class="n">socket_path</span><span class="p">,</span> <span class="n">api_version</span><span class="p">,</span> <span class="n">args</span><span class="p">,</span> <span class="n">show_json</span><span class="o">=</span><span class="bp">False</span><span class="p">):</span>
|
||||
<span class="sd">"""Undo changes to a recipe</span>
|
||||
|
||||
<span class="sd"> :param socket_path: Path to the Unix socket to use for API communication</span>
|
||||
<span class="sd"> :type socket_path: str</span>
|
||||
<span class="sd"> :param api_version: Version of the API to talk to. eg. "0"</span>
|
||||
<span class="sd"> :type api_version: str</span>
|
||||
<span class="sd"> :param args: List of remaining arguments from the cmdline</span>
|
||||
<span class="sd"> :type args: list of str</span>
|
||||
<span class="sd"> :param show_json: Set to True to show the JSON output instead of the human readable output</span>
|
||||
<span class="sd"> :type show_json: bool</span>
|
||||
|
||||
<span class="sd"> recipes undo <recipe> <commit> Undo changes to a recipe by reverting to the selected commit.</span>
|
||||
<span class="sd"> """</span>
|
||||
<span class="k">if</span> <span class="nb">len</span><span class="p">(</span><span class="n">args</span><span class="p">)</span> <span class="o">==</span> <span class="mi">0</span><span class="p">:</span>
|
||||
<span class="n">log</span><span class="o">.</span><span class="n">error</span><span class="p">(</span><span class="s">"undo is missing the recipe name and commit hash"</span><span class="p">)</span>
|
||||
<span class="k">return</span> <span class="mi">1</span>
|
||||
<span class="k">elif</span> <span class="nb">len</span><span class="p">(</span><span class="n">args</span><span class="p">)</span> <span class="o">==</span> <span class="mi">1</span><span class="p">:</span>
|
||||
<span class="n">log</span><span class="o">.</span><span class="n">error</span><span class="p">(</span><span class="s">"undo is missing commit hash"</span><span class="p">)</span>
|
||||
<span class="k">return</span> <span class="mi">1</span>
|
||||
|
||||
<span class="n">api_route</span> <span class="o">=</span> <span class="n">client</span><span class="o">.</span><span class="n">api_url</span><span class="p">(</span><span class="n">api_version</span><span class="p">,</span> <span class="s">"/recipes/undo/</span><span class="si">%s</span><span class="s">/</span><span class="si">%s</span><span class="s">"</span> <span class="o">%</span> <span class="p">(</span><span class="n">args</span><span class="p">[</span><span class="mi">0</span><span class="p">],</span> <span class="n">args</span><span class="p">[</span><span class="mi">1</span><span class="p">]))</span>
|
||||
<span class="n">result</span> <span class="o">=</span> <span class="n">client</span><span class="o">.</span><span class="n">post_url</span><span class="p">(</span><span class="n">socket_path</span><span class="p">,</span> <span class="n">api_route</span><span class="p">,</span> <span class="s">""</span><span class="p">)</span>
|
||||
|
||||
<span class="k">return</span> <span class="n">handle_api_result</span><span class="p">(</span><span class="n">result</span><span class="p">,</span> <span class="n">show_json</span><span class="p">)</span>
|
||||
</div>
|
||||
<div class="viewcode-block" id="recipes_workspace"><a class="viewcode-back" href="../../../composer.cli.html#composer.cli.recipes.recipes_workspace">[docs]</a><span class="k">def</span> <span class="nf">recipes_workspace</span><span class="p">(</span><span class="n">socket_path</span><span class="p">,</span> <span class="n">api_version</span><span class="p">,</span> <span class="n">args</span><span class="p">,</span> <span class="n">show_json</span><span class="o">=</span><span class="bp">False</span><span class="p">):</span>
|
||||
<span class="sd">"""Push the recipe TOML to the temporary workspace storage</span>
|
||||
|
||||
<span class="sd"> :param socket_path: Path to the Unix socket to use for API communication</span>
|
||||
<span class="sd"> :type socket_path: str</span>
|
||||
<span class="sd"> :param api_version: Version of the API to talk to. eg. "0"</span>
|
||||
<span class="sd"> :type api_version: str</span>
|
||||
<span class="sd"> :param args: List of remaining arguments from the cmdline</span>
|
||||
<span class="sd"> :type args: list of str</span>
|
||||
<span class="sd"> :param show_json: Set to True to show the JSON output instead of the human readable output</span>
|
||||
<span class="sd"> :type show_json: bool</span>
|
||||
|
||||
<span class="sd"> recipes workspace <recipe> Push the recipe TOML to the temporary workspace storage.</span>
|
||||
<span class="sd"> """</span>
|
||||
<span class="n">api_route</span> <span class="o">=</span> <span class="n">client</span><span class="o">.</span><span class="n">api_url</span><span class="p">(</span><span class="n">api_version</span><span class="p">,</span> <span class="s">"/recipes/workspace"</span><span class="p">)</span>
|
||||
<span class="n">rval</span> <span class="o">=</span> <span class="mi">0</span>
|
||||
<span class="k">for</span> <span class="n">recipe</span> <span class="ow">in</span> <span class="n">argify</span><span class="p">(</span><span class="n">args</span><span class="p">):</span>
|
||||
<span class="k">if</span> <span class="ow">not</span> <span class="n">os</span><span class="o">.</span><span class="n">path</span><span class="o">.</span><span class="n">exists</span><span class="p">(</span><span class="n">recipe</span><span class="p">):</span>
|
||||
<span class="n">log</span><span class="o">.</span><span class="n">error</span><span class="p">(</span><span class="s">"Missing recipe file: </span><span class="si">%s</span><span class="s">"</span><span class="p">,</span> <span class="n">recipe</span><span class="p">)</span>
|
||||
<span class="k">continue</span>
|
||||
<span class="n">recipe_toml</span> <span class="o">=</span> <span class="nb">open</span><span class="p">(</span><span class="n">recipe</span><span class="p">,</span> <span class="s">"r"</span><span class="p">)</span><span class="o">.</span><span class="n">read</span><span class="p">()</span>
|
||||
|
||||
<span class="n">result</span> <span class="o">=</span> <span class="n">client</span><span class="o">.</span><span class="n">post_url_toml</span><span class="p">(</span><span class="n">socket_path</span><span class="p">,</span> <span class="n">api_route</span><span class="p">,</span> <span class="n">recipe_toml</span><span class="p">)</span>
|
||||
<span class="k">if</span> <span class="n">show_json</span><span class="p">:</span>
|
||||
<span class="k">print</span><span class="p">(</span><span class="n">json</span><span class="o">.</span><span class="n">dumps</span><span class="p">(</span><span class="n">result</span><span class="p">,</span> <span class="n">indent</span><span class="o">=</span><span class="mi">4</span><span class="p">))</span>
|
||||
<span class="k">elif</span> <span class="n">result</span><span class="o">.</span><span class="n">get</span><span class="p">(</span><span class="s">"error"</span><span class="p">,</span> <span class="bp">False</span><span class="p">):</span>
|
||||
<span class="n">log</span><span class="o">.</span><span class="n">error</span><span class="p">(</span><span class="n">result</span><span class="p">[</span><span class="s">"error"</span><span class="p">][</span><span class="s">"msg"</span><span class="p">])</span>
|
||||
|
||||
<span class="c"># Any errors results in returning a 1, but we continue with the rest first</span>
|
||||
<span class="k">if</span> <span class="ow">not</span> <span class="n">result</span><span class="o">.</span><span class="n">get</span><span class="p">(</span><span class="s">"status"</span><span class="p">,</span> <span class="bp">False</span><span class="p">):</span>
|
||||
<span class="n">rval</span> <span class="o">=</span> <span class="mi">1</span>
|
||||
|
||||
<span class="k">return</span> <span class="n">rval</span></div>
|
||||
</pre></div>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="sphinxsidebar">
|
||||
<div class="sphinxsidebarwrapper">
|
||||
<div id="searchbox" style="display: none">
|
||||
<h3>Quick search</h3>
|
||||
<form class="search" action="../../../search.html" method="get">
|
||||
<input type="text" name="q" />
|
||||
<input type="submit" value="Go" />
|
||||
<input type="hidden" name="check_keywords" value="yes" />
|
||||
<input type="hidden" name="area" value="default" />
|
||||
</form>
|
||||
<p class="searchtip" style="font-size: 90%">
|
||||
Enter search terms or a module, class or function name.
|
||||
</p>
|
||||
</div>
|
||||
<script type="text/javascript">$('#searchbox').show(0);</script>
|
||||
</div>
|
||||
</div>
|
||||
<div class="clearer"></div>
|
||||
</div>
|
||||
<div class="related">
|
||||
<h3>Navigation</h3>
|
||||
<ul>
|
||||
<li class="right" style="margin-right: 10px">
|
||||
<a href="../../../genindex.html" title="General Index"
|
||||
>index</a></li>
|
||||
<li class="right" >
|
||||
<a href="../../../py-modindex.html" title="Python Module Index"
|
||||
>modules</a> |</li>
|
||||
<li><a href="../../../index.html">Lorax 19.7.11 documentation</a> »</li>
|
||||
<li><a href="../../index.html" >Module code</a> »</li>
|
||||
<li><a href="../cli.html" >composer.cli</a> »</li>
|
||||
</ul>
|
||||
</div>
|
||||
<div class="footer">
|
||||
© Copyright 2018, Red Hat, Inc..
|
||||
Created using <a href="http://sphinx.pocoo.org/">Sphinx</a> 1.1.3.
|
||||
</div>
|
||||
</body>
|
||||
</html>
|
179
lorax-composer/_modules/composer/cli/utilities.html
Normal file
179
lorax-composer/_modules/composer/cli/utilities.html
Normal file
@ -0,0 +1,179 @@
|
||||
|
||||
|
||||
<!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>composer.cli.utilities — Lorax 19.7.11 documentation</title>
|
||||
|
||||
<link rel="stylesheet" href="../../../_static/default.css" type="text/css" />
|
||||
<link rel="stylesheet" href="../../../_static/pygments.css" type="text/css" />
|
||||
|
||||
<script type="text/javascript">
|
||||
var DOCUMENTATION_OPTIONS = {
|
||||
URL_ROOT: '../../../',
|
||||
VERSION: '19.7.11',
|
||||
COLLAPSE_INDEX: false,
|
||||
FILE_SUFFIX: '.html',
|
||||
HAS_SOURCE: true
|
||||
};
|
||||
</script>
|
||||
<script type="text/javascript" src="../../../_static/jquery.js"></script>
|
||||
<script type="text/javascript" src="../../../_static/underscore.js"></script>
|
||||
<script type="text/javascript" src="../../../_static/doctools.js"></script>
|
||||
<link rel="top" title="Lorax 19.7.11 documentation" href="../../../index.html" />
|
||||
<link rel="up" title="composer.cli" href="../cli.html" />
|
||||
</head>
|
||||
<body>
|
||||
<div class="related">
|
||||
<h3>Navigation</h3>
|
||||
<ul>
|
||||
<li class="right" style="margin-right: 10px">
|
||||
<a href="../../../genindex.html" title="General Index"
|
||||
accesskey="I">index</a></li>
|
||||
<li class="right" >
|
||||
<a href="../../../py-modindex.html" title="Python Module Index"
|
||||
>modules</a> |</li>
|
||||
<li><a href="../../../index.html">Lorax 19.7.11 documentation</a> »</li>
|
||||
<li><a href="../../index.html" >Module code</a> »</li>
|
||||
<li><a href="../cli.html" accesskey="U">composer.cli</a> »</li>
|
||||
</ul>
|
||||
</div>
|
||||
|
||||
<div class="document">
|
||||
<div class="documentwrapper">
|
||||
<div class="bodywrapper">
|
||||
<div class="body">
|
||||
|
||||
<h1>Source code for composer.cli.utilities</h1><div class="highlight"><pre>
|
||||
<span class="c">#</span>
|
||||
<span class="c"># Copyright (C) 2018 Red Hat, Inc.</span>
|
||||
<span class="c">#</span>
|
||||
<span class="c"># This program is free software; you can redistribute it and/or modify</span>
|
||||
<span class="c"># it under the terms of the GNU General Public License as published by</span>
|
||||
<span class="c"># the Free Software Foundation; either version 2 of the License, or</span>
|
||||
<span class="c"># (at your option) any later version.</span>
|
||||
<span class="c">#</span>
|
||||
<span class="c"># This program is distributed in the hope that it will be useful,</span>
|
||||
<span class="c"># but WITHOUT ANY WARRANTY; without even the implied warranty of</span>
|
||||
<span class="c"># MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the</span>
|
||||
<span class="c"># GNU General Public License for more details.</span>
|
||||
<span class="c">#</span>
|
||||
<span class="c"># You should have received a copy of the GNU General Public License</span>
|
||||
<span class="c"># along with this program. If not, see <http://www.gnu.org/licenses/>.</span>
|
||||
<span class="c">#</span>
|
||||
<span class="kn">import</span> <span class="nn">logging</span>
|
||||
<span class="n">log</span> <span class="o">=</span> <span class="n">logging</span><span class="o">.</span><span class="n">getLogger</span><span class="p">(</span><span class="s">"composer-cli"</span><span class="p">)</span>
|
||||
|
||||
<span class="kn">import</span> <span class="nn">json</span>
|
||||
|
||||
<div class="viewcode-block" id="argify"><a class="viewcode-back" href="../../../composer.cli.html#composer.cli.utilities.argify">[docs]</a><span class="k">def</span> <span class="nf">argify</span><span class="p">(</span><span class="n">args</span><span class="p">):</span>
|
||||
<span class="sd">"""Take a list of human args and return a list with each item</span>
|
||||
|
||||
<span class="sd"> :param args: list of strings with possible commas and spaces</span>
|
||||
<span class="sd"> :type args: list of str</span>
|
||||
<span class="sd"> :returns: List of all the items</span>
|
||||
<span class="sd"> :rtype: list of str</span>
|
||||
|
||||
<span class="sd"> Examples:</span>
|
||||
|
||||
<span class="sd"> ["one,two", "three", ",four", ",five,"] returns ["one", "two", "three", "four", "five"]</span>
|
||||
<span class="sd"> """</span>
|
||||
<span class="k">return</span> <span class="nb">filter</span><span class="p">(</span><span class="k">lambda</span> <span class="n">i</span><span class="p">:</span> <span class="n">i</span><span class="p">,</span> <span class="p">[</span><span class="n">arg</span> <span class="k">for</span> <span class="n">entry</span> <span class="ow">in</span> <span class="n">args</span> <span class="k">for</span> <span class="n">arg</span> <span class="ow">in</span> <span class="n">entry</span><span class="o">.</span><span class="n">split</span><span class="p">(</span><span class="s">","</span><span class="p">)])</span>
|
||||
</div>
|
||||
<div class="viewcode-block" id="toml_filename"><a class="viewcode-back" href="../../../composer.cli.html#composer.cli.utilities.toml_filename">[docs]</a><span class="k">def</span> <span class="nf">toml_filename</span><span class="p">(</span><span class="n">recipe_name</span><span class="p">):</span>
|
||||
<span class="sd">"""Convert a recipe name into a filename.toml</span>
|
||||
|
||||
<span class="sd"> :param recipe_name: The recipe's name</span>
|
||||
<span class="sd"> :type recipe_name: str</span>
|
||||
<span class="sd"> :returns: The recipe name with ' ' converted to - and .toml appended</span>
|
||||
<span class="sd"> :rtype: str</span>
|
||||
<span class="sd"> """</span>
|
||||
<span class="k">return</span> <span class="n">recipe_name</span><span class="o">.</span><span class="n">replace</span><span class="p">(</span><span class="s">" "</span><span class="p">,</span> <span class="s">"-"</span><span class="p">)</span> <span class="o">+</span> <span class="s">".toml"</span>
|
||||
</div>
|
||||
<div class="viewcode-block" id="frozen_toml_filename"><a class="viewcode-back" href="../../../composer.cli.html#composer.cli.utilities.frozen_toml_filename">[docs]</a><span class="k">def</span> <span class="nf">frozen_toml_filename</span><span class="p">(</span><span class="n">recipe_name</span><span class="p">):</span>
|
||||
<span class="sd">"""Convert a recipe name into a filename.toml</span>
|
||||
|
||||
<span class="sd"> :param recipe_name: The recipe's name</span>
|
||||
<span class="sd"> :type recipe_name: str</span>
|
||||
<span class="sd"> :returns: The recipe name with ' ' converted to - and .toml appended</span>
|
||||
<span class="sd"> :rtype: str</span>
|
||||
<span class="sd"> """</span>
|
||||
<span class="k">return</span> <span class="n">recipe_name</span><span class="o">.</span><span class="n">replace</span><span class="p">(</span><span class="s">" "</span><span class="p">,</span> <span class="s">"-"</span><span class="p">)</span> <span class="o">+</span> <span class="s">".frozen.toml"</span>
|
||||
</div>
|
||||
<div class="viewcode-block" id="handle_api_result"><a class="viewcode-back" href="../../../composer.cli.html#composer.cli.utilities.handle_api_result">[docs]</a><span class="k">def</span> <span class="nf">handle_api_result</span><span class="p">(</span><span class="n">result</span><span class="p">,</span> <span class="n">show_json</span><span class="o">=</span><span class="bp">False</span><span class="p">):</span>
|
||||
<span class="sd">"""Log any errors, return the correct value</span>
|
||||
|
||||
<span class="sd"> :param result: JSON result from the http query</span>
|
||||
<span class="sd"> :type result: dict</span>
|
||||
<span class="sd"> """</span>
|
||||
<span class="k">if</span> <span class="n">show_json</span><span class="p">:</span>
|
||||
<span class="k">print</span><span class="p">(</span><span class="n">json</span><span class="o">.</span><span class="n">dumps</span><span class="p">(</span><span class="n">result</span><span class="p">,</span> <span class="n">indent</span><span class="o">=</span><span class="mi">4</span><span class="p">))</span>
|
||||
<span class="k">elif</span> <span class="n">result</span><span class="o">.</span><span class="n">get</span><span class="p">(</span><span class="s">"error"</span><span class="p">,</span> <span class="bp">False</span><span class="p">):</span>
|
||||
<span class="n">log</span><span class="o">.</span><span class="n">error</span><span class="p">(</span><span class="n">result</span><span class="p">[</span><span class="s">"error"</span><span class="p">][</span><span class="s">"msg"</span><span class="p">])</span>
|
||||
|
||||
<span class="k">if</span> <span class="n">result</span><span class="p">[</span><span class="s">"status"</span><span class="p">]</span> <span class="o">==</span> <span class="bp">True</span><span class="p">:</span>
|
||||
<span class="k">return</span> <span class="mi">0</span>
|
||||
<span class="k">else</span><span class="p">:</span>
|
||||
<span class="k">return</span> <span class="mi">1</span>
|
||||
</div>
|
||||
<div class="viewcode-block" id="packageNEVRA"><a class="viewcode-back" href="../../../composer.cli.html#composer.cli.utilities.packageNEVRA">[docs]</a><span class="k">def</span> <span class="nf">packageNEVRA</span><span class="p">(</span><span class="n">pkg</span><span class="p">):</span>
|
||||
<span class="sd">"""Return the package info as a NEVRA</span>
|
||||
|
||||
<span class="sd"> :param pkg: The package details</span>
|
||||
<span class="sd"> :type pkg: dict</span>
|
||||
<span class="sd"> :returns: name-[epoch:]version-release-arch</span>
|
||||
<span class="sd"> :rtype: str</span>
|
||||
<span class="sd"> """</span>
|
||||
<span class="k">if</span> <span class="n">pkg</span><span class="p">[</span><span class="s">"epoch"</span><span class="p">]:</span>
|
||||
<span class="k">return</span> <span class="s">"</span><span class="si">%s</span><span class="s">-</span><span class="si">%s</span><span class="s">:</span><span class="si">%s</span><span class="s">-</span><span class="si">%s</span><span class="s">.</span><span class="si">%s</span><span class="s">"</span> <span class="o">%</span> <span class="p">(</span><span class="n">pkg</span><span class="p">[</span><span class="s">"name"</span><span class="p">],</span> <span class="n">pkg</span><span class="p">[</span><span class="s">"epoch"</span><span class="p">],</span> <span class="n">pkg</span><span class="p">[</span><span class="s">"version"</span><span class="p">],</span> <span class="n">pkg</span><span class="p">[</span><span class="s">"release"</span><span class="p">],</span> <span class="n">pkg</span><span class="p">[</span><span class="s">"arch"</span><span class="p">])</span>
|
||||
<span class="k">else</span><span class="p">:</span>
|
||||
<span class="k">return</span> <span class="s">"</span><span class="si">%s</span><span class="s">-</span><span class="si">%s</span><span class="s">-</span><span class="si">%s</span><span class="s">.</span><span class="si">%s</span><span class="s">"</span> <span class="o">%</span> <span class="p">(</span><span class="n">pkg</span><span class="p">[</span><span class="s">"name"</span><span class="p">],</span> <span class="n">pkg</span><span class="p">[</span><span class="s">"version"</span><span class="p">],</span> <span class="n">pkg</span><span class="p">[</span><span class="s">"release"</span><span class="p">],</span> <span class="n">pkg</span><span class="p">[</span><span class="s">"arch"</span><span class="p">])</span></div>
|
||||
</pre></div>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="sphinxsidebar">
|
||||
<div class="sphinxsidebarwrapper">
|
||||
<div id="searchbox" style="display: none">
|
||||
<h3>Quick search</h3>
|
||||
<form class="search" action="../../../search.html" method="get">
|
||||
<input type="text" name="q" />
|
||||
<input type="submit" value="Go" />
|
||||
<input type="hidden" name="check_keywords" value="yes" />
|
||||
<input type="hidden" name="area" value="default" />
|
||||
</form>
|
||||
<p class="searchtip" style="font-size: 90%">
|
||||
Enter search terms or a module, class or function name.
|
||||
</p>
|
||||
</div>
|
||||
<script type="text/javascript">$('#searchbox').show(0);</script>
|
||||
</div>
|
||||
</div>
|
||||
<div class="clearer"></div>
|
||||
</div>
|
||||
<div class="related">
|
||||
<h3>Navigation</h3>
|
||||
<ul>
|
||||
<li class="right" style="margin-right: 10px">
|
||||
<a href="../../../genindex.html" title="General Index"
|
||||
>index</a></li>
|
||||
<li class="right" >
|
||||
<a href="../../../py-modindex.html" title="Python Module Index"
|
||||
>modules</a> |</li>
|
||||
<li><a href="../../../index.html">Lorax 19.7.11 documentation</a> »</li>
|
||||
<li><a href="../../index.html" >Module code</a> »</li>
|
||||
<li><a href="../cli.html" >composer.cli</a> »</li>
|
||||
</ul>
|
||||
</div>
|
||||
<div class="footer">
|
||||
© Copyright 2018, Red Hat, Inc..
|
||||
Created using <a href="http://sphinx.pocoo.org/">Sphinx</a> 1.1.3.
|
||||
</div>
|
||||
</body>
|
||||
</html>
|
290
lorax-composer/_modules/composer/http_client.html
Normal file
290
lorax-composer/_modules/composer/http_client.html
Normal file
@ -0,0 +1,290 @@
|
||||
|
||||
|
||||
<!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>composer.http_client — Lorax 19.7.11 documentation</title>
|
||||
|
||||
<link rel="stylesheet" href="../../_static/default.css" type="text/css" />
|
||||
<link rel="stylesheet" href="../../_static/pygments.css" type="text/css" />
|
||||
|
||||
<script type="text/javascript">
|
||||
var DOCUMENTATION_OPTIONS = {
|
||||
URL_ROOT: '../../',
|
||||
VERSION: '19.7.11',
|
||||
COLLAPSE_INDEX: false,
|
||||
FILE_SUFFIX: '.html',
|
||||
HAS_SOURCE: true
|
||||
};
|
||||
</script>
|
||||
<script type="text/javascript" src="../../_static/jquery.js"></script>
|
||||
<script type="text/javascript" src="../../_static/underscore.js"></script>
|
||||
<script type="text/javascript" src="../../_static/doctools.js"></script>
|
||||
<link rel="top" title="Lorax 19.7.11 documentation" href="../../index.html" />
|
||||
<link rel="up" title="Module code" href="../index.html" />
|
||||
</head>
|
||||
<body>
|
||||
<div class="related">
|
||||
<h3>Navigation</h3>
|
||||
<ul>
|
||||
<li class="right" style="margin-right: 10px">
|
||||
<a href="../../genindex.html" title="General Index"
|
||||
accesskey="I">index</a></li>
|
||||
<li class="right" >
|
||||
<a href="../../py-modindex.html" title="Python Module Index"
|
||||
>modules</a> |</li>
|
||||
<li><a href="../../index.html">Lorax 19.7.11 documentation</a> »</li>
|
||||
<li><a href="../index.html" accesskey="U">Module code</a> »</li>
|
||||
</ul>
|
||||
</div>
|
||||
|
||||
<div class="document">
|
||||
<div class="documentwrapper">
|
||||
<div class="bodywrapper">
|
||||
<div class="body">
|
||||
|
||||
<h1>Source code for composer.http_client</h1><div class="highlight"><pre>
|
||||
<span class="c">#</span>
|
||||
<span class="c"># Copyright (C) 2018 Red Hat, Inc.</span>
|
||||
<span class="c">#</span>
|
||||
<span class="c"># This program is free software; you can redistribute it and/or modify</span>
|
||||
<span class="c"># it under the terms of the GNU General Public License as published by</span>
|
||||
<span class="c"># the Free Software Foundation; either version 2 of the License, or</span>
|
||||
<span class="c"># (at your option) any later version.</span>
|
||||
<span class="c">#</span>
|
||||
<span class="c"># This program is distributed in the hope that it will be useful,</span>
|
||||
<span class="c"># but WITHOUT ANY WARRANTY; without even the implied warranty of</span>
|
||||
<span class="c"># MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the</span>
|
||||
<span class="c"># GNU General Public License for more details.</span>
|
||||
<span class="c">#</span>
|
||||
<span class="c"># You should have received a copy of the GNU General Public License</span>
|
||||
<span class="c"># along with this program. If not, see <http://www.gnu.org/licenses/>.</span>
|
||||
<span class="c">#</span>
|
||||
<span class="kn">import</span> <span class="nn">logging</span>
|
||||
<span class="n">log</span> <span class="o">=</span> <span class="n">logging</span><span class="o">.</span><span class="n">getLogger</span><span class="p">(</span><span class="s">"composer-cli"</span><span class="p">)</span>
|
||||
|
||||
<span class="kn">import</span> <span class="nn">os</span>
|
||||
<span class="kn">import</span> <span class="nn">sys</span>
|
||||
<span class="kn">import</span> <span class="nn">json</span>
|
||||
|
||||
<span class="kn">from</span> <span class="nn">composer.unix_socket</span> <span class="kn">import</span> <span class="n">UnixHTTPConnectionPool</span>
|
||||
|
||||
<div class="viewcode-block" id="api_url"><a class="viewcode-back" href="../../composer.html#composer.http_client.api_url">[docs]</a><span class="k">def</span> <span class="nf">api_url</span><span class="p">(</span><span class="n">api_version</span><span class="p">,</span> <span class="n">url</span><span class="p">):</span>
|
||||
<span class="sd">"""Return the versioned path to the API route</span>
|
||||
|
||||
<span class="sd"> :param api_version: The version of the API to talk to. eg. "0"</span>
|
||||
<span class="sd"> :type api_version: str</span>
|
||||
<span class="sd"> :param url: The API route to talk to</span>
|
||||
<span class="sd"> :type url: str</span>
|
||||
<span class="sd"> :returns: The full url to use for the route and API version</span>
|
||||
<span class="sd"> :rtype: str</span>
|
||||
<span class="sd"> """</span>
|
||||
<span class="k">return</span> <span class="n">os</span><span class="o">.</span><span class="n">path</span><span class="o">.</span><span class="n">normpath</span><span class="p">(</span><span class="s">"/api/v</span><span class="si">%s</span><span class="s">/</span><span class="si">%s</span><span class="s">"</span> <span class="o">%</span> <span class="p">(</span><span class="n">api_version</span><span class="p">,</span> <span class="n">url</span><span class="p">))</span>
|
||||
</div>
|
||||
<div class="viewcode-block" id="get_url_raw"><a class="viewcode-back" href="../../composer.html#composer.http_client.get_url_raw">[docs]</a><span class="k">def</span> <span class="nf">get_url_raw</span><span class="p">(</span><span class="n">socket_path</span><span class="p">,</span> <span class="n">url</span><span class="p">):</span>
|
||||
<span class="sd">"""Return the raw results of a GET request</span>
|
||||
|
||||
<span class="sd"> :param socket_path: Path to the Unix socket to use for API communication</span>
|
||||
<span class="sd"> :type socket_path: str</span>
|
||||
<span class="sd"> :param url: URL to request</span>
|
||||
<span class="sd"> :type url: str</span>
|
||||
<span class="sd"> :returns: The raw response from the server</span>
|
||||
<span class="sd"> :rtype: str</span>
|
||||
<span class="sd"> """</span>
|
||||
<span class="n">http</span> <span class="o">=</span> <span class="n">UnixHTTPConnectionPool</span><span class="p">(</span><span class="n">socket_path</span><span class="p">)</span>
|
||||
<span class="n">r</span> <span class="o">=</span> <span class="n">http</span><span class="o">.</span><span class="n">request</span><span class="p">(</span><span class="s">"GET"</span><span class="p">,</span> <span class="n">url</span><span class="p">)</span>
|
||||
<span class="k">return</span> <span class="n">r</span><span class="o">.</span><span class="n">data</span><span class="o">.</span><span class="n">decode</span><span class="p">(</span><span class="s">'utf-8'</span><span class="p">)</span>
|
||||
</div>
|
||||
<div class="viewcode-block" id="get_url_json"><a class="viewcode-back" href="../../composer.html#composer.http_client.get_url_json">[docs]</a><span class="k">def</span> <span class="nf">get_url_json</span><span class="p">(</span><span class="n">socket_path</span><span class="p">,</span> <span class="n">url</span><span class="p">):</span>
|
||||
<span class="sd">"""Return the JSON results of a GET request</span>
|
||||
|
||||
<span class="sd"> :param socket_path: Path to the Unix socket to use for API communication</span>
|
||||
<span class="sd"> :type socket_path: str</span>
|
||||
<span class="sd"> :param url: URL to request</span>
|
||||
<span class="sd"> :type url: str</span>
|
||||
<span class="sd"> :returns: The json response from the server</span>
|
||||
<span class="sd"> :rtype: dict</span>
|
||||
<span class="sd"> """</span>
|
||||
<span class="n">http</span> <span class="o">=</span> <span class="n">UnixHTTPConnectionPool</span><span class="p">(</span><span class="n">socket_path</span><span class="p">)</span>
|
||||
<span class="n">r</span> <span class="o">=</span> <span class="n">http</span><span class="o">.</span><span class="n">request</span><span class="p">(</span><span class="s">"GET"</span><span class="p">,</span> <span class="n">url</span><span class="p">)</span>
|
||||
<span class="k">return</span> <span class="n">json</span><span class="o">.</span><span class="n">loads</span><span class="p">(</span><span class="n">r</span><span class="o">.</span><span class="n">data</span><span class="o">.</span><span class="n">decode</span><span class="p">(</span><span class="s">'utf-8'</span><span class="p">))</span>
|
||||
</div>
|
||||
<div class="viewcode-block" id="delete_url_json"><a class="viewcode-back" href="../../composer.html#composer.http_client.delete_url_json">[docs]</a><span class="k">def</span> <span class="nf">delete_url_json</span><span class="p">(</span><span class="n">socket_path</span><span class="p">,</span> <span class="n">url</span><span class="p">):</span>
|
||||
<span class="sd">"""Send a DELETE request to the url and return JSON response</span>
|
||||
|
||||
<span class="sd"> :param socket_path: Path to the Unix socket to use for API communication</span>
|
||||
<span class="sd"> :type socket_path: str</span>
|
||||
<span class="sd"> :param url: URL to send DELETE to</span>
|
||||
<span class="sd"> :type url: str</span>
|
||||
<span class="sd"> :returns: The json response from the server</span>
|
||||
<span class="sd"> :rtype: dict</span>
|
||||
<span class="sd"> """</span>
|
||||
<span class="n">http</span> <span class="o">=</span> <span class="n">UnixHTTPConnectionPool</span><span class="p">(</span><span class="n">socket_path</span><span class="p">)</span>
|
||||
<span class="n">r</span> <span class="o">=</span> <span class="n">http</span><span class="o">.</span><span class="n">request</span><span class="p">(</span><span class="s">"DELETE"</span><span class="p">,</span> <span class="n">url</span><span class="p">)</span>
|
||||
<span class="k">return</span> <span class="n">json</span><span class="o">.</span><span class="n">loads</span><span class="p">(</span><span class="n">r</span><span class="o">.</span><span class="n">data</span><span class="o">.</span><span class="n">decode</span><span class="p">(</span><span class="s">"utf-8"</span><span class="p">))</span>
|
||||
</div>
|
||||
<div class="viewcode-block" id="post_url"><a class="viewcode-back" href="../../composer.html#composer.http_client.post_url">[docs]</a><span class="k">def</span> <span class="nf">post_url</span><span class="p">(</span><span class="n">socket_path</span><span class="p">,</span> <span class="n">url</span><span class="p">,</span> <span class="n">body</span><span class="p">):</span>
|
||||
<span class="sd">"""POST raw data to the URL</span>
|
||||
|
||||
<span class="sd"> :param socket_path: Path to the Unix socket to use for API communication</span>
|
||||
<span class="sd"> :type socket_path: str</span>
|
||||
<span class="sd"> :param url: URL to send POST to</span>
|
||||
<span class="sd"> :type url: str</span>
|
||||
<span class="sd"> :param body: The data for the body of the POST</span>
|
||||
<span class="sd"> :type body: str</span>
|
||||
<span class="sd"> :returns: The json response from the server</span>
|
||||
<span class="sd"> :rtype: dict</span>
|
||||
<span class="sd"> """</span>
|
||||
<span class="n">http</span> <span class="o">=</span> <span class="n">UnixHTTPConnectionPool</span><span class="p">(</span><span class="n">socket_path</span><span class="p">)</span>
|
||||
<span class="n">r</span> <span class="o">=</span> <span class="n">http</span><span class="o">.</span><span class="n">request</span><span class="p">(</span><span class="s">"POST"</span><span class="p">,</span> <span class="n">url</span><span class="p">,</span>
|
||||
<span class="n">body</span><span class="o">=</span><span class="n">body</span><span class="o">.</span><span class="n">encode</span><span class="p">(</span><span class="s">"utf-8"</span><span class="p">))</span>
|
||||
<span class="k">return</span> <span class="n">json</span><span class="o">.</span><span class="n">loads</span><span class="p">(</span><span class="n">r</span><span class="o">.</span><span class="n">data</span><span class="o">.</span><span class="n">decode</span><span class="p">(</span><span class="s">"utf-8"</span><span class="p">))</span>
|
||||
</div>
|
||||
<div class="viewcode-block" id="post_url_toml"><a class="viewcode-back" href="../../composer.html#composer.http_client.post_url_toml">[docs]</a><span class="k">def</span> <span class="nf">post_url_toml</span><span class="p">(</span><span class="n">socket_path</span><span class="p">,</span> <span class="n">url</span><span class="p">,</span> <span class="n">body</span><span class="p">):</span>
|
||||
<span class="sd">"""POST a TOML recipe to the URL</span>
|
||||
|
||||
<span class="sd"> :param socket_path: Path to the Unix socket to use for API communication</span>
|
||||
<span class="sd"> :type socket_path: str</span>
|
||||
<span class="sd"> :param url: URL to send POST to</span>
|
||||
<span class="sd"> :type url: str</span>
|
||||
<span class="sd"> :param body: The data for the body of the POST</span>
|
||||
<span class="sd"> :type body: str</span>
|
||||
<span class="sd"> :returns: The json response from the server</span>
|
||||
<span class="sd"> :rtype: dict</span>
|
||||
<span class="sd"> """</span>
|
||||
<span class="n">http</span> <span class="o">=</span> <span class="n">UnixHTTPConnectionPool</span><span class="p">(</span><span class="n">socket_path</span><span class="p">)</span>
|
||||
<span class="n">r</span> <span class="o">=</span> <span class="n">http</span><span class="o">.</span><span class="n">request</span><span class="p">(</span><span class="s">"POST"</span><span class="p">,</span> <span class="n">url</span><span class="p">,</span>
|
||||
<span class="n">body</span><span class="o">=</span><span class="n">body</span><span class="o">.</span><span class="n">encode</span><span class="p">(</span><span class="s">"utf-8"</span><span class="p">),</span>
|
||||
<span class="n">headers</span><span class="o">=</span><span class="p">{</span><span class="s">"Content-Type"</span><span class="p">:</span> <span class="s">"text/x-toml"</span><span class="p">})</span>
|
||||
<span class="k">return</span> <span class="n">json</span><span class="o">.</span><span class="n">loads</span><span class="p">(</span><span class="n">r</span><span class="o">.</span><span class="n">data</span><span class="o">.</span><span class="n">decode</span><span class="p">(</span><span class="s">"utf-8"</span><span class="p">))</span>
|
||||
</div>
|
||||
<div class="viewcode-block" id="post_url_json"><a class="viewcode-back" href="../../composer.html#composer.http_client.post_url_json">[docs]</a><span class="k">def</span> <span class="nf">post_url_json</span><span class="p">(</span><span class="n">socket_path</span><span class="p">,</span> <span class="n">url</span><span class="p">,</span> <span class="n">body</span><span class="p">):</span>
|
||||
<span class="sd">"""POST some JSON data to the URL</span>
|
||||
|
||||
<span class="sd"> :param socket_path: Path to the Unix socket to use for API communication</span>
|
||||
<span class="sd"> :type socket_path: str</span>
|
||||
<span class="sd"> :param url: URL to send POST to</span>
|
||||
<span class="sd"> :type url: str</span>
|
||||
<span class="sd"> :param body: The data for the body of the POST</span>
|
||||
<span class="sd"> :type body: str</span>
|
||||
<span class="sd"> :returns: The json response from the server</span>
|
||||
<span class="sd"> :rtype: dict</span>
|
||||
<span class="sd"> """</span>
|
||||
<span class="n">http</span> <span class="o">=</span> <span class="n">UnixHTTPConnectionPool</span><span class="p">(</span><span class="n">socket_path</span><span class="p">)</span>
|
||||
<span class="n">r</span> <span class="o">=</span> <span class="n">http</span><span class="o">.</span><span class="n">request</span><span class="p">(</span><span class="s">"POST"</span><span class="p">,</span> <span class="n">url</span><span class="p">,</span>
|
||||
<span class="n">body</span><span class="o">=</span><span class="n">body</span><span class="o">.</span><span class="n">encode</span><span class="p">(</span><span class="s">"utf-8"</span><span class="p">),</span>
|
||||
<span class="n">headers</span><span class="o">=</span><span class="p">{</span><span class="s">"Content-Type"</span><span class="p">:</span> <span class="s">"application/json"</span><span class="p">})</span>
|
||||
<span class="k">return</span> <span class="n">json</span><span class="o">.</span><span class="n">loads</span><span class="p">(</span><span class="n">r</span><span class="o">.</span><span class="n">data</span><span class="o">.</span><span class="n">decode</span><span class="p">(</span><span class="s">"utf-8"</span><span class="p">))</span>
|
||||
</div>
|
||||
<div class="viewcode-block" id="get_filename"><a class="viewcode-back" href="../../composer.html#composer.http_client.get_filename">[docs]</a><span class="k">def</span> <span class="nf">get_filename</span><span class="p">(</span><span class="n">headers</span><span class="p">):</span>
|
||||
<span class="sd">"""Get the filename from the response header</span>
|
||||
|
||||
<span class="sd"> :param response: The urllib3 response object</span>
|
||||
<span class="sd"> :type response: Response</span>
|
||||
<span class="sd"> :raises: RuntimeError if it cannot find a filename in the header</span>
|
||||
<span class="sd"> :returns: Filename from content-disposition header</span>
|
||||
<span class="sd"> :rtype: str</span>
|
||||
<span class="sd"> """</span>
|
||||
<span class="n">log</span><span class="o">.</span><span class="n">debug</span><span class="p">(</span><span class="s">"Headers = </span><span class="si">%s</span><span class="s">"</span><span class="p">,</span> <span class="n">headers</span><span class="p">)</span>
|
||||
<span class="k">if</span> <span class="s">"content-disposition"</span> <span class="ow">not</span> <span class="ow">in</span> <span class="n">headers</span><span class="p">:</span>
|
||||
<span class="k">raise</span> <span class="ne">RuntimeError</span><span class="p">(</span><span class="s">"No Content-Disposition header; cannot get filename"</span><span class="p">)</span>
|
||||
|
||||
<span class="k">try</span><span class="p">:</span>
|
||||
<span class="n">k</span><span class="p">,</span> <span class="n">_</span><span class="p">,</span> <span class="n">v</span> <span class="o">=</span> <span class="n">headers</span><span class="p">[</span><span class="s">"content-disposition"</span><span class="p">]</span><span class="o">.</span><span class="n">split</span><span class="p">(</span><span class="s">";"</span><span class="p">)[</span><span class="mi">1</span><span class="p">]</span><span class="o">.</span><span class="n">strip</span><span class="p">()</span><span class="o">.</span><span class="n">partition</span><span class="p">(</span><span class="s">"="</span><span class="p">)</span>
|
||||
<span class="k">if</span> <span class="n">k</span> <span class="o">!=</span> <span class="s">"filename"</span><span class="p">:</span>
|
||||
<span class="k">raise</span> <span class="ne">RuntimeError</span><span class="p">(</span><span class="s">"No filename= found in content-disposition header"</span><span class="p">)</span>
|
||||
<span class="k">except</span> <span class="ne">RuntimeError</span><span class="p">:</span>
|
||||
<span class="k">raise</span>
|
||||
<span class="k">except</span> <span class="ne">Exception</span> <span class="k">as</span> <span class="n">e</span><span class="p">:</span>
|
||||
<span class="k">raise</span> <span class="ne">RuntimeError</span><span class="p">(</span><span class="s">"Error parsing filename from content-disposition header: </span><span class="si">%s</span><span class="s">"</span> <span class="o">%</span> <span class="nb">str</span><span class="p">(</span><span class="n">e</span><span class="p">))</span>
|
||||
|
||||
<span class="k">return</span> <span class="n">os</span><span class="o">.</span><span class="n">path</span><span class="o">.</span><span class="n">basename</span><span class="p">(</span><span class="n">v</span><span class="p">)</span>
|
||||
</div>
|
||||
<div class="viewcode-block" id="download_file"><a class="viewcode-back" href="../../composer.html#composer.http_client.download_file">[docs]</a><span class="k">def</span> <span class="nf">download_file</span><span class="p">(</span><span class="n">socket_path</span><span class="p">,</span> <span class="n">url</span><span class="p">,</span> <span class="n">progress</span><span class="o">=</span><span class="bp">True</span><span class="p">):</span>
|
||||
<span class="sd">"""Download a file, saving it to the CWD with the included filename</span>
|
||||
|
||||
<span class="sd"> :param socket_path: Path to the Unix socket to use for API communication</span>
|
||||
<span class="sd"> :type socket_path: str</span>
|
||||
<span class="sd"> :param url: URL to send POST to</span>
|
||||
<span class="sd"> :type url: str</span>
|
||||
<span class="sd"> """</span>
|
||||
<span class="n">http</span> <span class="o">=</span> <span class="n">UnixHTTPConnectionPool</span><span class="p">(</span><span class="n">socket_path</span><span class="p">)</span>
|
||||
<span class="n">r</span> <span class="o">=</span> <span class="n">http</span><span class="o">.</span><span class="n">request</span><span class="p">(</span><span class="s">"GET"</span><span class="p">,</span> <span class="n">url</span><span class="p">,</span> <span class="n">preload_content</span><span class="o">=</span><span class="bp">False</span><span class="p">)</span>
|
||||
<span class="k">if</span> <span class="n">r</span><span class="o">.</span><span class="n">status</span> <span class="o">==</span> <span class="mi">400</span><span class="p">:</span>
|
||||
<span class="n">err</span> <span class="o">=</span> <span class="n">json</span><span class="o">.</span><span class="n">loads</span><span class="p">(</span><span class="n">r</span><span class="o">.</span><span class="n">data</span><span class="o">.</span><span class="n">decode</span><span class="p">(</span><span class="s">"utf-8"</span><span class="p">))</span>
|
||||
<span class="k">if</span> <span class="ow">not</span> <span class="n">err</span><span class="p">[</span><span class="s">"status"</span><span class="p">]:</span>
|
||||
<span class="k">raise</span> <span class="ne">RuntimeError</span><span class="p">(</span><span class="n">err</span><span class="p">[</span><span class="s">"error"</span><span class="p">][</span><span class="s">"msg"</span><span class="p">])</span>
|
||||
|
||||
<span class="n">filename</span> <span class="o">=</span> <span class="n">get_filename</span><span class="p">(</span><span class="n">r</span><span class="o">.</span><span class="n">headers</span><span class="p">)</span>
|
||||
<span class="k">if</span> <span class="n">os</span><span class="o">.</span><span class="n">path</span><span class="o">.</span><span class="n">exists</span><span class="p">(</span><span class="n">filename</span><span class="p">):</span>
|
||||
<span class="n">msg</span> <span class="o">=</span> <span class="s">"</span><span class="si">%s</span><span class="s"> exists, skipping download"</span> <span class="o">%</span> <span class="n">filename</span>
|
||||
<span class="n">log</span><span class="o">.</span><span class="n">error</span><span class="p">(</span><span class="n">msg</span><span class="p">)</span>
|
||||
<span class="k">raise</span> <span class="ne">RuntimeError</span><span class="p">(</span><span class="n">msg</span><span class="p">)</span>
|
||||
|
||||
<span class="k">with</span> <span class="nb">open</span><span class="p">(</span><span class="n">filename</span><span class="p">,</span> <span class="s">"wb"</span><span class="p">)</span> <span class="k">as</span> <span class="n">f</span><span class="p">:</span>
|
||||
<span class="k">while</span> <span class="bp">True</span><span class="p">:</span>
|
||||
<span class="n">data</span> <span class="o">=</span> <span class="n">r</span><span class="o">.</span><span class="n">read</span><span class="p">(</span><span class="mi">10</span> <span class="o">*</span> <span class="mi">1024</span><span class="o">**</span><span class="mi">2</span><span class="p">)</span>
|
||||
<span class="k">if</span> <span class="ow">not</span> <span class="n">data</span><span class="p">:</span>
|
||||
<span class="k">break</span>
|
||||
<span class="n">f</span><span class="o">.</span><span class="n">write</span><span class="p">(</span><span class="n">data</span><span class="p">)</span>
|
||||
|
||||
<span class="k">if</span> <span class="n">progress</span><span class="p">:</span>
|
||||
<span class="n">data_written</span> <span class="o">=</span> <span class="n">f</span><span class="o">.</span><span class="n">tell</span><span class="p">()</span>
|
||||
<span class="k">if</span> <span class="n">data_written</span> <span class="o">></span> <span class="mi">5</span> <span class="o">*</span> <span class="mi">1024</span><span class="o">**</span><span class="mi">2</span><span class="p">:</span>
|
||||
<span class="n">sys</span><span class="o">.</span><span class="n">stdout</span><span class="o">.</span><span class="n">write</span><span class="p">(</span><span class="s">"</span><span class="si">%s</span><span class="s">: </span><span class="si">%0.2f</span><span class="s"> MB </span><span class="se">\r</span><span class="s">"</span> <span class="o">%</span> <span class="p">(</span><span class="n">filename</span><span class="p">,</span> <span class="n">data_written</span> <span class="o">/</span> <span class="mi">1024</span><span class="o">**</span><span class="mi">2</span><span class="p">))</span>
|
||||
<span class="k">else</span><span class="p">:</span>
|
||||
<span class="n">sys</span><span class="o">.</span><span class="n">stdout</span><span class="o">.</span><span class="n">write</span><span class="p">(</span><span class="s">"</span><span class="si">%s</span><span class="s">: </span><span class="si">%0.2f</span><span class="s"> kB</span><span class="se">\r</span><span class="s">"</span> <span class="o">%</span> <span class="p">(</span><span class="n">filename</span><span class="p">,</span> <span class="n">data_written</span> <span class="o">/</span> <span class="mi">1024</span><span class="p">))</span>
|
||||
<span class="n">sys</span><span class="o">.</span><span class="n">stdout</span><span class="o">.</span><span class="n">flush</span><span class="p">()</span>
|
||||
|
||||
<span class="k">print</span><span class="p">(</span><span class="s">""</span><span class="p">)</span>
|
||||
<span class="n">r</span><span class="o">.</span><span class="n">release_conn</span><span class="p">()</span>
|
||||
|
||||
<span class="k">return</span> <span class="mi">0</span></div>
|
||||
</pre></div>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="sphinxsidebar">
|
||||
<div class="sphinxsidebarwrapper">
|
||||
<div id="searchbox" style="display: none">
|
||||
<h3>Quick search</h3>
|
||||
<form class="search" action="../../search.html" method="get">
|
||||
<input type="text" name="q" />
|
||||
<input type="submit" value="Go" />
|
||||
<input type="hidden" name="check_keywords" value="yes" />
|
||||
<input type="hidden" name="area" value="default" />
|
||||
</form>
|
||||
<p class="searchtip" style="font-size: 90%">
|
||||
Enter search terms or a module, class or function name.
|
||||
</p>
|
||||
</div>
|
||||
<script type="text/javascript">$('#searchbox').show(0);</script>
|
||||
</div>
|
||||
</div>
|
||||
<div class="clearer"></div>
|
||||
</div>
|
||||
<div class="related">
|
||||
<h3>Navigation</h3>
|
||||
<ul>
|
||||
<li class="right" style="margin-right: 10px">
|
||||
<a href="../../genindex.html" title="General Index"
|
||||
>index</a></li>
|
||||
<li class="right" >
|
||||
<a href="../../py-modindex.html" title="Python Module Index"
|
||||
>modules</a> |</li>
|
||||
<li><a href="../../index.html">Lorax 19.7.11 documentation</a> »</li>
|
||||
<li><a href="../index.html" >Module code</a> »</li>
|
||||
</ul>
|
||||
</div>
|
||||
<div class="footer">
|
||||
© Copyright 2018, Red Hat, Inc..
|
||||
Created using <a href="http://sphinx.pocoo.org/">Sphinx</a> 1.1.3.
|
||||
</div>
|
||||
</body>
|
||||
</html>
|
160
lorax-composer/_modules/composer/unix_socket.html
Normal file
160
lorax-composer/_modules/composer/unix_socket.html
Normal file
@ -0,0 +1,160 @@
|
||||
|
||||
|
||||
<!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>composer.unix_socket — Lorax 19.7.11 documentation</title>
|
||||
|
||||
<link rel="stylesheet" href="../../_static/default.css" type="text/css" />
|
||||
<link rel="stylesheet" href="../../_static/pygments.css" type="text/css" />
|
||||
|
||||
<script type="text/javascript">
|
||||
var DOCUMENTATION_OPTIONS = {
|
||||
URL_ROOT: '../../',
|
||||
VERSION: '19.7.11',
|
||||
COLLAPSE_INDEX: false,
|
||||
FILE_SUFFIX: '.html',
|
||||
HAS_SOURCE: true
|
||||
};
|
||||
</script>
|
||||
<script type="text/javascript" src="../../_static/jquery.js"></script>
|
||||
<script type="text/javascript" src="../../_static/underscore.js"></script>
|
||||
<script type="text/javascript" src="../../_static/doctools.js"></script>
|
||||
<link rel="top" title="Lorax 19.7.11 documentation" href="../../index.html" />
|
||||
<link rel="up" title="Module code" href="../index.html" />
|
||||
</head>
|
||||
<body>
|
||||
<div class="related">
|
||||
<h3>Navigation</h3>
|
||||
<ul>
|
||||
<li class="right" style="margin-right: 10px">
|
||||
<a href="../../genindex.html" title="General Index"
|
||||
accesskey="I">index</a></li>
|
||||
<li class="right" >
|
||||
<a href="../../py-modindex.html" title="Python Module Index"
|
||||
>modules</a> |</li>
|
||||
<li><a href="../../index.html">Lorax 19.7.11 documentation</a> »</li>
|
||||
<li><a href="../index.html" accesskey="U">Module code</a> »</li>
|
||||
</ul>
|
||||
</div>
|
||||
|
||||
<div class="document">
|
||||
<div class="documentwrapper">
|
||||
<div class="bodywrapper">
|
||||
<div class="body">
|
||||
|
||||
<h1>Source code for composer.unix_socket</h1><div class="highlight"><pre>
|
||||
<span class="c">#</span>
|
||||
<span class="c"># Copyright (C) 2018 Red Hat, Inc.</span>
|
||||
<span class="c">#</span>
|
||||
<span class="c"># This program is free software; you can redistribute it and/or modify</span>
|
||||
<span class="c"># it under the terms of the GNU General Public License as published by</span>
|
||||
<span class="c"># the Free Software Foundation; either version 2 of the License, or</span>
|
||||
<span class="c"># (at your option) any later version.</span>
|
||||
<span class="c">#</span>
|
||||
<span class="c"># This program is distributed in the hope that it will be useful,</span>
|
||||
<span class="c"># but WITHOUT ANY WARRANTY; without even the implied warranty of</span>
|
||||
<span class="c"># MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the</span>
|
||||
<span class="c"># GNU General Public License for more details.</span>
|
||||
<span class="c">#</span>
|
||||
<span class="c"># You should have received a copy of the GNU General Public License</span>
|
||||
<span class="c"># along with this program. If not, see <http://www.gnu.org/licenses/>.</span>
|
||||
<span class="c">#</span>
|
||||
<span class="kn">import</span> <span class="nn">httplib</span>
|
||||
<span class="kn">import</span> <span class="nn">socket</span>
|
||||
<span class="kn">import</span> <span class="nn">urllib3</span>
|
||||
|
||||
|
||||
<span class="c"># These 2 classes were adapted and simplified for use with just urllib3.</span>
|
||||
<span class="c"># Originally from https://github.com/msabramo/requests-unixsocket/blob/master/requests_unixsocket/adapters.py</span>
|
||||
|
||||
<span class="c"># The following was adapted from some code from docker-py</span>
|
||||
<span class="c"># https://github.com/docker/docker-py/blob/master/docker/transport/unixconn.py</span>
|
||||
<div class="viewcode-block" id="UnixHTTPConnection"><a class="viewcode-back" href="../../composer.html#composer.unix_socket.UnixHTTPConnection">[docs]</a><span class="k">class</span> <span class="nc">UnixHTTPConnection</span><span class="p">(</span><span class="n">httplib</span><span class="o">.</span><span class="n">HTTPConnection</span><span class="p">,</span> <span class="nb">object</span><span class="p">):</span>
|
||||
|
||||
<span class="k">def</span> <span class="nf">__init__</span><span class="p">(</span><span class="bp">self</span><span class="p">,</span> <span class="n">socket_path</span><span class="p">,</span> <span class="n">timeout</span><span class="o">=</span><span class="mi">60</span><span class="p">):</span>
|
||||
<span class="sd">"""Create an HTTP connection to a unix domain socket</span>
|
||||
|
||||
<span class="sd"> :param socket_path: The path to the Unix domain socket</span>
|
||||
<span class="sd"> :param timeout: Number of seconds to timeout the connection</span>
|
||||
<span class="sd"> """</span>
|
||||
<span class="nb">super</span><span class="p">(</span><span class="n">UnixHTTPConnection</span><span class="p">,</span> <span class="bp">self</span><span class="p">)</span><span class="o">.</span><span class="n">__init__</span><span class="p">(</span><span class="s">'localhost'</span><span class="p">,</span> <span class="n">timeout</span><span class="o">=</span><span class="n">timeout</span><span class="p">)</span>
|
||||
<span class="bp">self</span><span class="o">.</span><span class="n">socket_path</span> <span class="o">=</span> <span class="n">socket_path</span>
|
||||
<span class="bp">self</span><span class="o">.</span><span class="n">sock</span> <span class="o">=</span> <span class="bp">None</span>
|
||||
|
||||
<span class="k">def</span> <span class="nf">__del__</span><span class="p">(</span><span class="bp">self</span><span class="p">):</span> <span class="c"># base class does not have d'tor</span>
|
||||
<span class="k">if</span> <span class="bp">self</span><span class="o">.</span><span class="n">sock</span><span class="p">:</span>
|
||||
<span class="bp">self</span><span class="o">.</span><span class="n">sock</span><span class="o">.</span><span class="n">close</span><span class="p">()</span>
|
||||
|
||||
<div class="viewcode-block" id="UnixHTTPConnection.connect"><a class="viewcode-back" href="../../composer.html#composer.unix_socket.UnixHTTPConnection.connect">[docs]</a> <span class="k">def</span> <span class="nf">connect</span><span class="p">(</span><span class="bp">self</span><span class="p">):</span>
|
||||
<span class="n">sock</span> <span class="o">=</span> <span class="n">socket</span><span class="o">.</span><span class="n">socket</span><span class="p">(</span><span class="n">socket</span><span class="o">.</span><span class="n">AF_UNIX</span><span class="p">,</span> <span class="n">socket</span><span class="o">.</span><span class="n">SOCK_STREAM</span><span class="p">)</span>
|
||||
<span class="n">sock</span><span class="o">.</span><span class="n">settimeout</span><span class="p">(</span><span class="bp">self</span><span class="o">.</span><span class="n">timeout</span><span class="p">)</span>
|
||||
<span class="n">sock</span><span class="o">.</span><span class="n">connect</span><span class="p">(</span><span class="bp">self</span><span class="o">.</span><span class="n">socket_path</span><span class="p">)</span>
|
||||
<span class="bp">self</span><span class="o">.</span><span class="n">sock</span> <span class="o">=</span> <span class="n">sock</span>
|
||||
</div></div>
|
||||
<div class="viewcode-block" id="UnixHTTPConnectionPool"><a class="viewcode-back" href="../../composer.html#composer.unix_socket.UnixHTTPConnectionPool">[docs]</a><span class="k">class</span> <span class="nc">UnixHTTPConnectionPool</span><span class="p">(</span><span class="n">urllib3</span><span class="o">.</span><span class="n">connectionpool</span><span class="o">.</span><span class="n">HTTPConnectionPool</span><span class="p">):</span>
|
||||
|
||||
<span class="k">def</span> <span class="nf">__init__</span><span class="p">(</span><span class="bp">self</span><span class="p">,</span> <span class="n">socket_path</span><span class="p">,</span> <span class="n">timeout</span><span class="o">=</span><span class="mi">60</span><span class="p">):</span>
|
||||
<span class="sd">"""Create a connection pool using a Unix domain socket</span>
|
||||
|
||||
<span class="sd"> :param socket_path: The path to the Unix domain socket</span>
|
||||
<span class="sd"> :param timeout: Number of seconds to timeout the connection</span>
|
||||
<span class="sd"> """</span>
|
||||
<span class="nb">super</span><span class="p">(</span><span class="n">UnixHTTPConnectionPool</span><span class="p">,</span> <span class="bp">self</span><span class="p">)</span><span class="o">.</span><span class="n">__init__</span><span class="p">(</span><span class="s">'localhost'</span><span class="p">,</span> <span class="n">timeout</span><span class="o">=</span><span class="n">timeout</span><span class="p">)</span>
|
||||
<span class="bp">self</span><span class="o">.</span><span class="n">socket_path</span> <span class="o">=</span> <span class="n">socket_path</span>
|
||||
|
||||
<span class="k">def</span> <span class="nf">_new_conn</span><span class="p">(</span><span class="bp">self</span><span class="p">):</span>
|
||||
<span class="k">return</span> <span class="n">UnixHTTPConnection</span><span class="p">(</span><span class="bp">self</span><span class="o">.</span><span class="n">socket_path</span><span class="p">,</span> <span class="bp">self</span><span class="o">.</span><span class="n">timeout</span><span class="p">)</span>
|
||||
</div>
|
||||
<span class="k">if</span> <span class="n">__name__</span> <span class="o">==</span> <span class="s">'__main__'</span><span class="p">:</span>
|
||||
<span class="n">http</span> <span class="o">=</span> <span class="n">UnixHTTPConnectionPool</span><span class="p">(</span><span class="s">"/var/run/weldr/api.socket"</span><span class="p">)</span>
|
||||
<span class="n">r</span> <span class="o">=</span> <span class="n">http</span><span class="o">.</span><span class="n">request</span><span class="p">(</span><span class="s">"GET"</span><span class="p">,</span> <span class="s">"/api/v0/recipes/list"</span><span class="p">)</span>
|
||||
<span class="k">print</span><span class="p">(</span><span class="n">r</span><span class="o">.</span><span class="n">data</span><span class="p">)</span>
|
||||
</pre></div>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="sphinxsidebar">
|
||||
<div class="sphinxsidebarwrapper">
|
||||
<div id="searchbox" style="display: none">
|
||||
<h3>Quick search</h3>
|
||||
<form class="search" action="../../search.html" method="get">
|
||||
<input type="text" name="q" />
|
||||
<input type="submit" value="Go" />
|
||||
<input type="hidden" name="check_keywords" value="yes" />
|
||||
<input type="hidden" name="area" value="default" />
|
||||
</form>
|
||||
<p class="searchtip" style="font-size: 90%">
|
||||
Enter search terms or a module, class or function name.
|
||||
</p>
|
||||
</div>
|
||||
<script type="text/javascript">$('#searchbox').show(0);</script>
|
||||
</div>
|
||||
</div>
|
||||
<div class="clearer"></div>
|
||||
</div>
|
||||
<div class="related">
|
||||
<h3>Navigation</h3>
|
||||
<ul>
|
||||
<li class="right" style="margin-right: 10px">
|
||||
<a href="../../genindex.html" title="General Index"
|
||||
>index</a></li>
|
||||
<li class="right" >
|
||||
<a href="../../py-modindex.html" title="Python Module Index"
|
||||
>modules</a> |</li>
|
||||
<li><a href="../../index.html">Lorax 19.7.11 documentation</a> »</li>
|
||||
<li><a href="../index.html" >Module code</a> »</li>
|
||||
</ul>
|
||||
</div>
|
||||
<div class="footer">
|
||||
© Copyright 2018, Red Hat, Inc..
|
||||
Created using <a href="http://sphinx.pocoo.org/">Sphinx</a> 1.1.3.
|
||||
</div>
|
||||
</body>
|
||||
</html>
|
@ -8,7 +8,7 @@
|
||||
<head>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
|
||||
|
||||
<title>Overview: module code — Lorax 19.7.10 documentation</title>
|
||||
<title>Overview: module code — Lorax 19.7.11 documentation</title>
|
||||
|
||||
<link rel="stylesheet" href="../_static/default.css" type="text/css" />
|
||||
<link rel="stylesheet" href="../_static/pygments.css" type="text/css" />
|
||||
@ -16,7 +16,7 @@
|
||||
<script type="text/javascript">
|
||||
var DOCUMENTATION_OPTIONS = {
|
||||
URL_ROOT: '../',
|
||||
VERSION: '19.7.10',
|
||||
VERSION: '19.7.11',
|
||||
COLLAPSE_INDEX: false,
|
||||
FILE_SUFFIX: '.html',
|
||||
HAS_SOURCE: true
|
||||
@ -25,7 +25,7 @@
|
||||
<script type="text/javascript" src="../_static/jquery.js"></script>
|
||||
<script type="text/javascript" src="../_static/underscore.js"></script>
|
||||
<script type="text/javascript" src="../_static/doctools.js"></script>
|
||||
<link rel="top" title="Lorax 19.7.10 documentation" href="../index.html" />
|
||||
<link rel="top" title="Lorax 19.7.11 documentation" href="../index.html" />
|
||||
</head>
|
||||
<body>
|
||||
<div class="related">
|
||||
@ -37,7 +37,7 @@
|
||||
<li class="right" >
|
||||
<a href="../py-modindex.html" title="Python Module Index"
|
||||
>modules</a> |</li>
|
||||
<li><a href="../index.html">Lorax 19.7.10 documentation</a> »</li>
|
||||
<li><a href="../index.html">Lorax 19.7.11 documentation</a> »</li>
|
||||
</ul>
|
||||
</div>
|
||||
|
||||
@ -47,6 +47,15 @@
|
||||
<div class="body">
|
||||
|
||||
<h1>All modules for which code is available</h1>
|
||||
<ul><li><a href="composer/cli.html">composer.cli</a></li>
|
||||
<ul><li><a href="composer/cli/compose.html">composer.cli.compose</a></li>
|
||||
<li><a href="composer/cli/modules.html">composer.cli.modules</a></li>
|
||||
<li><a href="composer/cli/projects.html">composer.cli.projects</a></li>
|
||||
<li><a href="composer/cli/recipes.html">composer.cli.recipes</a></li>
|
||||
<li><a href="composer/cli/utilities.html">composer.cli.utilities</a></li>
|
||||
</ul><li><a href="composer/http_client.html">composer.http_client</a></li>
|
||||
<li><a href="composer/unix_socket.html">composer.unix_socket</a></li>
|
||||
<li><a href="pylorax.html">pylorax</a></li>
|
||||
<ul><li><a href="pylorax/__init__.html">pylorax.__init__</a></li>
|
||||
<li><a href="pylorax/api.html">pylorax.api</a></li>
|
||||
<ul><li><a href="pylorax/api/compose.html">pylorax.api.compose</a></li>
|
||||
@ -73,7 +82,7 @@
|
||||
<li><a href="pylorax/treebuilder.html">pylorax.treebuilder</a></li>
|
||||
<li><a href="pylorax/treeinfo.html">pylorax.treeinfo</a></li>
|
||||
<li><a href="pylorax/yumhelper.html">pylorax.yumhelper</a></li>
|
||||
</ul>
|
||||
</ul></ul>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
@ -106,11 +115,11 @@
|
||||
<li class="right" >
|
||||
<a href="../py-modindex.html" title="Python Module Index"
|
||||
>modules</a> |</li>
|
||||
<li><a href="../index.html">Lorax 19.7.10 documentation</a> »</li>
|
||||
<li><a href="../index.html">Lorax 19.7.11 documentation</a> »</li>
|
||||
</ul>
|
||||
</div>
|
||||
<div class="footer">
|
||||
© Copyright 2017, Red Hat, Inc..
|
||||
© Copyright 2018, Red Hat, Inc..
|
||||
Created using <a href="http://sphinx.pocoo.org/">Sphinx</a> 1.1.3.
|
||||
</div>
|
||||
</body>
|
||||
|
469
lorax-composer/_modules/pylorax.html
Normal file
469
lorax-composer/_modules/pylorax.html
Normal file
@ -0,0 +1,469 @@
|
||||
|
||||
|
||||
<!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>pylorax — Lorax 19.7.11 documentation</title>
|
||||
|
||||
<link rel="stylesheet" href="../_static/default.css" type="text/css" />
|
||||
<link rel="stylesheet" href="../_static/pygments.css" type="text/css" />
|
||||
|
||||
<script type="text/javascript">
|
||||
var DOCUMENTATION_OPTIONS = {
|
||||
URL_ROOT: '../',
|
||||
VERSION: '19.7.11',
|
||||
COLLAPSE_INDEX: false,
|
||||
FILE_SUFFIX: '.html',
|
||||
HAS_SOURCE: true
|
||||
};
|
||||
</script>
|
||||
<script type="text/javascript" src="../_static/jquery.js"></script>
|
||||
<script type="text/javascript" src="../_static/underscore.js"></script>
|
||||
<script type="text/javascript" src="../_static/doctools.js"></script>
|
||||
<link rel="top" title="Lorax 19.7.11 documentation" href="../index.html" />
|
||||
<link rel="up" title="Module code" href="index.html" />
|
||||
</head>
|
||||
<body>
|
||||
<div class="related">
|
||||
<h3>Navigation</h3>
|
||||
<ul>
|
||||
<li class="right" style="margin-right: 10px">
|
||||
<a href="../genindex.html" title="General Index"
|
||||
accesskey="I">index</a></li>
|
||||
<li class="right" >
|
||||
<a href="../py-modindex.html" title="Python Module Index"
|
||||
>modules</a> |</li>
|
||||
<li><a href="../index.html">Lorax 19.7.11 documentation</a> »</li>
|
||||
<li><a href="index.html" accesskey="U">Module code</a> »</li>
|
||||
</ul>
|
||||
</div>
|
||||
|
||||
<div class="document">
|
||||
<div class="documentwrapper">
|
||||
<div class="bodywrapper">
|
||||
<div class="body">
|
||||
|
||||
<h1>Source code for pylorax</h1><div class="highlight"><pre>
|
||||
<span class="c">#</span>
|
||||
<span class="c"># __init__.py</span>
|
||||
<span class="c">#</span>
|
||||
<span class="c"># Copyright (C) 2010 Red Hat, Inc.</span>
|
||||
<span class="c">#</span>
|
||||
<span class="c"># This program is free software; you can redistribute it and/or modify</span>
|
||||
<span class="c"># it under the terms of the GNU General Public License as published by</span>
|
||||
<span class="c"># the Free Software Foundation; either version 2 of the License, or</span>
|
||||
<span class="c"># (at your option) any later version.</span>
|
||||
<span class="c">#</span>
|
||||
<span class="c"># This program is distributed in the hope that it will be useful,</span>
|
||||
<span class="c"># but WITHOUT ANY WARRANTY; without even the implied warranty of</span>
|
||||
<span class="c"># MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the</span>
|
||||
<span class="c"># GNU General Public License for more details.</span>
|
||||
<span class="c">#</span>
|
||||
<span class="c"># You should have received a copy of the GNU General Public License</span>
|
||||
<span class="c"># along with this program. If not, see <http://www.gnu.org/licenses/>.</span>
|
||||
<span class="c">#</span>
|
||||
<span class="c"># Red Hat Author(s): Martin Gracik <mgracik@redhat.com></span>
|
||||
<span class="c"># David Cantrell <dcantrell@redhat.com></span>
|
||||
<span class="c"># Will Woods <wwoods@redhat.com></span>
|
||||
|
||||
<span class="c"># set up logging</span>
|
||||
<span class="kn">import</span> <span class="nn">logging</span>
|
||||
<span class="n">logger</span> <span class="o">=</span> <span class="n">logging</span><span class="o">.</span><span class="n">getLogger</span><span class="p">(</span><span class="s">"pylorax"</span><span class="p">)</span>
|
||||
<span class="n">logger</span><span class="o">.</span><span class="n">addHandler</span><span class="p">(</span><span class="n">logging</span><span class="o">.</span><span class="n">NullHandler</span><span class="p">())</span>
|
||||
|
||||
<span class="kn">import</span> <span class="nn">sys</span>
|
||||
<span class="kn">import</span> <span class="nn">os</span>
|
||||
<span class="kn">import</span> <span class="nn">ConfigParser</span>
|
||||
<span class="kn">import</span> <span class="nn">tempfile</span>
|
||||
<span class="kn">import</span> <span class="nn">locale</span>
|
||||
<span class="kn">from</span> <span class="nn">subprocess</span> <span class="kn">import</span> <span class="n">CalledProcessError</span>
|
||||
<span class="kn">import</span> <span class="nn">selinux</span>
|
||||
|
||||
<span class="kn">from</span> <span class="nn">pylorax.base</span> <span class="kn">import</span> <span class="n">BaseLoraxClass</span><span class="p">,</span> <span class="n">DataHolder</span>
|
||||
<span class="kn">import</span> <span class="nn">pylorax.output</span> <span class="kn">as</span> <span class="nn">output</span>
|
||||
|
||||
<span class="kn">import</span> <span class="nn">yum</span>
|
||||
<span class="kn">import</span> <span class="nn">pylorax.ltmpl</span> <span class="kn">as</span> <span class="nn">ltmpl</span>
|
||||
|
||||
<span class="kn">import</span> <span class="nn">pylorax.imgutils</span> <span class="kn">as</span> <span class="nn">imgutils</span>
|
||||
<span class="kn">from</span> <span class="nn">pylorax.sysutils</span> <span class="kn">import</span> <span class="n">joinpaths</span><span class="p">,</span> <span class="n">linktree</span><span class="p">,</span> <span class="n">remove</span>
|
||||
<span class="kn">from</span> <span class="nn">rpmUtils.arch</span> <span class="kn">import</span> <span class="n">getBaseArch</span>
|
||||
|
||||
<span class="kn">from</span> <span class="nn">pylorax.treebuilder</span> <span class="kn">import</span> <span class="n">RuntimeBuilder</span><span class="p">,</span> <span class="n">TreeBuilder</span>
|
||||
<span class="kn">from</span> <span class="nn">pylorax.buildstamp</span> <span class="kn">import</span> <span class="n">BuildStamp</span>
|
||||
<span class="kn">from</span> <span class="nn">pylorax.treeinfo</span> <span class="kn">import</span> <span class="n">TreeInfo</span>
|
||||
<span class="kn">from</span> <span class="nn">pylorax.discinfo</span> <span class="kn">import</span> <span class="n">DiscInfo</span>
|
||||
<span class="kn">from</span> <span class="nn">pylorax.executils</span> <span class="kn">import</span> <span class="n">runcmd</span><span class="p">,</span> <span class="n">runcmd_output</span>
|
||||
|
||||
<span class="c"># get lorax version</span>
|
||||
<span class="k">try</span><span class="p">:</span>
|
||||
<span class="kn">import</span> <span class="nn">pylorax.version</span>
|
||||
<span class="k">except</span> <span class="ne">ImportError</span><span class="p">:</span>
|
||||
<span class="n">vernum</span> <span class="o">=</span> <span class="s">"devel"</span>
|
||||
<span class="k">else</span><span class="p">:</span>
|
||||
<span class="n">vernum</span> <span class="o">=</span> <span class="n">pylorax</span><span class="o">.</span><span class="n">version</span><span class="o">.</span><span class="n">num</span>
|
||||
|
||||
<span class="c"># List of drivers to remove on ppc64 arch to keep initrd < 32MiB</span>
|
||||
<span class="n">REMOVE_PPC64_DRIVERS</span> <span class="o">=</span> <span class="s">"floppy scsi_debug nouveau radeon cirrus mgag200"</span>
|
||||
<span class="n">REMOVE_PPC64_MODULES</span> <span class="o">=</span> <span class="s">"drm plymouth"</span>
|
||||
|
||||
<div class="viewcode-block" id="ArchData"><a class="viewcode-back" href="../pylorax.html#pylorax.ArchData">[docs]</a><span class="k">class</span> <span class="nc">ArchData</span><span class="p">(</span><span class="n">DataHolder</span><span class="p">):</span>
|
||||
<span class="n">lib64_arches</span> <span class="o">=</span> <span class="p">(</span><span class="s">"x86_64"</span><span class="p">,</span> <span class="s">"ppc64"</span><span class="p">,</span> <span class="s">"ppc64le"</span><span class="p">,</span> <span class="s">"s390x"</span><span class="p">,</span> <span class="s">"ia64"</span><span class="p">,</span> <span class="s">"aarch64"</span><span class="p">)</span>
|
||||
<span class="n">bcj_arch</span> <span class="o">=</span> <span class="nb">dict</span><span class="p">(</span><span class="n">i386</span><span class="o">=</span><span class="s">"x86"</span><span class="p">,</span> <span class="n">x86_64</span><span class="o">=</span><span class="s">"x86"</span><span class="p">,</span>
|
||||
<span class="n">ppc</span><span class="o">=</span><span class="s">"powerpc"</span><span class="p">,</span> <span class="n">ppc64</span><span class="o">=</span><span class="s">"powerpc"</span><span class="p">,</span> <span class="n">ppc64le</span><span class="o">=</span><span class="s">"powerpc"</span><span class="p">,</span>
|
||||
<span class="n">arm</span><span class="o">=</span><span class="s">"arm"</span><span class="p">,</span> <span class="n">armhfp</span><span class="o">=</span><span class="s">"arm"</span><span class="p">)</span>
|
||||
|
||||
<span class="k">def</span> <span class="nf">__init__</span><span class="p">(</span><span class="bp">self</span><span class="p">,</span> <span class="n">buildarch</span><span class="p">):</span>
|
||||
<span class="n">DataHolder</span><span class="o">.</span><span class="n">__init__</span><span class="p">(</span><span class="bp">self</span><span class="p">,</span> <span class="n">buildarch</span><span class="o">=</span><span class="n">buildarch</span><span class="p">)</span>
|
||||
<span class="bp">self</span><span class="o">.</span><span class="n">basearch</span> <span class="o">=</span> <span class="n">getBaseArch</span><span class="p">(</span><span class="n">buildarch</span><span class="p">)</span>
|
||||
<span class="bp">self</span><span class="o">.</span><span class="n">libdir</span> <span class="o">=</span> <span class="s">"lib64"</span> <span class="k">if</span> <span class="bp">self</span><span class="o">.</span><span class="n">basearch</span> <span class="ow">in</span> <span class="bp">self</span><span class="o">.</span><span class="n">lib64_arches</span> <span class="k">else</span> <span class="s">"lib"</span>
|
||||
<span class="bp">self</span><span class="o">.</span><span class="n">bcj</span> <span class="o">=</span> <span class="bp">self</span><span class="o">.</span><span class="n">bcj_arch</span><span class="o">.</span><span class="n">get</span><span class="p">(</span><span class="bp">self</span><span class="o">.</span><span class="n">basearch</span><span class="p">)</span>
|
||||
</div>
|
||||
<div class="viewcode-block" id="Lorax"><a class="viewcode-back" href="../pylorax.html#pylorax.Lorax">[docs]</a><span class="k">class</span> <span class="nc">Lorax</span><span class="p">(</span><span class="n">BaseLoraxClass</span><span class="p">):</span>
|
||||
|
||||
<span class="k">def</span> <span class="nf">__init__</span><span class="p">(</span><span class="bp">self</span><span class="p">):</span>
|
||||
<span class="n">BaseLoraxClass</span><span class="o">.</span><span class="n">__init__</span><span class="p">(</span><span class="bp">self</span><span class="p">)</span>
|
||||
<span class="bp">self</span><span class="o">.</span><span class="n">_configured</span> <span class="o">=</span> <span class="bp">False</span>
|
||||
<span class="bp">self</span><span class="o">.</span><span class="n">conf</span> <span class="o">=</span> <span class="bp">None</span>
|
||||
<span class="bp">self</span><span class="o">.</span><span class="n">outputdir</span> <span class="o">=</span> <span class="bp">None</span>
|
||||
<span class="bp">self</span><span class="o">.</span><span class="n">workdir</span> <span class="o">=</span> <span class="bp">None</span>
|
||||
<span class="bp">self</span><span class="o">.</span><span class="n">inroot</span> <span class="o">=</span> <span class="bp">None</span>
|
||||
<span class="bp">self</span><span class="o">.</span><span class="n">arch</span> <span class="o">=</span> <span class="bp">None</span>
|
||||
<span class="bp">self</span><span class="o">.</span><span class="n">product</span> <span class="o">=</span> <span class="bp">None</span>
|
||||
<span class="bp">self</span><span class="o">.</span><span class="n">debug</span> <span class="o">=</span> <span class="bp">False</span>
|
||||
|
||||
<span class="c"># set locale to C</span>
|
||||
<span class="n">locale</span><span class="o">.</span><span class="n">setlocale</span><span class="p">(</span><span class="n">locale</span><span class="o">.</span><span class="n">LC_ALL</span><span class="p">,</span> <span class="s">'C'</span><span class="p">)</span>
|
||||
|
||||
<div class="viewcode-block" id="Lorax.configure"><a class="viewcode-back" href="../pylorax.html#pylorax.Lorax.configure">[docs]</a> <span class="k">def</span> <span class="nf">configure</span><span class="p">(</span><span class="bp">self</span><span class="p">,</span> <span class="n">conf_file</span><span class="o">=</span><span class="s">"/etc/lorax/lorax.conf"</span><span class="p">):</span>
|
||||
<span class="bp">self</span><span class="o">.</span><span class="n">conf</span> <span class="o">=</span> <span class="n">ConfigParser</span><span class="o">.</span><span class="n">SafeConfigParser</span><span class="p">()</span>
|
||||
|
||||
<span class="c"># set defaults</span>
|
||||
<span class="bp">self</span><span class="o">.</span><span class="n">conf</span><span class="o">.</span><span class="n">add_section</span><span class="p">(</span><span class="s">"lorax"</span><span class="p">)</span>
|
||||
<span class="bp">self</span><span class="o">.</span><span class="n">conf</span><span class="o">.</span><span class="n">set</span><span class="p">(</span><span class="s">"lorax"</span><span class="p">,</span> <span class="s">"debug"</span><span class="p">,</span> <span class="s">"1"</span><span class="p">)</span>
|
||||
<span class="bp">self</span><span class="o">.</span><span class="n">conf</span><span class="o">.</span><span class="n">set</span><span class="p">(</span><span class="s">"lorax"</span><span class="p">,</span> <span class="s">"sharedir"</span><span class="p">,</span> <span class="s">"/usr/share/lorax"</span><span class="p">)</span>
|
||||
|
||||
<span class="bp">self</span><span class="o">.</span><span class="n">conf</span><span class="o">.</span><span class="n">add_section</span><span class="p">(</span><span class="s">"output"</span><span class="p">)</span>
|
||||
<span class="bp">self</span><span class="o">.</span><span class="n">conf</span><span class="o">.</span><span class="n">set</span><span class="p">(</span><span class="s">"output"</span><span class="p">,</span> <span class="s">"colors"</span><span class="p">,</span> <span class="s">"1"</span><span class="p">)</span>
|
||||
<span class="bp">self</span><span class="o">.</span><span class="n">conf</span><span class="o">.</span><span class="n">set</span><span class="p">(</span><span class="s">"output"</span><span class="p">,</span> <span class="s">"encoding"</span><span class="p">,</span> <span class="s">"utf-8"</span><span class="p">)</span>
|
||||
<span class="bp">self</span><span class="o">.</span><span class="n">conf</span><span class="o">.</span><span class="n">set</span><span class="p">(</span><span class="s">"output"</span><span class="p">,</span> <span class="s">"ignorelist"</span><span class="p">,</span> <span class="s">"/usr/share/lorax/ignorelist"</span><span class="p">)</span>
|
||||
|
||||
<span class="bp">self</span><span class="o">.</span><span class="n">conf</span><span class="o">.</span><span class="n">add_section</span><span class="p">(</span><span class="s">"templates"</span><span class="p">)</span>
|
||||
<span class="bp">self</span><span class="o">.</span><span class="n">conf</span><span class="o">.</span><span class="n">set</span><span class="p">(</span><span class="s">"templates"</span><span class="p">,</span> <span class="s">"ramdisk"</span><span class="p">,</span> <span class="s">"ramdisk.ltmpl"</span><span class="p">)</span>
|
||||
|
||||
<span class="bp">self</span><span class="o">.</span><span class="n">conf</span><span class="o">.</span><span class="n">add_section</span><span class="p">(</span><span class="s">"yum"</span><span class="p">)</span>
|
||||
<span class="bp">self</span><span class="o">.</span><span class="n">conf</span><span class="o">.</span><span class="n">set</span><span class="p">(</span><span class="s">"yum"</span><span class="p">,</span> <span class="s">"skipbroken"</span><span class="p">,</span> <span class="s">"0"</span><span class="p">)</span>
|
||||
|
||||
<span class="bp">self</span><span class="o">.</span><span class="n">conf</span><span class="o">.</span><span class="n">add_section</span><span class="p">(</span><span class="s">"compression"</span><span class="p">)</span>
|
||||
<span class="bp">self</span><span class="o">.</span><span class="n">conf</span><span class="o">.</span><span class="n">set</span><span class="p">(</span><span class="s">"compression"</span><span class="p">,</span> <span class="s">"type"</span><span class="p">,</span> <span class="s">"xz"</span><span class="p">)</span>
|
||||
<span class="bp">self</span><span class="o">.</span><span class="n">conf</span><span class="o">.</span><span class="n">set</span><span class="p">(</span><span class="s">"compression"</span><span class="p">,</span> <span class="s">"args"</span><span class="p">,</span> <span class="s">""</span><span class="p">)</span>
|
||||
<span class="bp">self</span><span class="o">.</span><span class="n">conf</span><span class="o">.</span><span class="n">set</span><span class="p">(</span><span class="s">"compression"</span><span class="p">,</span> <span class="s">"bcj"</span><span class="p">,</span> <span class="s">"on"</span><span class="p">)</span>
|
||||
|
||||
<span class="c"># read the config file</span>
|
||||
<span class="k">if</span> <span class="n">os</span><span class="o">.</span><span class="n">path</span><span class="o">.</span><span class="n">isfile</span><span class="p">(</span><span class="n">conf_file</span><span class="p">):</span>
|
||||
<span class="bp">self</span><span class="o">.</span><span class="n">conf</span><span class="o">.</span><span class="n">read</span><span class="p">(</span><span class="n">conf_file</span><span class="p">)</span>
|
||||
|
||||
<span class="c"># set up the output</span>
|
||||
<span class="bp">self</span><span class="o">.</span><span class="n">debug</span> <span class="o">=</span> <span class="bp">self</span><span class="o">.</span><span class="n">conf</span><span class="o">.</span><span class="n">getboolean</span><span class="p">(</span><span class="s">"lorax"</span><span class="p">,</span> <span class="s">"debug"</span><span class="p">)</span>
|
||||
<span class="n">output_level</span> <span class="o">=</span> <span class="n">output</span><span class="o">.</span><span class="n">DEBUG</span> <span class="k">if</span> <span class="bp">self</span><span class="o">.</span><span class="n">debug</span> <span class="k">else</span> <span class="n">output</span><span class="o">.</span><span class="n">INFO</span>
|
||||
|
||||
<span class="n">colors</span> <span class="o">=</span> <span class="bp">self</span><span class="o">.</span><span class="n">conf</span><span class="o">.</span><span class="n">getboolean</span><span class="p">(</span><span class="s">"output"</span><span class="p">,</span> <span class="s">"colors"</span><span class="p">)</span>
|
||||
<span class="n">encoding</span> <span class="o">=</span> <span class="bp">self</span><span class="o">.</span><span class="n">conf</span><span class="o">.</span><span class="n">get</span><span class="p">(</span><span class="s">"output"</span><span class="p">,</span> <span class="s">"encoding"</span><span class="p">)</span>
|
||||
|
||||
<span class="bp">self</span><span class="o">.</span><span class="n">output</span><span class="o">.</span><span class="n">basic_config</span><span class="p">(</span><span class="n">output_level</span><span class="o">=</span><span class="n">output_level</span><span class="p">,</span>
|
||||
<span class="n">colors</span><span class="o">=</span><span class="n">colors</span><span class="p">,</span> <span class="n">encoding</span><span class="o">=</span><span class="n">encoding</span><span class="p">)</span>
|
||||
|
||||
<span class="n">ignorelist</span> <span class="o">=</span> <span class="bp">self</span><span class="o">.</span><span class="n">conf</span><span class="o">.</span><span class="n">get</span><span class="p">(</span><span class="s">"output"</span><span class="p">,</span> <span class="s">"ignorelist"</span><span class="p">)</span>
|
||||
<span class="k">if</span> <span class="n">os</span><span class="o">.</span><span class="n">path</span><span class="o">.</span><span class="n">isfile</span><span class="p">(</span><span class="n">ignorelist</span><span class="p">):</span>
|
||||
<span class="k">with</span> <span class="nb">open</span><span class="p">(</span><span class="n">ignorelist</span><span class="p">,</span> <span class="s">"r"</span><span class="p">)</span> <span class="k">as</span> <span class="n">fobj</span><span class="p">:</span>
|
||||
<span class="k">for</span> <span class="n">line</span> <span class="ow">in</span> <span class="n">fobj</span><span class="p">:</span>
|
||||
<span class="n">line</span> <span class="o">=</span> <span class="n">line</span><span class="o">.</span><span class="n">strip</span><span class="p">()</span>
|
||||
<span class="k">if</span> <span class="n">line</span> <span class="ow">and</span> <span class="ow">not</span> <span class="n">line</span><span class="o">.</span><span class="n">startswith</span><span class="p">(</span><span class="s">"#"</span><span class="p">):</span>
|
||||
<span class="bp">self</span><span class="o">.</span><span class="n">output</span><span class="o">.</span><span class="n">ignore</span><span class="p">(</span><span class="n">line</span><span class="p">)</span>
|
||||
|
||||
<span class="c"># cron does not have sbin in PATH,</span>
|
||||
<span class="c"># so we have to add it ourselves</span>
|
||||
<span class="n">os</span><span class="o">.</span><span class="n">environ</span><span class="p">[</span><span class="s">"PATH"</span><span class="p">]</span> <span class="o">=</span> <span class="s">"{0}:/sbin:/usr/sbin"</span><span class="o">.</span><span class="n">format</span><span class="p">(</span><span class="n">os</span><span class="o">.</span><span class="n">environ</span><span class="p">[</span><span class="s">"PATH"</span><span class="p">])</span>
|
||||
|
||||
<span class="c"># remove some environmental variables that can cause problems with package scripts</span>
|
||||
<span class="n">env_remove</span> <span class="o">=</span> <span class="p">(</span><span class="s">'DISPLAY'</span><span class="p">,</span> <span class="s">'DBUS_SESSION_BUS_ADDRESS'</span><span class="p">)</span>
|
||||
<span class="n">_</span> <span class="o">=</span> <span class="p">[</span><span class="n">os</span><span class="o">.</span><span class="n">environ</span><span class="o">.</span><span class="n">pop</span><span class="p">(</span><span class="n">k</span><span class="p">)</span> <span class="k">for</span> <span class="n">k</span> <span class="ow">in</span> <span class="n">env_remove</span> <span class="k">if</span> <span class="n">k</span> <span class="ow">in</span> <span class="n">os</span><span class="o">.</span><span class="n">environ</span><span class="p">]</span>
|
||||
|
||||
<span class="bp">self</span><span class="o">.</span><span class="n">_configured</span> <span class="o">=</span> <span class="bp">True</span>
|
||||
</div>
|
||||
<div class="viewcode-block" id="Lorax.init_stream_logging"><a class="viewcode-back" href="../pylorax.html#pylorax.Lorax.init_stream_logging">[docs]</a> <span class="k">def</span> <span class="nf">init_stream_logging</span><span class="p">(</span><span class="bp">self</span><span class="p">):</span>
|
||||
<span class="n">sh</span> <span class="o">=</span> <span class="n">logging</span><span class="o">.</span><span class="n">StreamHandler</span><span class="p">()</span>
|
||||
<span class="n">sh</span><span class="o">.</span><span class="n">setLevel</span><span class="p">(</span><span class="n">logging</span><span class="o">.</span><span class="n">INFO</span><span class="p">)</span>
|
||||
<span class="n">logger</span><span class="o">.</span><span class="n">addHandler</span><span class="p">(</span><span class="n">sh</span><span class="p">)</span>
|
||||
</div>
|
||||
<div class="viewcode-block" id="Lorax.init_file_logging"><a class="viewcode-back" href="../pylorax.html#pylorax.Lorax.init_file_logging">[docs]</a> <span class="k">def</span> <span class="nf">init_file_logging</span><span class="p">(</span><span class="bp">self</span><span class="p">,</span> <span class="n">logdir</span><span class="p">,</span> <span class="n">logname</span><span class="o">=</span><span class="s">"pylorax.log"</span><span class="p">):</span>
|
||||
<span class="n">fh</span> <span class="o">=</span> <span class="n">logging</span><span class="o">.</span><span class="n">FileHandler</span><span class="p">(</span><span class="n">filename</span><span class="o">=</span><span class="n">joinpaths</span><span class="p">(</span><span class="n">logdir</span><span class="p">,</span> <span class="n">logname</span><span class="p">),</span> <span class="n">mode</span><span class="o">=</span><span class="s">"w"</span><span class="p">)</span>
|
||||
<span class="n">fh</span><span class="o">.</span><span class="n">setLevel</span><span class="p">(</span><span class="n">logging</span><span class="o">.</span><span class="n">DEBUG</span><span class="p">)</span>
|
||||
<span class="n">logger</span><span class="o">.</span><span class="n">addHandler</span><span class="p">(</span><span class="n">fh</span><span class="p">)</span>
|
||||
</div>
|
||||
<div class="viewcode-block" id="Lorax.run"><a class="viewcode-back" href="../pylorax.html#pylorax.Lorax.run">[docs]</a> <span class="k">def</span> <span class="nf">run</span><span class="p">(</span><span class="bp">self</span><span class="p">,</span> <span class="n">ybo</span><span class="p">,</span> <span class="n">product</span><span class="p">,</span> <span class="n">version</span><span class="p">,</span> <span class="n">release</span><span class="p">,</span> <span class="n">variant</span><span class="o">=</span><span class="s">""</span><span class="p">,</span> <span class="n">bugurl</span><span class="o">=</span><span class="s">""</span><span class="p">,</span>
|
||||
<span class="n">isfinal</span><span class="o">=</span><span class="bp">False</span><span class="p">,</span> <span class="n">workdir</span><span class="o">=</span><span class="bp">None</span><span class="p">,</span> <span class="n">outputdir</span><span class="o">=</span><span class="bp">None</span><span class="p">,</span> <span class="n">buildarch</span><span class="o">=</span><span class="bp">None</span><span class="p">,</span> <span class="n">volid</span><span class="o">=</span><span class="bp">None</span><span class="p">,</span>
|
||||
<span class="n">domacboot</span><span class="o">=</span><span class="bp">False</span><span class="p">,</span> <span class="n">doupgrade</span><span class="o">=</span><span class="bp">True</span><span class="p">,</span> <span class="n">remove_temp</span><span class="o">=</span><span class="bp">False</span><span class="p">,</span>
|
||||
<span class="n">installpkgs</span><span class="o">=</span><span class="bp">None</span><span class="p">,</span>
|
||||
<span class="n">size</span><span class="o">=</span><span class="mi">2</span><span class="p">,</span>
|
||||
<span class="n">add_templates</span><span class="o">=</span><span class="bp">None</span><span class="p">,</span>
|
||||
<span class="n">add_template_vars</span><span class="o">=</span><span class="bp">None</span><span class="p">,</span>
|
||||
<span class="n">add_arch_templates</span><span class="o">=</span><span class="bp">None</span><span class="p">,</span>
|
||||
<span class="n">add_arch_template_vars</span><span class="o">=</span><span class="bp">None</span><span class="p">,</span>
|
||||
<span class="n">template_tempdir</span><span class="o">=</span><span class="bp">None</span><span class="p">):</span>
|
||||
|
||||
<span class="k">assert</span> <span class="bp">self</span><span class="o">.</span><span class="n">_configured</span>
|
||||
|
||||
<span class="n">installpkgs</span> <span class="o">=</span> <span class="n">installpkgs</span> <span class="ow">or</span> <span class="p">[]</span>
|
||||
|
||||
<span class="k">if</span> <span class="n">domacboot</span><span class="p">:</span>
|
||||
<span class="k">try</span><span class="p">:</span>
|
||||
<span class="n">runcmd</span><span class="p">([</span><span class="s">"rpm"</span><span class="p">,</span> <span class="s">"-q"</span><span class="p">,</span> <span class="s">"hfsplus-tools"</span><span class="p">])</span>
|
||||
<span class="k">except</span> <span class="n">CalledProcessError</span><span class="p">:</span>
|
||||
<span class="n">logger</span><span class="o">.</span><span class="n">critical</span><span class="p">(</span><span class="s">"you need to install hfsplus-tools to create mac images"</span><span class="p">)</span>
|
||||
<span class="n">sys</span><span class="o">.</span><span class="n">exit</span><span class="p">(</span><span class="mi">1</span><span class="p">)</span>
|
||||
|
||||
<span class="c"># set up work directory</span>
|
||||
<span class="bp">self</span><span class="o">.</span><span class="n">workdir</span> <span class="o">=</span> <span class="n">workdir</span> <span class="ow">or</span> <span class="n">tempfile</span><span class="o">.</span><span class="n">mkdtemp</span><span class="p">(</span><span class="n">prefix</span><span class="o">=</span><span class="s">"pylorax.work."</span><span class="p">)</span>
|
||||
<span class="k">if</span> <span class="ow">not</span> <span class="n">os</span><span class="o">.</span><span class="n">path</span><span class="o">.</span><span class="n">isdir</span><span class="p">(</span><span class="bp">self</span><span class="o">.</span><span class="n">workdir</span><span class="p">):</span>
|
||||
<span class="n">os</span><span class="o">.</span><span class="n">makedirs</span><span class="p">(</span><span class="bp">self</span><span class="o">.</span><span class="n">workdir</span><span class="p">)</span>
|
||||
|
||||
<span class="c"># set up log directory</span>
|
||||
<span class="n">logdir</span> <span class="o">=</span> <span class="s">'/var/log/lorax'</span>
|
||||
<span class="k">if</span> <span class="ow">not</span> <span class="n">os</span><span class="o">.</span><span class="n">path</span><span class="o">.</span><span class="n">isdir</span><span class="p">(</span><span class="n">logdir</span><span class="p">):</span>
|
||||
<span class="n">os</span><span class="o">.</span><span class="n">makedirs</span><span class="p">(</span><span class="n">logdir</span><span class="p">)</span>
|
||||
|
||||
<span class="bp">self</span><span class="o">.</span><span class="n">init_stream_logging</span><span class="p">()</span>
|
||||
<span class="bp">self</span><span class="o">.</span><span class="n">init_file_logging</span><span class="p">(</span><span class="n">logdir</span><span class="p">)</span>
|
||||
|
||||
<span class="n">logger</span><span class="o">.</span><span class="n">debug</span><span class="p">(</span><span class="s">"version is </span><span class="si">%s</span><span class="s">"</span><span class="p">,</span> <span class="n">vernum</span><span class="p">)</span>
|
||||
<span class="n">logger</span><span class="o">.</span><span class="n">debug</span><span class="p">(</span><span class="s">"using work directory </span><span class="si">%s</span><span class="s">"</span><span class="p">,</span> <span class="bp">self</span><span class="o">.</span><span class="n">workdir</span><span class="p">)</span>
|
||||
<span class="n">logger</span><span class="o">.</span><span class="n">debug</span><span class="p">(</span><span class="s">"using log directory </span><span class="si">%s</span><span class="s">"</span><span class="p">,</span> <span class="n">logdir</span><span class="p">)</span>
|
||||
|
||||
<span class="c"># set up output directory</span>
|
||||
<span class="bp">self</span><span class="o">.</span><span class="n">outputdir</span> <span class="o">=</span> <span class="n">outputdir</span> <span class="ow">or</span> <span class="n">tempfile</span><span class="o">.</span><span class="n">mkdtemp</span><span class="p">(</span><span class="n">prefix</span><span class="o">=</span><span class="s">"pylorax.out."</span><span class="p">)</span>
|
||||
<span class="k">if</span> <span class="ow">not</span> <span class="n">os</span><span class="o">.</span><span class="n">path</span><span class="o">.</span><span class="n">isdir</span><span class="p">(</span><span class="bp">self</span><span class="o">.</span><span class="n">outputdir</span><span class="p">):</span>
|
||||
<span class="n">os</span><span class="o">.</span><span class="n">makedirs</span><span class="p">(</span><span class="bp">self</span><span class="o">.</span><span class="n">outputdir</span><span class="p">)</span>
|
||||
<span class="n">logger</span><span class="o">.</span><span class="n">debug</span><span class="p">(</span><span class="s">"using output directory </span><span class="si">%s</span><span class="s">"</span><span class="p">,</span> <span class="bp">self</span><span class="o">.</span><span class="n">outputdir</span><span class="p">)</span>
|
||||
|
||||
<span class="c"># do we have root privileges?</span>
|
||||
<span class="n">logger</span><span class="o">.</span><span class="n">info</span><span class="p">(</span><span class="s">"checking for root privileges"</span><span class="p">)</span>
|
||||
<span class="k">if</span> <span class="ow">not</span> <span class="n">os</span><span class="o">.</span><span class="n">geteuid</span><span class="p">()</span> <span class="o">==</span> <span class="mi">0</span><span class="p">:</span>
|
||||
<span class="n">logger</span><span class="o">.</span><span class="n">critical</span><span class="p">(</span><span class="s">"no root privileges"</span><span class="p">)</span>
|
||||
<span class="n">sys</span><span class="o">.</span><span class="n">exit</span><span class="p">(</span><span class="mi">1</span><span class="p">)</span>
|
||||
|
||||
<span class="c"># is selinux disabled?</span>
|
||||
<span class="c"># With selinux in enforcing mode the rpcbind package required for</span>
|
||||
<span class="c"># dracut nfs module, which is in turn required by anaconda module,</span>
|
||||
<span class="c"># will not get installed, because it's preinstall scriptlet fails,</span>
|
||||
<span class="c"># resulting in an incomplete initial ramdisk image.</span>
|
||||
<span class="c"># The reason is that the scriptlet runs tools from the shadow-utils</span>
|
||||
<span class="c"># package in chroot, particularly groupadd and useradd to add the</span>
|
||||
<span class="c"># required rpc group and rpc user. This operation fails, because</span>
|
||||
<span class="c"># the selinux context on files in the chroot, that the shadow-utils</span>
|
||||
<span class="c"># tools need to access (/etc/group, /etc/passwd, /etc/shadow etc.),</span>
|
||||
<span class="c"># is wrong and selinux therefore disallows access to these files.</span>
|
||||
<span class="n">logger</span><span class="o">.</span><span class="n">info</span><span class="p">(</span><span class="s">"checking the selinux mode"</span><span class="p">)</span>
|
||||
<span class="k">if</span> <span class="n">selinux</span><span class="o">.</span><span class="n">is_selinux_enabled</span><span class="p">()</span> <span class="ow">and</span> <span class="n">selinux</span><span class="o">.</span><span class="n">security_getenforce</span><span class="p">():</span>
|
||||
<span class="n">logger</span><span class="o">.</span><span class="n">critical</span><span class="p">(</span><span class="s">"selinux must be disabled or in Permissive mode"</span><span class="p">)</span>
|
||||
<span class="n">sys</span><span class="o">.</span><span class="n">exit</span><span class="p">(</span><span class="mi">1</span><span class="p">)</span>
|
||||
|
||||
<span class="c"># do we have a proper yum base object?</span>
|
||||
<span class="n">logger</span><span class="o">.</span><span class="n">info</span><span class="p">(</span><span class="s">"checking yum base object"</span><span class="p">)</span>
|
||||
<span class="k">if</span> <span class="ow">not</span> <span class="nb">isinstance</span><span class="p">(</span><span class="n">ybo</span><span class="p">,</span> <span class="n">yum</span><span class="o">.</span><span class="n">YumBase</span><span class="p">):</span>
|
||||
<span class="n">logger</span><span class="o">.</span><span class="n">critical</span><span class="p">(</span><span class="s">"no yum base object"</span><span class="p">)</span>
|
||||
<span class="n">sys</span><span class="o">.</span><span class="n">exit</span><span class="p">(</span><span class="mi">1</span><span class="p">)</span>
|
||||
<span class="bp">self</span><span class="o">.</span><span class="n">inroot</span> <span class="o">=</span> <span class="n">ybo</span><span class="o">.</span><span class="n">conf</span><span class="o">.</span><span class="n">installroot</span>
|
||||
<span class="n">logger</span><span class="o">.</span><span class="n">debug</span><span class="p">(</span><span class="s">"using install root: </span><span class="si">%s</span><span class="s">"</span><span class="p">,</span> <span class="bp">self</span><span class="o">.</span><span class="n">inroot</span><span class="p">)</span>
|
||||
|
||||
<span class="k">if</span> <span class="ow">not</span> <span class="n">buildarch</span><span class="p">:</span>
|
||||
<span class="n">buildarch</span> <span class="o">=</span> <span class="n">get_buildarch</span><span class="p">(</span><span class="n">ybo</span><span class="p">)</span>
|
||||
|
||||
<span class="n">logger</span><span class="o">.</span><span class="n">info</span><span class="p">(</span><span class="s">"setting up build architecture"</span><span class="p">)</span>
|
||||
<span class="bp">self</span><span class="o">.</span><span class="n">arch</span> <span class="o">=</span> <span class="n">ArchData</span><span class="p">(</span><span class="n">buildarch</span><span class="p">)</span>
|
||||
<span class="k">for</span> <span class="n">attr</span> <span class="ow">in</span> <span class="p">(</span><span class="s">'buildarch'</span><span class="p">,</span> <span class="s">'basearch'</span><span class="p">,</span> <span class="s">'libdir'</span><span class="p">):</span>
|
||||
<span class="n">logger</span><span class="o">.</span><span class="n">debug</span><span class="p">(</span><span class="s">"self.arch.</span><span class="si">%s</span><span class="s"> = </span><span class="si">%s</span><span class="s">"</span><span class="p">,</span> <span class="n">attr</span><span class="p">,</span> <span class="nb">getattr</span><span class="p">(</span><span class="bp">self</span><span class="o">.</span><span class="n">arch</span><span class="p">,</span><span class="n">attr</span><span class="p">))</span>
|
||||
|
||||
<span class="n">logger</span><span class="o">.</span><span class="n">info</span><span class="p">(</span><span class="s">"setting up build parameters"</span><span class="p">)</span>
|
||||
<span class="n">product</span> <span class="o">=</span> <span class="n">DataHolder</span><span class="p">(</span><span class="n">name</span><span class="o">=</span><span class="n">product</span><span class="p">,</span> <span class="n">version</span><span class="o">=</span><span class="n">version</span><span class="p">,</span> <span class="n">release</span><span class="o">=</span><span class="n">release</span><span class="p">,</span>
|
||||
<span class="n">variant</span><span class="o">=</span><span class="n">variant</span><span class="p">,</span> <span class="n">bugurl</span><span class="o">=</span><span class="n">bugurl</span><span class="p">,</span> <span class="n">isfinal</span><span class="o">=</span><span class="n">isfinal</span><span class="p">)</span>
|
||||
<span class="bp">self</span><span class="o">.</span><span class="n">product</span> <span class="o">=</span> <span class="n">product</span>
|
||||
<span class="n">logger</span><span class="o">.</span><span class="n">debug</span><span class="p">(</span><span class="s">"product data: </span><span class="si">%s</span><span class="s">"</span><span class="p">,</span> <span class="n">product</span><span class="p">)</span>
|
||||
|
||||
<span class="c"># NOTE: if you change isolabel, you need to change pungi to match, or</span>
|
||||
<span class="c"># the pungi images won't boot.</span>
|
||||
<span class="n">isolabel</span> <span class="o">=</span> <span class="n">volid</span> <span class="ow">or</span> <span class="s">"</span><span class="si">%s</span><span class="s"> </span><span class="si">%s</span><span class="s"> </span><span class="si">%s</span><span class="s">"</span> <span class="o">%</span> <span class="p">(</span><span class="bp">self</span><span class="o">.</span><span class="n">product</span><span class="o">.</span><span class="n">name</span><span class="p">,</span> <span class="bp">self</span><span class="o">.</span><span class="n">product</span><span class="o">.</span><span class="n">version</span><span class="p">,</span>
|
||||
<span class="bp">self</span><span class="o">.</span><span class="n">arch</span><span class="o">.</span><span class="n">basearch</span><span class="p">)</span>
|
||||
|
||||
<span class="k">if</span> <span class="nb">len</span><span class="p">(</span><span class="n">isolabel</span><span class="p">)</span> <span class="o">></span> <span class="mi">32</span><span class="p">:</span>
|
||||
<span class="n">logger</span><span class="o">.</span><span class="n">fatal</span><span class="p">(</span><span class="s">"the volume id cannot be longer than 32 characters"</span><span class="p">)</span>
|
||||
<span class="n">sys</span><span class="o">.</span><span class="n">exit</span><span class="p">(</span><span class="mi">1</span><span class="p">)</span>
|
||||
|
||||
<span class="n">templatedir</span> <span class="o">=</span> <span class="bp">self</span><span class="o">.</span><span class="n">conf</span><span class="o">.</span><span class="n">get</span><span class="p">(</span><span class="s">"lorax"</span><span class="p">,</span> <span class="s">"sharedir"</span><span class="p">)</span>
|
||||
<span class="c"># NOTE: rb.root = ybo.conf.installroot (== self.inroot)</span>
|
||||
<span class="n">rb</span> <span class="o">=</span> <span class="n">RuntimeBuilder</span><span class="p">(</span><span class="n">product</span><span class="o">=</span><span class="bp">self</span><span class="o">.</span><span class="n">product</span><span class="p">,</span> <span class="n">arch</span><span class="o">=</span><span class="bp">self</span><span class="o">.</span><span class="n">arch</span><span class="p">,</span>
|
||||
<span class="n">yum</span><span class="o">=</span><span class="n">ybo</span><span class="p">,</span> <span class="n">templatedir</span><span class="o">=</span><span class="n">templatedir</span><span class="p">,</span>
|
||||
<span class="n">installpkgs</span><span class="o">=</span><span class="n">installpkgs</span><span class="p">,</span>
|
||||
<span class="n">add_templates</span><span class="o">=</span><span class="n">add_templates</span><span class="p">,</span>
|
||||
<span class="n">add_template_vars</span><span class="o">=</span><span class="n">add_template_vars</span><span class="p">)</span>
|
||||
|
||||
<span class="n">logger</span><span class="o">.</span><span class="n">info</span><span class="p">(</span><span class="s">"installing runtime packages"</span><span class="p">)</span>
|
||||
<span class="n">rb</span><span class="o">.</span><span class="n">yum</span><span class="o">.</span><span class="n">conf</span><span class="o">.</span><span class="n">skip_broken</span> <span class="o">=</span> <span class="bp">self</span><span class="o">.</span><span class="n">conf</span><span class="o">.</span><span class="n">getboolean</span><span class="p">(</span><span class="s">"yum"</span><span class="p">,</span> <span class="s">"skipbroken"</span><span class="p">)</span>
|
||||
<span class="n">rb</span><span class="o">.</span><span class="n">install</span><span class="p">()</span>
|
||||
|
||||
<span class="c"># write .buildstamp</span>
|
||||
<span class="n">buildstamp</span> <span class="o">=</span> <span class="n">BuildStamp</span><span class="p">(</span><span class="bp">self</span><span class="o">.</span><span class="n">product</span><span class="o">.</span><span class="n">name</span><span class="p">,</span> <span class="bp">self</span><span class="o">.</span><span class="n">product</span><span class="o">.</span><span class="n">version</span><span class="p">,</span>
|
||||
<span class="bp">self</span><span class="o">.</span><span class="n">product</span><span class="o">.</span><span class="n">bugurl</span><span class="p">,</span> <span class="bp">self</span><span class="o">.</span><span class="n">product</span><span class="o">.</span><span class="n">isfinal</span><span class="p">,</span> <span class="bp">self</span><span class="o">.</span><span class="n">arch</span><span class="o">.</span><span class="n">buildarch</span><span class="p">)</span>
|
||||
|
||||
<span class="n">buildstamp</span><span class="o">.</span><span class="n">write</span><span class="p">(</span><span class="n">joinpaths</span><span class="p">(</span><span class="bp">self</span><span class="o">.</span><span class="n">inroot</span><span class="p">,</span> <span class="s">".buildstamp"</span><span class="p">))</span>
|
||||
|
||||
<span class="k">if</span> <span class="bp">self</span><span class="o">.</span><span class="n">debug</span><span class="p">:</span>
|
||||
<span class="n">rb</span><span class="o">.</span><span class="n">writepkglists</span><span class="p">(</span><span class="n">joinpaths</span><span class="p">(</span><span class="n">logdir</span><span class="p">,</span> <span class="s">"pkglists"</span><span class="p">))</span>
|
||||
<span class="n">rb</span><span class="o">.</span><span class="n">writepkgsizes</span><span class="p">(</span><span class="n">joinpaths</span><span class="p">(</span><span class="n">logdir</span><span class="p">,</span> <span class="s">"original-pkgsizes.txt"</span><span class="p">))</span>
|
||||
|
||||
<span class="n">logger</span><span class="o">.</span><span class="n">info</span><span class="p">(</span><span class="s">"doing post-install configuration"</span><span class="p">)</span>
|
||||
<span class="n">rb</span><span class="o">.</span><span class="n">postinstall</span><span class="p">()</span>
|
||||
|
||||
<span class="c"># write .discinfo</span>
|
||||
<span class="n">discinfo</span> <span class="o">=</span> <span class="n">DiscInfo</span><span class="p">(</span><span class="bp">self</span><span class="o">.</span><span class="n">product</span><span class="o">.</span><span class="n">release</span><span class="p">,</span> <span class="bp">self</span><span class="o">.</span><span class="n">arch</span><span class="o">.</span><span class="n">basearch</span><span class="p">)</span>
|
||||
<span class="n">discinfo</span><span class="o">.</span><span class="n">write</span><span class="p">(</span><span class="n">joinpaths</span><span class="p">(</span><span class="bp">self</span><span class="o">.</span><span class="n">outputdir</span><span class="p">,</span> <span class="s">".discinfo"</span><span class="p">))</span>
|
||||
|
||||
<span class="n">logger</span><span class="o">.</span><span class="n">info</span><span class="p">(</span><span class="s">"backing up installroot"</span><span class="p">)</span>
|
||||
<span class="n">installroot</span> <span class="o">=</span> <span class="n">joinpaths</span><span class="p">(</span><span class="bp">self</span><span class="o">.</span><span class="n">workdir</span><span class="p">,</span> <span class="s">"installroot"</span><span class="p">)</span>
|
||||
<span class="n">linktree</span><span class="p">(</span><span class="bp">self</span><span class="o">.</span><span class="n">inroot</span><span class="p">,</span> <span class="n">installroot</span><span class="p">)</span>
|
||||
|
||||
<span class="n">logger</span><span class="o">.</span><span class="n">info</span><span class="p">(</span><span class="s">"generating kernel module metadata"</span><span class="p">)</span>
|
||||
<span class="n">rb</span><span class="o">.</span><span class="n">generate_module_data</span><span class="p">()</span>
|
||||
|
||||
<span class="n">logger</span><span class="o">.</span><span class="n">info</span><span class="p">(</span><span class="s">"cleaning unneeded files"</span><span class="p">)</span>
|
||||
<span class="n">rb</span><span class="o">.</span><span class="n">cleanup</span><span class="p">()</span>
|
||||
|
||||
<span class="k">if</span> <span class="bp">self</span><span class="o">.</span><span class="n">debug</span><span class="p">:</span>
|
||||
<span class="n">rb</span><span class="o">.</span><span class="n">writepkgsizes</span><span class="p">(</span><span class="n">joinpaths</span><span class="p">(</span><span class="n">logdir</span><span class="p">,</span> <span class="s">"final-pkgsizes.txt"</span><span class="p">))</span>
|
||||
|
||||
<span class="n">logger</span><span class="o">.</span><span class="n">info</span><span class="p">(</span><span class="s">"creating the runtime image"</span><span class="p">)</span>
|
||||
<span class="n">runtime</span> <span class="o">=</span> <span class="s">"images/install.img"</span>
|
||||
<span class="n">compression</span> <span class="o">=</span> <span class="bp">self</span><span class="o">.</span><span class="n">conf</span><span class="o">.</span><span class="n">get</span><span class="p">(</span><span class="s">"compression"</span><span class="p">,</span> <span class="s">"type"</span><span class="p">)</span>
|
||||
<span class="n">compressargs</span> <span class="o">=</span> <span class="bp">self</span><span class="o">.</span><span class="n">conf</span><span class="o">.</span><span class="n">get</span><span class="p">(</span><span class="s">"compression"</span><span class="p">,</span> <span class="s">"args"</span><span class="p">)</span><span class="o">.</span><span class="n">split</span><span class="p">()</span>
|
||||
<span class="k">if</span> <span class="bp">self</span><span class="o">.</span><span class="n">conf</span><span class="o">.</span><span class="n">getboolean</span><span class="p">(</span><span class="s">"compression"</span><span class="p">,</span> <span class="s">"bcj"</span><span class="p">):</span>
|
||||
<span class="k">if</span> <span class="bp">self</span><span class="o">.</span><span class="n">arch</span><span class="o">.</span><span class="n">bcj</span><span class="p">:</span>
|
||||
<span class="n">compressargs</span> <span class="o">+=</span> <span class="p">[</span><span class="s">"-Xbcj"</span><span class="p">,</span> <span class="bp">self</span><span class="o">.</span><span class="n">arch</span><span class="o">.</span><span class="n">bcj</span><span class="p">]</span>
|
||||
<span class="k">else</span><span class="p">:</span>
|
||||
<span class="n">logger</span><span class="o">.</span><span class="n">info</span><span class="p">(</span><span class="s">"no BCJ filter for arch </span><span class="si">%s</span><span class="s">"</span><span class="p">,</span> <span class="bp">self</span><span class="o">.</span><span class="n">arch</span><span class="o">.</span><span class="n">basearch</span><span class="p">)</span>
|
||||
<span class="n">rb</span><span class="o">.</span><span class="n">create_runtime</span><span class="p">(</span><span class="n">joinpaths</span><span class="p">(</span><span class="n">installroot</span><span class="p">,</span><span class="n">runtime</span><span class="p">),</span>
|
||||
<span class="n">compression</span><span class="o">=</span><span class="n">compression</span><span class="p">,</span> <span class="n">compressargs</span><span class="o">=</span><span class="n">compressargs</span><span class="p">)</span>
|
||||
|
||||
<span class="n">logger</span><span class="o">.</span><span class="n">info</span><span class="p">(</span><span class="s">"preparing to build output tree and boot images"</span><span class="p">)</span>
|
||||
<span class="n">treebuilder</span> <span class="o">=</span> <span class="n">TreeBuilder</span><span class="p">(</span><span class="n">product</span><span class="o">=</span><span class="bp">self</span><span class="o">.</span><span class="n">product</span><span class="p">,</span> <span class="n">arch</span><span class="o">=</span><span class="bp">self</span><span class="o">.</span><span class="n">arch</span><span class="p">,</span>
|
||||
<span class="n">inroot</span><span class="o">=</span><span class="n">installroot</span><span class="p">,</span> <span class="n">outroot</span><span class="o">=</span><span class="bp">self</span><span class="o">.</span><span class="n">outputdir</span><span class="p">,</span>
|
||||
<span class="n">runtime</span><span class="o">=</span><span class="n">runtime</span><span class="p">,</span> <span class="n">isolabel</span><span class="o">=</span><span class="n">isolabel</span><span class="p">,</span>
|
||||
<span class="n">domacboot</span><span class="o">=</span><span class="n">domacboot</span><span class="p">,</span> <span class="n">doupgrade</span><span class="o">=</span><span class="n">doupgrade</span><span class="p">,</span>
|
||||
<span class="n">templatedir</span><span class="o">=</span><span class="n">templatedir</span><span class="p">,</span>
|
||||
<span class="n">add_templates</span><span class="o">=</span><span class="n">add_arch_templates</span><span class="p">,</span>
|
||||
<span class="n">add_template_vars</span><span class="o">=</span><span class="n">add_arch_template_vars</span><span class="p">,</span>
|
||||
<span class="n">workdir</span><span class="o">=</span><span class="bp">self</span><span class="o">.</span><span class="n">workdir</span><span class="p">)</span>
|
||||
|
||||
<span class="n">logger</span><span class="o">.</span><span class="n">info</span><span class="p">(</span><span class="s">"rebuilding initramfs images"</span><span class="p">)</span>
|
||||
<span class="n">dracut_args</span> <span class="o">=</span> <span class="p">[</span><span class="s">"--xz"</span><span class="p">,</span> <span class="s">"--install"</span><span class="p">,</span> <span class="s">"/.buildstamp"</span><span class="p">,</span> <span class="s">"--no-early-microcode"</span><span class="p">,</span> <span class="s">"--add"</span><span class="p">,</span> <span class="s">"fips"</span><span class="p">]</span>
|
||||
<span class="n">anaconda_args</span> <span class="o">=</span> <span class="n">dracut_args</span> <span class="o">+</span> <span class="p">[</span><span class="s">"--add"</span><span class="p">,</span> <span class="s">"anaconda pollcdrom"</span><span class="p">]</span>
|
||||
|
||||
<span class="c"># ppc64 cannot boot an initrd > 32MiB so remove some drivers</span>
|
||||
<span class="k">if</span> <span class="bp">self</span><span class="o">.</span><span class="n">arch</span><span class="o">.</span><span class="n">basearch</span> <span class="ow">in</span> <span class="p">(</span><span class="s">"ppc64"</span><span class="p">,</span> <span class="s">"ppc64le"</span><span class="p">):</span>
|
||||
<span class="n">dracut_args</span><span class="o">.</span><span class="n">extend</span><span class="p">([</span><span class="s">"--omit-drivers"</span><span class="p">,</span> <span class="n">REMOVE_PPC64_DRIVERS</span><span class="p">])</span>
|
||||
|
||||
<span class="c"># Only omit dracut modules from the initrd so that they're kept for</span>
|
||||
<span class="c"># upgrade.img</span>
|
||||
<span class="n">anaconda_args</span><span class="o">.</span><span class="n">extend</span><span class="p">([</span><span class="s">"--omit"</span><span class="p">,</span> <span class="n">REMOVE_PPC64_MODULES</span><span class="p">])</span>
|
||||
|
||||
<span class="n">treebuilder</span><span class="o">.</span><span class="n">rebuild_initrds</span><span class="p">(</span><span class="n">add_args</span><span class="o">=</span><span class="n">anaconda_args</span><span class="p">)</span>
|
||||
|
||||
<span class="k">if</span> <span class="n">doupgrade</span><span class="p">:</span>
|
||||
<span class="c"># Build upgrade.img. It'd be nice if these could coexist in the same</span>
|
||||
<span class="c"># image, but that would increase the size of the anaconda initramfs,</span>
|
||||
<span class="c"># which worries some people (esp. PPC tftpboot). So they're separate.</span>
|
||||
<span class="k">try</span><span class="p">:</span>
|
||||
<span class="c"># If possible, use the 'redhat-upgrade-tool' plymouth theme</span>
|
||||
<span class="n">themes</span> <span class="o">=</span> <span class="n">runcmd_output</span><span class="p">([</span><span class="s">'plymouth-set-default-theme'</span><span class="p">,</span> <span class="s">'--list'</span><span class="p">],</span>
|
||||
<span class="n">root</span><span class="o">=</span><span class="n">installroot</span><span class="p">)</span>
|
||||
<span class="k">if</span> <span class="s">'redhat-upgrade-tool'</span> <span class="ow">in</span> <span class="n">themes</span><span class="o">.</span><span class="n">splitlines</span><span class="p">():</span>
|
||||
<span class="n">os</span><span class="o">.</span><span class="n">environ</span><span class="p">[</span><span class="s">'PLYMOUTH_THEME_NAME'</span><span class="p">]</span> <span class="o">=</span> <span class="s">'redhat-upgrade-tool'</span>
|
||||
<span class="k">except</span> <span class="ne">RuntimeError</span><span class="p">:</span>
|
||||
<span class="k">pass</span>
|
||||
<span class="n">upgrade_args</span> <span class="o">=</span> <span class="n">dracut_args</span> <span class="o">+</span> <span class="p">[</span><span class="s">"--add"</span><span class="p">,</span> <span class="s">"system-upgrade convertfs"</span><span class="p">]</span>
|
||||
<span class="n">treebuilder</span><span class="o">.</span><span class="n">rebuild_initrds</span><span class="p">(</span><span class="n">add_args</span><span class="o">=</span><span class="n">upgrade_args</span><span class="p">,</span> <span class="n">prefix</span><span class="o">=</span><span class="s">"upgrade"</span><span class="p">)</span>
|
||||
|
||||
<span class="n">logger</span><span class="o">.</span><span class="n">info</span><span class="p">(</span><span class="s">"populating output tree and building boot images"</span><span class="p">)</span>
|
||||
<span class="n">treebuilder</span><span class="o">.</span><span class="n">build</span><span class="p">()</span>
|
||||
|
||||
<span class="c"># write .treeinfo file and we're done</span>
|
||||
<span class="n">treeinfo</span> <span class="o">=</span> <span class="n">TreeInfo</span><span class="p">(</span><span class="bp">self</span><span class="o">.</span><span class="n">product</span><span class="o">.</span><span class="n">name</span><span class="p">,</span> <span class="bp">self</span><span class="o">.</span><span class="n">product</span><span class="o">.</span><span class="n">version</span><span class="p">,</span>
|
||||
<span class="bp">self</span><span class="o">.</span><span class="n">product</span><span class="o">.</span><span class="n">variant</span><span class="p">,</span> <span class="bp">self</span><span class="o">.</span><span class="n">arch</span><span class="o">.</span><span class="n">basearch</span><span class="p">)</span>
|
||||
<span class="k">for</span> <span class="n">section</span><span class="p">,</span> <span class="n">data</span> <span class="ow">in</span> <span class="n">treebuilder</span><span class="o">.</span><span class="n">treeinfo_data</span><span class="o">.</span><span class="n">items</span><span class="p">():</span>
|
||||
<span class="n">treeinfo</span><span class="o">.</span><span class="n">add_section</span><span class="p">(</span><span class="n">section</span><span class="p">,</span> <span class="n">data</span><span class="p">)</span>
|
||||
<span class="n">treeinfo</span><span class="o">.</span><span class="n">write</span><span class="p">(</span><span class="n">joinpaths</span><span class="p">(</span><span class="bp">self</span><span class="o">.</span><span class="n">outputdir</span><span class="p">,</span> <span class="s">".treeinfo"</span><span class="p">))</span>
|
||||
|
||||
<span class="c"># cleanup</span>
|
||||
<span class="k">if</span> <span class="n">remove_temp</span><span class="p">:</span>
|
||||
<span class="n">remove</span><span class="p">(</span><span class="bp">self</span><span class="o">.</span><span class="n">workdir</span><span class="p">)</span>
|
||||
|
||||
</div></div>
|
||||
<div class="viewcode-block" id="get_buildarch"><a class="viewcode-back" href="../pylorax.html#pylorax.get_buildarch">[docs]</a><span class="k">def</span> <span class="nf">get_buildarch</span><span class="p">(</span><span class="n">ybo</span><span class="p">):</span>
|
||||
<span class="c"># get architecture of the available anaconda package</span>
|
||||
<span class="n">buildarch</span> <span class="o">=</span> <span class="bp">None</span>
|
||||
<span class="k">for</span> <span class="n">anaconda</span> <span class="ow">in</span> <span class="n">ybo</span><span class="o">.</span><span class="n">doPackageLists</span><span class="p">(</span><span class="n">patterns</span><span class="o">=</span><span class="p">[</span><span class="s">"anaconda"</span><span class="p">])</span><span class="o">.</span><span class="n">available</span><span class="p">:</span>
|
||||
<span class="k">if</span> <span class="n">anaconda</span><span class="o">.</span><span class="n">arch</span> <span class="o">!=</span> <span class="s">"src"</span><span class="p">:</span>
|
||||
<span class="n">buildarch</span> <span class="o">=</span> <span class="n">anaconda</span><span class="o">.</span><span class="n">arch</span>
|
||||
<span class="k">break</span>
|
||||
<span class="k">if</span> <span class="ow">not</span> <span class="n">buildarch</span><span class="p">:</span>
|
||||
<span class="n">logger</span><span class="o">.</span><span class="n">critical</span><span class="p">(</span><span class="s">"no anaconda package in the repository"</span><span class="p">)</span>
|
||||
<span class="n">sys</span><span class="o">.</span><span class="n">exit</span><span class="p">(</span><span class="mi">1</span><span class="p">)</span>
|
||||
|
||||
<span class="k">return</span> <span class="n">buildarch</span></div>
|
||||
</pre></div>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="sphinxsidebar">
|
||||
<div class="sphinxsidebarwrapper">
|
||||
<div id="searchbox" style="display: none">
|
||||
<h3>Quick search</h3>
|
||||
<form class="search" action="../search.html" method="get">
|
||||
<input type="text" name="q" />
|
||||
<input type="submit" value="Go" />
|
||||
<input type="hidden" name="check_keywords" value="yes" />
|
||||
<input type="hidden" name="area" value="default" />
|
||||
</form>
|
||||
<p class="searchtip" style="font-size: 90%">
|
||||
Enter search terms or a module, class or function name.
|
||||
</p>
|
||||
</div>
|
||||
<script type="text/javascript">$('#searchbox').show(0);</script>
|
||||
</div>
|
||||
</div>
|
||||
<div class="clearer"></div>
|
||||
</div>
|
||||
<div class="related">
|
||||
<h3>Navigation</h3>
|
||||
<ul>
|
||||
<li class="right" style="margin-right: 10px">
|
||||
<a href="../genindex.html" title="General Index"
|
||||
>index</a></li>
|
||||
<li class="right" >
|
||||
<a href="../py-modindex.html" title="Python Module Index"
|
||||
>modules</a> |</li>
|
||||
<li><a href="../index.html">Lorax 19.7.11 documentation</a> »</li>
|
||||
<li><a href="index.html" >Module code</a> »</li>
|
||||
</ul>
|
||||
</div>
|
||||
<div class="footer">
|
||||
© Copyright 2018, Red Hat, Inc..
|
||||
Created using <a href="http://sphinx.pocoo.org/">Sphinx</a> 1.1.3.
|
||||
</div>
|
||||
</body>
|
||||
</html>
|
@ -8,7 +8,7 @@
|
||||
<head>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
|
||||
|
||||
<title>pylorax.__init__ — Lorax 19.7.10 documentation</title>
|
||||
<title>pylorax.__init__ — Lorax 19.7.11 documentation</title>
|
||||
|
||||
<link rel="stylesheet" href="../../_static/default.css" type="text/css" />
|
||||
<link rel="stylesheet" href="../../_static/pygments.css" type="text/css" />
|
||||
@ -16,7 +16,7 @@
|
||||
<script type="text/javascript">
|
||||
var DOCUMENTATION_OPTIONS = {
|
||||
URL_ROOT: '../../',
|
||||
VERSION: '19.7.10',
|
||||
VERSION: '19.7.11',
|
||||
COLLAPSE_INDEX: false,
|
||||
FILE_SUFFIX: '.html',
|
||||
HAS_SOURCE: true
|
||||
@ -25,8 +25,8 @@
|
||||
<script type="text/javascript" src="../../_static/jquery.js"></script>
|
||||
<script type="text/javascript" src="../../_static/underscore.js"></script>
|
||||
<script type="text/javascript" src="../../_static/doctools.js"></script>
|
||||
<link rel="top" title="Lorax 19.7.10 documentation" href="../../index.html" />
|
||||
<link rel="up" title="Module code" href="../index.html" />
|
||||
<link rel="top" title="Lorax 19.7.11 documentation" href="../../index.html" />
|
||||
<link rel="up" title="pylorax" href="../pylorax.html" />
|
||||
</head>
|
||||
<body>
|
||||
<div class="related">
|
||||
@ -38,8 +38,9 @@
|
||||
<li class="right" >
|
||||
<a href="../../py-modindex.html" title="Python Module Index"
|
||||
>modules</a> |</li>
|
||||
<li><a href="../../index.html">Lorax 19.7.10 documentation</a> »</li>
|
||||
<li><a href="../index.html" accesskey="U">Module code</a> »</li>
|
||||
<li><a href="../../index.html">Lorax 19.7.11 documentation</a> »</li>
|
||||
<li><a href="../index.html" >Module code</a> »</li>
|
||||
<li><a href="../pylorax.html" accesskey="U">pylorax</a> »</li>
|
||||
</ul>
|
||||
</div>
|
||||
|
||||
@ -457,12 +458,13 @@
|
||||
<li class="right" >
|
||||
<a href="../../py-modindex.html" title="Python Module Index"
|
||||
>modules</a> |</li>
|
||||
<li><a href="../../index.html">Lorax 19.7.10 documentation</a> »</li>
|
||||
<li><a href="../../index.html">Lorax 19.7.11 documentation</a> »</li>
|
||||
<li><a href="../index.html" >Module code</a> »</li>
|
||||
<li><a href="../pylorax.html" >pylorax</a> »</li>
|
||||
</ul>
|
||||
</div>
|
||||
<div class="footer">
|
||||
© Copyright 2017, Red Hat, Inc..
|
||||
© Copyright 2018, Red Hat, Inc..
|
||||
Created using <a href="http://sphinx.pocoo.org/">Sphinx</a> 1.1.3.
|
||||
</div>
|
||||
</body>
|
||||
|
@ -8,7 +8,7 @@
|
||||
<head>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
|
||||
|
||||
<title>pylorax.api — Lorax 19.7.10 documentation</title>
|
||||
<title>pylorax.api — Lorax 19.7.11 documentation</title>
|
||||
|
||||
<link rel="stylesheet" href="../../_static/default.css" type="text/css" />
|
||||
<link rel="stylesheet" href="../../_static/pygments.css" type="text/css" />
|
||||
@ -16,7 +16,7 @@
|
||||
<script type="text/javascript">
|
||||
var DOCUMENTATION_OPTIONS = {
|
||||
URL_ROOT: '../../',
|
||||
VERSION: '19.7.10',
|
||||
VERSION: '19.7.11',
|
||||
COLLAPSE_INDEX: false,
|
||||
FILE_SUFFIX: '.html',
|
||||
HAS_SOURCE: true
|
||||
@ -25,8 +25,8 @@
|
||||
<script type="text/javascript" src="../../_static/jquery.js"></script>
|
||||
<script type="text/javascript" src="../../_static/underscore.js"></script>
|
||||
<script type="text/javascript" src="../../_static/doctools.js"></script>
|
||||
<link rel="top" title="Lorax 19.7.10 documentation" href="../../index.html" />
|
||||
<link rel="up" title="Module code" href="../index.html" />
|
||||
<link rel="top" title="Lorax 19.7.11 documentation" href="../../index.html" />
|
||||
<link rel="up" title="pylorax" href="../pylorax.html" />
|
||||
</head>
|
||||
<body>
|
||||
<div class="related">
|
||||
@ -38,8 +38,9 @@
|
||||
<li class="right" >
|
||||
<a href="../../py-modindex.html" title="Python Module Index"
|
||||
>modules</a> |</li>
|
||||
<li><a href="../../index.html">Lorax 19.7.10 documentation</a> »</li>
|
||||
<li><a href="../index.html" accesskey="U">Module code</a> »</li>
|
||||
<li><a href="../../index.html">Lorax 19.7.11 documentation</a> »</li>
|
||||
<li><a href="../index.html" >Module code</a> »</li>
|
||||
<li><a href="../pylorax.html" accesskey="U">pylorax</a> »</li>
|
||||
</ul>
|
||||
</div>
|
||||
|
||||
@ -102,12 +103,13 @@
|
||||
<li class="right" >
|
||||
<a href="../../py-modindex.html" title="Python Module Index"
|
||||
>modules</a> |</li>
|
||||
<li><a href="../../index.html">Lorax 19.7.10 documentation</a> »</li>
|
||||
<li><a href="../../index.html">Lorax 19.7.11 documentation</a> »</li>
|
||||
<li><a href="../index.html" >Module code</a> »</li>
|
||||
<li><a href="../pylorax.html" >pylorax</a> »</li>
|
||||
</ul>
|
||||
</div>
|
||||
<div class="footer">
|
||||
© Copyright 2017, Red Hat, Inc..
|
||||
© Copyright 2018, Red Hat, Inc..
|
||||
Created using <a href="http://sphinx.pocoo.org/">Sphinx</a> 1.1.3.
|
||||
</div>
|
||||
</body>
|
||||
|
@ -8,7 +8,7 @@
|
||||
<head>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
|
||||
|
||||
<title>pylorax.api.compose — Lorax 19.7.10 documentation</title>
|
||||
<title>pylorax.api.compose — Lorax 19.7.11 documentation</title>
|
||||
|
||||
<link rel="stylesheet" href="../../../_static/default.css" type="text/css" />
|
||||
<link rel="stylesheet" href="../../../_static/pygments.css" type="text/css" />
|
||||
@ -16,7 +16,7 @@
|
||||
<script type="text/javascript">
|
||||
var DOCUMENTATION_OPTIONS = {
|
||||
URL_ROOT: '../../../',
|
||||
VERSION: '19.7.10',
|
||||
VERSION: '19.7.11',
|
||||
COLLAPSE_INDEX: false,
|
||||
FILE_SUFFIX: '.html',
|
||||
HAS_SOURCE: true
|
||||
@ -25,7 +25,7 @@
|
||||
<script type="text/javascript" src="../../../_static/jquery.js"></script>
|
||||
<script type="text/javascript" src="../../../_static/underscore.js"></script>
|
||||
<script type="text/javascript" src="../../../_static/doctools.js"></script>
|
||||
<link rel="top" title="Lorax 19.7.10 documentation" href="../../../index.html" />
|
||||
<link rel="top" title="Lorax 19.7.11 documentation" href="../../../index.html" />
|
||||
<link rel="up" title="pylorax.api" href="../api.html" />
|
||||
</head>
|
||||
<body>
|
||||
@ -38,8 +38,9 @@
|
||||
<li class="right" >
|
||||
<a href="../../../py-modindex.html" title="Python Module Index"
|
||||
>modules</a> |</li>
|
||||
<li><a href="../../../index.html">Lorax 19.7.10 documentation</a> »</li>
|
||||
<li><a href="../../../index.html">Lorax 19.7.11 documentation</a> »</li>
|
||||
<li><a href="../../index.html" >Module code</a> »</li>
|
||||
<li><a href="../../pylorax.html" >pylorax</a> »</li>
|
||||
<li><a href="../api.html" accesskey="U">pylorax.api</a> »</li>
|
||||
</ul>
|
||||
</div>
|
||||
@ -404,13 +405,14 @@
|
||||
<li class="right" >
|
||||
<a href="../../../py-modindex.html" title="Python Module Index"
|
||||
>modules</a> |</li>
|
||||
<li><a href="../../../index.html">Lorax 19.7.10 documentation</a> »</li>
|
||||
<li><a href="../../../index.html">Lorax 19.7.11 documentation</a> »</li>
|
||||
<li><a href="../../index.html" >Module code</a> »</li>
|
||||
<li><a href="../../pylorax.html" >pylorax</a> »</li>
|
||||
<li><a href="../api.html" >pylorax.api</a> »</li>
|
||||
</ul>
|
||||
</div>
|
||||
<div class="footer">
|
||||
© Copyright 2017, Red Hat, Inc..
|
||||
© Copyright 2018, Red Hat, Inc..
|
||||
Created using <a href="http://sphinx.pocoo.org/">Sphinx</a> 1.1.3.
|
||||
</div>
|
||||
</body>
|
||||
|
@ -8,7 +8,7 @@
|
||||
<head>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
|
||||
|
||||
<title>pylorax.api.config — Lorax 19.7.10 documentation</title>
|
||||
<title>pylorax.api.config — Lorax 19.7.11 documentation</title>
|
||||
|
||||
<link rel="stylesheet" href="../../../_static/default.css" type="text/css" />
|
||||
<link rel="stylesheet" href="../../../_static/pygments.css" type="text/css" />
|
||||
@ -16,7 +16,7 @@
|
||||
<script type="text/javascript">
|
||||
var DOCUMENTATION_OPTIONS = {
|
||||
URL_ROOT: '../../../',
|
||||
VERSION: '19.7.10',
|
||||
VERSION: '19.7.11',
|
||||
COLLAPSE_INDEX: false,
|
||||
FILE_SUFFIX: '.html',
|
||||
HAS_SOURCE: true
|
||||
@ -25,7 +25,7 @@
|
||||
<script type="text/javascript" src="../../../_static/jquery.js"></script>
|
||||
<script type="text/javascript" src="../../../_static/underscore.js"></script>
|
||||
<script type="text/javascript" src="../../../_static/doctools.js"></script>
|
||||
<link rel="top" title="Lorax 19.7.10 documentation" href="../../../index.html" />
|
||||
<link rel="top" title="Lorax 19.7.11 documentation" href="../../../index.html" />
|
||||
<link rel="up" title="pylorax.api" href="../api.html" />
|
||||
</head>
|
||||
<body>
|
||||
@ -38,8 +38,9 @@
|
||||
<li class="right" >
|
||||
<a href="../../../py-modindex.html" title="Python Module Index"
|
||||
>modules</a> |</li>
|
||||
<li><a href="../../../index.html">Lorax 19.7.10 documentation</a> »</li>
|
||||
<li><a href="../../../index.html">Lorax 19.7.11 documentation</a> »</li>
|
||||
<li><a href="../../index.html" >Module code</a> »</li>
|
||||
<li><a href="../../pylorax.html" >pylorax</a> »</li>
|
||||
<li><a href="../api.html" accesskey="U">pylorax.api</a> »</li>
|
||||
</ul>
|
||||
</div>
|
||||
@ -189,13 +190,14 @@
|
||||
<li class="right" >
|
||||
<a href="../../../py-modindex.html" title="Python Module Index"
|
||||
>modules</a> |</li>
|
||||
<li><a href="../../../index.html">Lorax 19.7.10 documentation</a> »</li>
|
||||
<li><a href="../../../index.html">Lorax 19.7.11 documentation</a> »</li>
|
||||
<li><a href="../../index.html" >Module code</a> »</li>
|
||||
<li><a href="../../pylorax.html" >pylorax</a> »</li>
|
||||
<li><a href="../api.html" >pylorax.api</a> »</li>
|
||||
</ul>
|
||||
</div>
|
||||
<div class="footer">
|
||||
© Copyright 2017, Red Hat, Inc..
|
||||
© Copyright 2018, Red Hat, Inc..
|
||||
Created using <a href="http://sphinx.pocoo.org/">Sphinx</a> 1.1.3.
|
||||
</div>
|
||||
</body>
|
||||
|
@ -8,7 +8,7 @@
|
||||
<head>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
|
||||
|
||||
<title>pylorax.api.crossdomain — Lorax 19.7.10 documentation</title>
|
||||
<title>pylorax.api.crossdomain — Lorax 19.7.11 documentation</title>
|
||||
|
||||
<link rel="stylesheet" href="../../../_static/default.css" type="text/css" />
|
||||
<link rel="stylesheet" href="../../../_static/pygments.css" type="text/css" />
|
||||
@ -16,7 +16,7 @@
|
||||
<script type="text/javascript">
|
||||
var DOCUMENTATION_OPTIONS = {
|
||||
URL_ROOT: '../../../',
|
||||
VERSION: '19.7.10',
|
||||
VERSION: '19.7.11',
|
||||
COLLAPSE_INDEX: false,
|
||||
FILE_SUFFIX: '.html',
|
||||
HAS_SOURCE: true
|
||||
@ -25,7 +25,7 @@
|
||||
<script type="text/javascript" src="../../../_static/jquery.js"></script>
|
||||
<script type="text/javascript" src="../../../_static/underscore.js"></script>
|
||||
<script type="text/javascript" src="../../../_static/doctools.js"></script>
|
||||
<link rel="top" title="Lorax 19.7.10 documentation" href="../../../index.html" />
|
||||
<link rel="top" title="Lorax 19.7.11 documentation" href="../../../index.html" />
|
||||
<link rel="up" title="pylorax.api" href="../api.html" />
|
||||
</head>
|
||||
<body>
|
||||
@ -38,8 +38,9 @@
|
||||
<li class="right" >
|
||||
<a href="../../../py-modindex.html" title="Python Module Index"
|
||||
>modules</a> |</li>
|
||||
<li><a href="../../../index.html">Lorax 19.7.10 documentation</a> »</li>
|
||||
<li><a href="../../../index.html">Lorax 19.7.11 documentation</a> »</li>
|
||||
<li><a href="../../index.html" >Module code</a> »</li>
|
||||
<li><a href="../../pylorax.html" >pylorax</a> »</li>
|
||||
<li><a href="../api.html" accesskey="U">pylorax.api</a> »</li>
|
||||
</ul>
|
||||
</div>
|
||||
@ -147,13 +148,14 @@
|
||||
<li class="right" >
|
||||
<a href="../../../py-modindex.html" title="Python Module Index"
|
||||
>modules</a> |</li>
|
||||
<li><a href="../../../index.html">Lorax 19.7.10 documentation</a> »</li>
|
||||
<li><a href="../../../index.html">Lorax 19.7.11 documentation</a> »</li>
|
||||
<li><a href="../../index.html" >Module code</a> »</li>
|
||||
<li><a href="../../pylorax.html" >pylorax</a> »</li>
|
||||
<li><a href="../api.html" >pylorax.api</a> »</li>
|
||||
</ul>
|
||||
</div>
|
||||
<div class="footer">
|
||||
© Copyright 2017, Red Hat, Inc..
|
||||
© Copyright 2018, Red Hat, Inc..
|
||||
Created using <a href="http://sphinx.pocoo.org/">Sphinx</a> 1.1.3.
|
||||
</div>
|
||||
</body>
|
||||
|
@ -8,7 +8,7 @@
|
||||
<head>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
|
||||
|
||||
<title>pylorax.api.projects — Lorax 19.7.10 documentation</title>
|
||||
<title>pylorax.api.projects — Lorax 19.7.11 documentation</title>
|
||||
|
||||
<link rel="stylesheet" href="../../../_static/default.css" type="text/css" />
|
||||
<link rel="stylesheet" href="../../../_static/pygments.css" type="text/css" />
|
||||
@ -16,7 +16,7 @@
|
||||
<script type="text/javascript">
|
||||
var DOCUMENTATION_OPTIONS = {
|
||||
URL_ROOT: '../../../',
|
||||
VERSION: '19.7.10',
|
||||
VERSION: '19.7.11',
|
||||
COLLAPSE_INDEX: false,
|
||||
FILE_SUFFIX: '.html',
|
||||
HAS_SOURCE: true
|
||||
@ -25,7 +25,7 @@
|
||||
<script type="text/javascript" src="../../../_static/jquery.js"></script>
|
||||
<script type="text/javascript" src="../../../_static/underscore.js"></script>
|
||||
<script type="text/javascript" src="../../../_static/doctools.js"></script>
|
||||
<link rel="top" title="Lorax 19.7.10 documentation" href="../../../index.html" />
|
||||
<link rel="top" title="Lorax 19.7.11 documentation" href="../../../index.html" />
|
||||
<link rel="up" title="pylorax.api" href="../api.html" />
|
||||
</head>
|
||||
<body>
|
||||
@ -38,8 +38,9 @@
|
||||
<li class="right" >
|
||||
<a href="../../../py-modindex.html" title="Python Module Index"
|
||||
>modules</a> |</li>
|
||||
<li><a href="../../../index.html">Lorax 19.7.10 documentation</a> »</li>
|
||||
<li><a href="../../../index.html">Lorax 19.7.11 documentation</a> »</li>
|
||||
<li><a href="../../index.html" >Module code</a> »</li>
|
||||
<li><a href="../../pylorax.html" >pylorax</a> »</li>
|
||||
<li><a href="../api.html" accesskey="U">pylorax.api</a> »</li>
|
||||
</ul>
|
||||
</div>
|
||||
@ -346,13 +347,14 @@
|
||||
<li class="right" >
|
||||
<a href="../../../py-modindex.html" title="Python Module Index"
|
||||
>modules</a> |</li>
|
||||
<li><a href="../../../index.html">Lorax 19.7.10 documentation</a> »</li>
|
||||
<li><a href="../../../index.html">Lorax 19.7.11 documentation</a> »</li>
|
||||
<li><a href="../../index.html" >Module code</a> »</li>
|
||||
<li><a href="../../pylorax.html" >pylorax</a> »</li>
|
||||
<li><a href="../api.html" >pylorax.api</a> »</li>
|
||||
</ul>
|
||||
</div>
|
||||
<div class="footer">
|
||||
© Copyright 2017, Red Hat, Inc..
|
||||
© Copyright 2018, Red Hat, Inc..
|
||||
Created using <a href="http://sphinx.pocoo.org/">Sphinx</a> 1.1.3.
|
||||
</div>
|
||||
</body>
|
||||
|
@ -8,7 +8,7 @@
|
||||
<head>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
|
||||
|
||||
<title>pylorax.api.queue — Lorax 19.7.10 documentation</title>
|
||||
<title>pylorax.api.queue — Lorax 19.7.11 documentation</title>
|
||||
|
||||
<link rel="stylesheet" href="../../../_static/default.css" type="text/css" />
|
||||
<link rel="stylesheet" href="../../../_static/pygments.css" type="text/css" />
|
||||
@ -16,7 +16,7 @@
|
||||
<script type="text/javascript">
|
||||
var DOCUMENTATION_OPTIONS = {
|
||||
URL_ROOT: '../../../',
|
||||
VERSION: '19.7.10',
|
||||
VERSION: '19.7.11',
|
||||
COLLAPSE_INDEX: false,
|
||||
FILE_SUFFIX: '.html',
|
||||
HAS_SOURCE: true
|
||||
@ -25,7 +25,7 @@
|
||||
<script type="text/javascript" src="../../../_static/jquery.js"></script>
|
||||
<script type="text/javascript" src="../../../_static/underscore.js"></script>
|
||||
<script type="text/javascript" src="../../../_static/doctools.js"></script>
|
||||
<link rel="top" title="Lorax 19.7.10 documentation" href="../../../index.html" />
|
||||
<link rel="top" title="Lorax 19.7.11 documentation" href="../../../index.html" />
|
||||
<link rel="up" title="pylorax.api" href="../api.html" />
|
||||
</head>
|
||||
<body>
|
||||
@ -38,8 +38,9 @@
|
||||
<li class="right" >
|
||||
<a href="../../../py-modindex.html" title="Python Module Index"
|
||||
>modules</a> |</li>
|
||||
<li><a href="../../../index.html">Lorax 19.7.10 documentation</a> »</li>
|
||||
<li><a href="../../../index.html">Lorax 19.7.11 documentation</a> »</li>
|
||||
<li><a href="../../index.html" >Module code</a> »</li>
|
||||
<li><a href="../../pylorax.html" >pylorax</a> »</li>
|
||||
<li><a href="../api.html" accesskey="U">pylorax.api</a> »</li>
|
||||
</ul>
|
||||
</div>
|
||||
@ -646,13 +647,14 @@
|
||||
<li class="right" >
|
||||
<a href="../../../py-modindex.html" title="Python Module Index"
|
||||
>modules</a> |</li>
|
||||
<li><a href="../../../index.html">Lorax 19.7.10 documentation</a> »</li>
|
||||
<li><a href="../../../index.html">Lorax 19.7.11 documentation</a> »</li>
|
||||
<li><a href="../../index.html" >Module code</a> »</li>
|
||||
<li><a href="../../pylorax.html" >pylorax</a> »</li>
|
||||
<li><a href="../api.html" >pylorax.api</a> »</li>
|
||||
</ul>
|
||||
</div>
|
||||
<div class="footer">
|
||||
© Copyright 2017, Red Hat, Inc..
|
||||
© Copyright 2018, Red Hat, Inc..
|
||||
Created using <a href="http://sphinx.pocoo.org/">Sphinx</a> 1.1.3.
|
||||
</div>
|
||||
</body>
|
||||
|
@ -8,7 +8,7 @@
|
||||
<head>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
|
||||
|
||||
<title>pylorax.api.recipes — Lorax 19.7.10 documentation</title>
|
||||
<title>pylorax.api.recipes — Lorax 19.7.11 documentation</title>
|
||||
|
||||
<link rel="stylesheet" href="../../../_static/default.css" type="text/css" />
|
||||
<link rel="stylesheet" href="../../../_static/pygments.css" type="text/css" />
|
||||
@ -16,7 +16,7 @@
|
||||
<script type="text/javascript">
|
||||
var DOCUMENTATION_OPTIONS = {
|
||||
URL_ROOT: '../../../',
|
||||
VERSION: '19.7.10',
|
||||
VERSION: '19.7.11',
|
||||
COLLAPSE_INDEX: false,
|
||||
FILE_SUFFIX: '.html',
|
||||
HAS_SOURCE: true
|
||||
@ -25,7 +25,7 @@
|
||||
<script type="text/javascript" src="../../../_static/jquery.js"></script>
|
||||
<script type="text/javascript" src="../../../_static/underscore.js"></script>
|
||||
<script type="text/javascript" src="../../../_static/doctools.js"></script>
|
||||
<link rel="top" title="Lorax 19.7.10 documentation" href="../../../index.html" />
|
||||
<link rel="top" title="Lorax 19.7.11 documentation" href="../../../index.html" />
|
||||
<link rel="up" title="pylorax.api" href="../api.html" />
|
||||
</head>
|
||||
<body>
|
||||
@ -38,8 +38,9 @@
|
||||
<li class="right" >
|
||||
<a href="../../../py-modindex.html" title="Python Module Index"
|
||||
>modules</a> |</li>
|
||||
<li><a href="../../../index.html">Lorax 19.7.10 documentation</a> »</li>
|
||||
<li><a href="../../../index.html">Lorax 19.7.11 documentation</a> »</li>
|
||||
<li><a href="../../index.html" >Module code</a> »</li>
|
||||
<li><a href="../../pylorax.html" >pylorax</a> »</li>
|
||||
<li><a href="../api.html" accesskey="U">pylorax.api</a> »</li>
|
||||
</ul>
|
||||
</div>
|
||||
@ -965,13 +966,14 @@
|
||||
<li class="right" >
|
||||
<a href="../../../py-modindex.html" title="Python Module Index"
|
||||
>modules</a> |</li>
|
||||
<li><a href="../../../index.html">Lorax 19.7.10 documentation</a> »</li>
|
||||
<li><a href="../../../index.html">Lorax 19.7.11 documentation</a> »</li>
|
||||
<li><a href="../../index.html" >Module code</a> »</li>
|
||||
<li><a href="../../pylorax.html" >pylorax</a> »</li>
|
||||
<li><a href="../api.html" >pylorax.api</a> »</li>
|
||||
</ul>
|
||||
</div>
|
||||
<div class="footer">
|
||||
© Copyright 2017, Red Hat, Inc..
|
||||
© Copyright 2018, Red Hat, Inc..
|
||||
Created using <a href="http://sphinx.pocoo.org/">Sphinx</a> 1.1.3.
|
||||
</div>
|
||||
</body>
|
||||
|
@ -8,7 +8,7 @@
|
||||
<head>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
|
||||
|
||||
<title>pylorax.api.server — Lorax 19.7.10 documentation</title>
|
||||
<title>pylorax.api.server — Lorax 19.7.11 documentation</title>
|
||||
|
||||
<link rel="stylesheet" href="../../../_static/default.css" type="text/css" />
|
||||
<link rel="stylesheet" href="../../../_static/pygments.css" type="text/css" />
|
||||
@ -16,7 +16,7 @@
|
||||
<script type="text/javascript">
|
||||
var DOCUMENTATION_OPTIONS = {
|
||||
URL_ROOT: '../../../',
|
||||
VERSION: '19.7.10',
|
||||
VERSION: '19.7.11',
|
||||
COLLAPSE_INDEX: false,
|
||||
FILE_SUFFIX: '.html',
|
||||
HAS_SOURCE: true
|
||||
@ -25,7 +25,7 @@
|
||||
<script type="text/javascript" src="../../../_static/jquery.js"></script>
|
||||
<script type="text/javascript" src="../../../_static/underscore.js"></script>
|
||||
<script type="text/javascript" src="../../../_static/doctools.js"></script>
|
||||
<link rel="top" title="Lorax 19.7.10 documentation" href="../../../index.html" />
|
||||
<link rel="top" title="Lorax 19.7.11 documentation" href="../../../index.html" />
|
||||
<link rel="up" title="pylorax.api" href="../api.html" />
|
||||
</head>
|
||||
<body>
|
||||
@ -38,8 +38,9 @@
|
||||
<li class="right" >
|
||||
<a href="../../../py-modindex.html" title="Python Module Index"
|
||||
>modules</a> |</li>
|
||||
<li><a href="../../../index.html">Lorax 19.7.10 documentation</a> »</li>
|
||||
<li><a href="../../../index.html">Lorax 19.7.11 documentation</a> »</li>
|
||||
<li><a href="../../index.html" >Module code</a> »</li>
|
||||
<li><a href="../../pylorax.html" >pylorax</a> »</li>
|
||||
<li><a href="../api.html" accesskey="U">pylorax.api</a> »</li>
|
||||
</ul>
|
||||
</div>
|
||||
@ -138,13 +139,14 @@
|
||||
<li class="right" >
|
||||
<a href="../../../py-modindex.html" title="Python Module Index"
|
||||
>modules</a> |</li>
|
||||
<li><a href="../../../index.html">Lorax 19.7.10 documentation</a> »</li>
|
||||
<li><a href="../../../index.html">Lorax 19.7.11 documentation</a> »</li>
|
||||
<li><a href="../../index.html" >Module code</a> »</li>
|
||||
<li><a href="../../pylorax.html" >pylorax</a> »</li>
|
||||
<li><a href="../api.html" >pylorax.api</a> »</li>
|
||||
</ul>
|
||||
</div>
|
||||
<div class="footer">
|
||||
© Copyright 2017, Red Hat, Inc..
|
||||
© Copyright 2018, Red Hat, Inc..
|
||||
Created using <a href="http://sphinx.pocoo.org/">Sphinx</a> 1.1.3.
|
||||
</div>
|
||||
</body>
|
||||
|
@ -8,7 +8,7 @@
|
||||
<head>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
|
||||
|
||||
<title>pylorax.api.v0 — Lorax 19.7.10 documentation</title>
|
||||
<title>pylorax.api.v0 — Lorax 19.7.11 documentation</title>
|
||||
|
||||
<link rel="stylesheet" href="../../../_static/default.css" type="text/css" />
|
||||
<link rel="stylesheet" href="../../../_static/pygments.css" type="text/css" />
|
||||
@ -16,7 +16,7 @@
|
||||
<script type="text/javascript">
|
||||
var DOCUMENTATION_OPTIONS = {
|
||||
URL_ROOT: '../../../',
|
||||
VERSION: '19.7.10',
|
||||
VERSION: '19.7.11',
|
||||
COLLAPSE_INDEX: false,
|
||||
FILE_SUFFIX: '.html',
|
||||
HAS_SOURCE: true
|
||||
@ -25,7 +25,7 @@
|
||||
<script type="text/javascript" src="../../../_static/jquery.js"></script>
|
||||
<script type="text/javascript" src="../../../_static/underscore.js"></script>
|
||||
<script type="text/javascript" src="../../../_static/doctools.js"></script>
|
||||
<link rel="top" title="Lorax 19.7.10 documentation" href="../../../index.html" />
|
||||
<link rel="top" title="Lorax 19.7.11 documentation" href="../../../index.html" />
|
||||
<link rel="up" title="pylorax.api" href="../api.html" />
|
||||
</head>
|
||||
<body>
|
||||
@ -38,8 +38,9 @@
|
||||
<li class="right" >
|
||||
<a href="../../../py-modindex.html" title="Python Module Index"
|
||||
>modules</a> |</li>
|
||||
<li><a href="../../../index.html">Lorax 19.7.10 documentation</a> »</li>
|
||||
<li><a href="../../../index.html">Lorax 19.7.11 documentation</a> »</li>
|
||||
<li><a href="../../index.html" >Module code</a> »</li>
|
||||
<li><a href="../../pylorax.html" >pylorax</a> »</li>
|
||||
<li><a href="../api.html" accesskey="U">pylorax.api</a> »</li>
|
||||
</ul>
|
||||
</div>
|
||||
@ -1659,13 +1660,14 @@
|
||||
<li class="right" >
|
||||
<a href="../../../py-modindex.html" title="Python Module Index"
|
||||
>modules</a> |</li>
|
||||
<li><a href="../../../index.html">Lorax 19.7.10 documentation</a> »</li>
|
||||
<li><a href="../../../index.html">Lorax 19.7.11 documentation</a> »</li>
|
||||
<li><a href="../../index.html" >Module code</a> »</li>
|
||||
<li><a href="../../pylorax.html" >pylorax</a> »</li>
|
||||
<li><a href="../api.html" >pylorax.api</a> »</li>
|
||||
</ul>
|
||||
</div>
|
||||
<div class="footer">
|
||||
© Copyright 2017, Red Hat, Inc..
|
||||
© Copyright 2018, Red Hat, Inc..
|
||||
Created using <a href="http://sphinx.pocoo.org/">Sphinx</a> 1.1.3.
|
||||
</div>
|
||||
</body>
|
||||
|
@ -8,7 +8,7 @@
|
||||
<head>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
|
||||
|
||||
<title>pylorax.api.workspace — Lorax 19.7.10 documentation</title>
|
||||
<title>pylorax.api.workspace — Lorax 19.7.11 documentation</title>
|
||||
|
||||
<link rel="stylesheet" href="../../../_static/default.css" type="text/css" />
|
||||
<link rel="stylesheet" href="../../../_static/pygments.css" type="text/css" />
|
||||
@ -16,7 +16,7 @@
|
||||
<script type="text/javascript">
|
||||
var DOCUMENTATION_OPTIONS = {
|
||||
URL_ROOT: '../../../',
|
||||
VERSION: '19.7.10',
|
||||
VERSION: '19.7.11',
|
||||
COLLAPSE_INDEX: false,
|
||||
FILE_SUFFIX: '.html',
|
||||
HAS_SOURCE: true
|
||||
@ -25,7 +25,7 @@
|
||||
<script type="text/javascript" src="../../../_static/jquery.js"></script>
|
||||
<script type="text/javascript" src="../../../_static/underscore.js"></script>
|
||||
<script type="text/javascript" src="../../../_static/doctools.js"></script>
|
||||
<link rel="top" title="Lorax 19.7.10 documentation" href="../../../index.html" />
|
||||
<link rel="top" title="Lorax 19.7.11 documentation" href="../../../index.html" />
|
||||
<link rel="up" title="pylorax.api" href="../api.html" />
|
||||
</head>
|
||||
<body>
|
||||
@ -38,8 +38,9 @@
|
||||
<li class="right" >
|
||||
<a href="../../../py-modindex.html" title="Python Module Index"
|
||||
>modules</a> |</li>
|
||||
<li><a href="../../../index.html">Lorax 19.7.10 documentation</a> »</li>
|
||||
<li><a href="../../../index.html">Lorax 19.7.11 documentation</a> »</li>
|
||||
<li><a href="../../index.html" >Module code</a> »</li>
|
||||
<li><a href="../../pylorax.html" >pylorax</a> »</li>
|
||||
<li><a href="../api.html" accesskey="U">pylorax.api</a> »</li>
|
||||
</ul>
|
||||
</div>
|
||||
@ -182,13 +183,14 @@
|
||||
<li class="right" >
|
||||
<a href="../../../py-modindex.html" title="Python Module Index"
|
||||
>modules</a> |</li>
|
||||
<li><a href="../../../index.html">Lorax 19.7.10 documentation</a> »</li>
|
||||
<li><a href="../../../index.html">Lorax 19.7.11 documentation</a> »</li>
|
||||
<li><a href="../../index.html" >Module code</a> »</li>
|
||||
<li><a href="../../pylorax.html" >pylorax</a> »</li>
|
||||
<li><a href="../api.html" >pylorax.api</a> »</li>
|
||||
</ul>
|
||||
</div>
|
||||
<div class="footer">
|
||||
© Copyright 2017, Red Hat, Inc..
|
||||
© Copyright 2018, Red Hat, Inc..
|
||||
Created using <a href="http://sphinx.pocoo.org/">Sphinx</a> 1.1.3.
|
||||
</div>
|
||||
</body>
|
||||
|
@ -8,7 +8,7 @@
|
||||
<head>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
|
||||
|
||||
<title>pylorax.api.yumbase — Lorax 19.7.10 documentation</title>
|
||||
<title>pylorax.api.yumbase — Lorax 19.7.11 documentation</title>
|
||||
|
||||
<link rel="stylesheet" href="../../../_static/default.css" type="text/css" />
|
||||
<link rel="stylesheet" href="../../../_static/pygments.css" type="text/css" />
|
||||
@ -16,7 +16,7 @@
|
||||
<script type="text/javascript">
|
||||
var DOCUMENTATION_OPTIONS = {
|
||||
URL_ROOT: '../../../',
|
||||
VERSION: '19.7.10',
|
||||
VERSION: '19.7.11',
|
||||
COLLAPSE_INDEX: false,
|
||||
FILE_SUFFIX: '.html',
|
||||
HAS_SOURCE: true
|
||||
@ -25,7 +25,7 @@
|
||||
<script type="text/javascript" src="../../../_static/jquery.js"></script>
|
||||
<script type="text/javascript" src="../../../_static/underscore.js"></script>
|
||||
<script type="text/javascript" src="../../../_static/doctools.js"></script>
|
||||
<link rel="top" title="Lorax 19.7.10 documentation" href="../../../index.html" />
|
||||
<link rel="top" title="Lorax 19.7.11 documentation" href="../../../index.html" />
|
||||
<link rel="up" title="pylorax.api" href="../api.html" />
|
||||
</head>
|
||||
<body>
|
||||
@ -38,8 +38,9 @@
|
||||
<li class="right" >
|
||||
<a href="../../../py-modindex.html" title="Python Module Index"
|
||||
>modules</a> |</li>
|
||||
<li><a href="../../../index.html">Lorax 19.7.10 documentation</a> »</li>
|
||||
<li><a href="../../../index.html">Lorax 19.7.11 documentation</a> »</li>
|
||||
<li><a href="../../index.html" >Module code</a> »</li>
|
||||
<li><a href="../../pylorax.html" >pylorax</a> »</li>
|
||||
<li><a href="../api.html" accesskey="U">pylorax.api</a> »</li>
|
||||
</ul>
|
||||
</div>
|
||||
@ -188,13 +189,14 @@
|
||||
<li class="right" >
|
||||
<a href="../../../py-modindex.html" title="Python Module Index"
|
||||
>modules</a> |</li>
|
||||
<li><a href="../../../index.html">Lorax 19.7.10 documentation</a> »</li>
|
||||
<li><a href="../../../index.html">Lorax 19.7.11 documentation</a> »</li>
|
||||
<li><a href="../../index.html" >Module code</a> »</li>
|
||||
<li><a href="../../pylorax.html" >pylorax</a> »</li>
|
||||
<li><a href="../api.html" >pylorax.api</a> »</li>
|
||||
</ul>
|
||||
</div>
|
||||
<div class="footer">
|
||||
© Copyright 2017, Red Hat, Inc..
|
||||
© Copyright 2018, Red Hat, Inc..
|
||||
Created using <a href="http://sphinx.pocoo.org/">Sphinx</a> 1.1.3.
|
||||
</div>
|
||||
</body>
|
||||
|
@ -8,7 +8,7 @@
|
||||
<head>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
|
||||
|
||||
<title>pylorax.base — Lorax 19.7.10 documentation</title>
|
||||
<title>pylorax.base — Lorax 19.7.11 documentation</title>
|
||||
|
||||
<link rel="stylesheet" href="../../_static/default.css" type="text/css" />
|
||||
<link rel="stylesheet" href="../../_static/pygments.css" type="text/css" />
|
||||
@ -16,7 +16,7 @@
|
||||
<script type="text/javascript">
|
||||
var DOCUMENTATION_OPTIONS = {
|
||||
URL_ROOT: '../../',
|
||||
VERSION: '19.7.10',
|
||||
VERSION: '19.7.11',
|
||||
COLLAPSE_INDEX: false,
|
||||
FILE_SUFFIX: '.html',
|
||||
HAS_SOURCE: true
|
||||
@ -25,8 +25,8 @@
|
||||
<script type="text/javascript" src="../../_static/jquery.js"></script>
|
||||
<script type="text/javascript" src="../../_static/underscore.js"></script>
|
||||
<script type="text/javascript" src="../../_static/doctools.js"></script>
|
||||
<link rel="top" title="Lorax 19.7.10 documentation" href="../../index.html" />
|
||||
<link rel="up" title="Module code" href="../index.html" />
|
||||
<link rel="top" title="Lorax 19.7.11 documentation" href="../../index.html" />
|
||||
<link rel="up" title="pylorax" href="../pylorax.html" />
|
||||
</head>
|
||||
<body>
|
||||
<div class="related">
|
||||
@ -38,8 +38,9 @@
|
||||
<li class="right" >
|
||||
<a href="../../py-modindex.html" title="Python Module Index"
|
||||
>modules</a> |</li>
|
||||
<li><a href="../../index.html">Lorax 19.7.10 documentation</a> »</li>
|
||||
<li><a href="../index.html" accesskey="U">Module code</a> »</li>
|
||||
<li><a href="../../index.html">Lorax 19.7.11 documentation</a> »</li>
|
||||
<li><a href="../index.html" >Module code</a> »</li>
|
||||
<li><a href="../pylorax.html" accesskey="U">pylorax</a> »</li>
|
||||
</ul>
|
||||
</div>
|
||||
|
||||
@ -149,12 +150,13 @@
|
||||
<li class="right" >
|
||||
<a href="../../py-modindex.html" title="Python Module Index"
|
||||
>modules</a> |</li>
|
||||
<li><a href="../../index.html">Lorax 19.7.10 documentation</a> »</li>
|
||||
<li><a href="../../index.html">Lorax 19.7.11 documentation</a> »</li>
|
||||
<li><a href="../index.html" >Module code</a> »</li>
|
||||
<li><a href="../pylorax.html" >pylorax</a> »</li>
|
||||
</ul>
|
||||
</div>
|
||||
<div class="footer">
|
||||
© Copyright 2017, Red Hat, Inc..
|
||||
© Copyright 2018, Red Hat, Inc..
|
||||
Created using <a href="http://sphinx.pocoo.org/">Sphinx</a> 1.1.3.
|
||||
</div>
|
||||
</body>
|
||||
|
@ -8,7 +8,7 @@
|
||||
<head>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
|
||||
|
||||
<title>pylorax.buildstamp — Lorax 19.7.10 documentation</title>
|
||||
<title>pylorax.buildstamp — Lorax 19.7.11 documentation</title>
|
||||
|
||||
<link rel="stylesheet" href="../../_static/default.css" type="text/css" />
|
||||
<link rel="stylesheet" href="../../_static/pygments.css" type="text/css" />
|
||||
@ -16,7 +16,7 @@
|
||||
<script type="text/javascript">
|
||||
var DOCUMENTATION_OPTIONS = {
|
||||
URL_ROOT: '../../',
|
||||
VERSION: '19.7.10',
|
||||
VERSION: '19.7.11',
|
||||
COLLAPSE_INDEX: false,
|
||||
FILE_SUFFIX: '.html',
|
||||
HAS_SOURCE: true
|
||||
@ -25,8 +25,8 @@
|
||||
<script type="text/javascript" src="../../_static/jquery.js"></script>
|
||||
<script type="text/javascript" src="../../_static/underscore.js"></script>
|
||||
<script type="text/javascript" src="../../_static/doctools.js"></script>
|
||||
<link rel="top" title="Lorax 19.7.10 documentation" href="../../index.html" />
|
||||
<link rel="up" title="Module code" href="../index.html" />
|
||||
<link rel="top" title="Lorax 19.7.11 documentation" href="../../index.html" />
|
||||
<link rel="up" title="pylorax" href="../pylorax.html" />
|
||||
</head>
|
||||
<body>
|
||||
<div class="related">
|
||||
@ -38,8 +38,9 @@
|
||||
<li class="right" >
|
||||
<a href="../../py-modindex.html" title="Python Module Index"
|
||||
>modules</a> |</li>
|
||||
<li><a href="../../index.html">Lorax 19.7.10 documentation</a> »</li>
|
||||
<li><a href="../index.html" accesskey="U">Module code</a> »</li>
|
||||
<li><a href="../../index.html">Lorax 19.7.11 documentation</a> »</li>
|
||||
<li><a href="../index.html" >Module code</a> »</li>
|
||||
<li><a href="../pylorax.html" accesskey="U">pylorax</a> »</li>
|
||||
</ul>
|
||||
</div>
|
||||
|
||||
@ -140,12 +141,13 @@
|
||||
<li class="right" >
|
||||
<a href="../../py-modindex.html" title="Python Module Index"
|
||||
>modules</a> |</li>
|
||||
<li><a href="../../index.html">Lorax 19.7.10 documentation</a> »</li>
|
||||
<li><a href="../../index.html">Lorax 19.7.11 documentation</a> »</li>
|
||||
<li><a href="../index.html" >Module code</a> »</li>
|
||||
<li><a href="../pylorax.html" >pylorax</a> »</li>
|
||||
</ul>
|
||||
</div>
|
||||
<div class="footer">
|
||||
© Copyright 2017, Red Hat, Inc..
|
||||
© Copyright 2018, Red Hat, Inc..
|
||||
Created using <a href="http://sphinx.pocoo.org/">Sphinx</a> 1.1.3.
|
||||
</div>
|
||||
</body>
|
||||
|
@ -8,7 +8,7 @@
|
||||
<head>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
|
||||
|
||||
<title>pylorax.creator — Lorax 19.7.10 documentation</title>
|
||||
<title>pylorax.creator — Lorax 19.7.11 documentation</title>
|
||||
|
||||
<link rel="stylesheet" href="../../_static/default.css" type="text/css" />
|
||||
<link rel="stylesheet" href="../../_static/pygments.css" type="text/css" />
|
||||
@ -16,7 +16,7 @@
|
||||
<script type="text/javascript">
|
||||
var DOCUMENTATION_OPTIONS = {
|
||||
URL_ROOT: '../../',
|
||||
VERSION: '19.7.10',
|
||||
VERSION: '19.7.11',
|
||||
COLLAPSE_INDEX: false,
|
||||
FILE_SUFFIX: '.html',
|
||||
HAS_SOURCE: true
|
||||
@ -25,8 +25,8 @@
|
||||
<script type="text/javascript" src="../../_static/jquery.js"></script>
|
||||
<script type="text/javascript" src="../../_static/underscore.js"></script>
|
||||
<script type="text/javascript" src="../../_static/doctools.js"></script>
|
||||
<link rel="top" title="Lorax 19.7.10 documentation" href="../../index.html" />
|
||||
<link rel="up" title="Module code" href="../index.html" />
|
||||
<link rel="top" title="Lorax 19.7.11 documentation" href="../../index.html" />
|
||||
<link rel="up" title="pylorax" href="../pylorax.html" />
|
||||
</head>
|
||||
<body>
|
||||
<div class="related">
|
||||
@ -38,8 +38,9 @@
|
||||
<li class="right" >
|
||||
<a href="../../py-modindex.html" title="Python Module Index"
|
||||
>modules</a> |</li>
|
||||
<li><a href="../../index.html">Lorax 19.7.10 documentation</a> »</li>
|
||||
<li><a href="../index.html" accesskey="U">Module code</a> »</li>
|
||||
<li><a href="../../index.html">Lorax 19.7.11 documentation</a> »</li>
|
||||
<li><a href="../index.html" >Module code</a> »</li>
|
||||
<li><a href="../pylorax.html" accesskey="U">pylorax</a> »</li>
|
||||
</ul>
|
||||
</div>
|
||||
|
||||
@ -695,12 +696,13 @@
|
||||
<li class="right" >
|
||||
<a href="../../py-modindex.html" title="Python Module Index"
|
||||
>modules</a> |</li>
|
||||
<li><a href="../../index.html">Lorax 19.7.10 documentation</a> »</li>
|
||||
<li><a href="../../index.html">Lorax 19.7.11 documentation</a> »</li>
|
||||
<li><a href="../index.html" >Module code</a> »</li>
|
||||
<li><a href="../pylorax.html" >pylorax</a> »</li>
|
||||
</ul>
|
||||
</div>
|
||||
<div class="footer">
|
||||
© Copyright 2017, Red Hat, Inc..
|
||||
© Copyright 2018, Red Hat, Inc..
|
||||
Created using <a href="http://sphinx.pocoo.org/">Sphinx</a> 1.1.3.
|
||||
</div>
|
||||
</body>
|
||||
|
@ -8,7 +8,7 @@
|
||||
<head>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
|
||||
|
||||
<title>pylorax.decorators — Lorax 19.7.10 documentation</title>
|
||||
<title>pylorax.decorators — Lorax 19.7.11 documentation</title>
|
||||
|
||||
<link rel="stylesheet" href="../../_static/default.css" type="text/css" />
|
||||
<link rel="stylesheet" href="../../_static/pygments.css" type="text/css" />
|
||||
@ -16,7 +16,7 @@
|
||||
<script type="text/javascript">
|
||||
var DOCUMENTATION_OPTIONS = {
|
||||
URL_ROOT: '../../',
|
||||
VERSION: '19.7.10',
|
||||
VERSION: '19.7.11',
|
||||
COLLAPSE_INDEX: false,
|
||||
FILE_SUFFIX: '.html',
|
||||
HAS_SOURCE: true
|
||||
@ -25,8 +25,8 @@
|
||||
<script type="text/javascript" src="../../_static/jquery.js"></script>
|
||||
<script type="text/javascript" src="../../_static/underscore.js"></script>
|
||||
<script type="text/javascript" src="../../_static/doctools.js"></script>
|
||||
<link rel="top" title="Lorax 19.7.10 documentation" href="../../index.html" />
|
||||
<link rel="up" title="Module code" href="../index.html" />
|
||||
<link rel="top" title="Lorax 19.7.11 documentation" href="../../index.html" />
|
||||
<link rel="up" title="pylorax" href="../pylorax.html" />
|
||||
</head>
|
||||
<body>
|
||||
<div class="related">
|
||||
@ -38,8 +38,9 @@
|
||||
<li class="right" >
|
||||
<a href="../../py-modindex.html" title="Python Module Index"
|
||||
>modules</a> |</li>
|
||||
<li><a href="../../index.html">Lorax 19.7.10 documentation</a> »</li>
|
||||
<li><a href="../index.html" accesskey="U">Module code</a> »</li>
|
||||
<li><a href="../../index.html">Lorax 19.7.11 documentation</a> »</li>
|
||||
<li><a href="../index.html" >Module code</a> »</li>
|
||||
<li><a href="../pylorax.html" accesskey="U">pylorax</a> »</li>
|
||||
</ul>
|
||||
</div>
|
||||
|
||||
@ -112,12 +113,13 @@
|
||||
<li class="right" >
|
||||
<a href="../../py-modindex.html" title="Python Module Index"
|
||||
>modules</a> |</li>
|
||||
<li><a href="../../index.html">Lorax 19.7.10 documentation</a> »</li>
|
||||
<li><a href="../../index.html">Lorax 19.7.11 documentation</a> »</li>
|
||||
<li><a href="../index.html" >Module code</a> »</li>
|
||||
<li><a href="../pylorax.html" >pylorax</a> »</li>
|
||||
</ul>
|
||||
</div>
|
||||
<div class="footer">
|
||||
© Copyright 2017, Red Hat, Inc..
|
||||
© Copyright 2018, Red Hat, Inc..
|
||||
Created using <a href="http://sphinx.pocoo.org/">Sphinx</a> 1.1.3.
|
||||
</div>
|
||||
</body>
|
||||
|
@ -8,7 +8,7 @@
|
||||
<head>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
|
||||
|
||||
<title>pylorax.discinfo — Lorax 19.7.10 documentation</title>
|
||||
<title>pylorax.discinfo — Lorax 19.7.11 documentation</title>
|
||||
|
||||
<link rel="stylesheet" href="../../_static/default.css" type="text/css" />
|
||||
<link rel="stylesheet" href="../../_static/pygments.css" type="text/css" />
|
||||
@ -16,7 +16,7 @@
|
||||
<script type="text/javascript">
|
||||
var DOCUMENTATION_OPTIONS = {
|
||||
URL_ROOT: '../../',
|
||||
VERSION: '19.7.10',
|
||||
VERSION: '19.7.11',
|
||||
COLLAPSE_INDEX: false,
|
||||
FILE_SUFFIX: '.html',
|
||||
HAS_SOURCE: true
|
||||
@ -25,8 +25,8 @@
|
||||
<script type="text/javascript" src="../../_static/jquery.js"></script>
|
||||
<script type="text/javascript" src="../../_static/underscore.js"></script>
|
||||
<script type="text/javascript" src="../../_static/doctools.js"></script>
|
||||
<link rel="top" title="Lorax 19.7.10 documentation" href="../../index.html" />
|
||||
<link rel="up" title="Module code" href="../index.html" />
|
||||
<link rel="top" title="Lorax 19.7.11 documentation" href="../../index.html" />
|
||||
<link rel="up" title="pylorax" href="../pylorax.html" />
|
||||
</head>
|
||||
<body>
|
||||
<div class="related">
|
||||
@ -38,8 +38,9 @@
|
||||
<li class="right" >
|
||||
<a href="../../py-modindex.html" title="Python Module Index"
|
||||
>modules</a> |</li>
|
||||
<li><a href="../../index.html">Lorax 19.7.10 documentation</a> »</li>
|
||||
<li><a href="../index.html" accesskey="U">Module code</a> »</li>
|
||||
<li><a href="../../index.html">Lorax 19.7.11 documentation</a> »</li>
|
||||
<li><a href="../index.html" >Module code</a> »</li>
|
||||
<li><a href="../pylorax.html" accesskey="U">pylorax</a> »</li>
|
||||
</ul>
|
||||
</div>
|
||||
|
||||
@ -121,12 +122,13 @@
|
||||
<li class="right" >
|
||||
<a href="../../py-modindex.html" title="Python Module Index"
|
||||
>modules</a> |</li>
|
||||
<li><a href="../../index.html">Lorax 19.7.10 documentation</a> »</li>
|
||||
<li><a href="../../index.html">Lorax 19.7.11 documentation</a> »</li>
|
||||
<li><a href="../index.html" >Module code</a> »</li>
|
||||
<li><a href="../pylorax.html" >pylorax</a> »</li>
|
||||
</ul>
|
||||
</div>
|
||||
<div class="footer">
|
||||
© Copyright 2017, Red Hat, Inc..
|
||||
© Copyright 2018, Red Hat, Inc..
|
||||
Created using <a href="http://sphinx.pocoo.org/">Sphinx</a> 1.1.3.
|
||||
</div>
|
||||
</body>
|
||||
|
@ -8,7 +8,7 @@
|
||||
<head>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
|
||||
|
||||
<title>pylorax.executils — Lorax 19.7.10 documentation</title>
|
||||
<title>pylorax.executils — Lorax 19.7.11 documentation</title>
|
||||
|
||||
<link rel="stylesheet" href="../../_static/default.css" type="text/css" />
|
||||
<link rel="stylesheet" href="../../_static/pygments.css" type="text/css" />
|
||||
@ -16,7 +16,7 @@
|
||||
<script type="text/javascript">
|
||||
var DOCUMENTATION_OPTIONS = {
|
||||
URL_ROOT: '../../',
|
||||
VERSION: '19.7.10',
|
||||
VERSION: '19.7.11',
|
||||
COLLAPSE_INDEX: false,
|
||||
FILE_SUFFIX: '.html',
|
||||
HAS_SOURCE: true
|
||||
@ -25,8 +25,8 @@
|
||||
<script type="text/javascript" src="../../_static/jquery.js"></script>
|
||||
<script type="text/javascript" src="../../_static/underscore.js"></script>
|
||||
<script type="text/javascript" src="../../_static/doctools.js"></script>
|
||||
<link rel="top" title="Lorax 19.7.10 documentation" href="../../index.html" />
|
||||
<link rel="up" title="Module code" href="../index.html" />
|
||||
<link rel="top" title="Lorax 19.7.11 documentation" href="../../index.html" />
|
||||
<link rel="up" title="pylorax" href="../pylorax.html" />
|
||||
</head>
|
||||
<body>
|
||||
<div class="related">
|
||||
@ -38,8 +38,9 @@
|
||||
<li class="right" >
|
||||
<a href="../../py-modindex.html" title="Python Module Index"
|
||||
>modules</a> |</li>
|
||||
<li><a href="../../index.html">Lorax 19.7.10 documentation</a> »</li>
|
||||
<li><a href="../index.html" accesskey="U">Module code</a> »</li>
|
||||
<li><a href="../../index.html">Lorax 19.7.11 documentation</a> »</li>
|
||||
<li><a href="../index.html" >Module code</a> »</li>
|
||||
<li><a href="../pylorax.html" accesskey="U">pylorax</a> »</li>
|
||||
</ul>
|
||||
</div>
|
||||
|
||||
@ -507,12 +508,13 @@
|
||||
<li class="right" >
|
||||
<a href="../../py-modindex.html" title="Python Module Index"
|
||||
>modules</a> |</li>
|
||||
<li><a href="../../index.html">Lorax 19.7.10 documentation</a> »</li>
|
||||
<li><a href="../../index.html">Lorax 19.7.11 documentation</a> »</li>
|
||||
<li><a href="../index.html" >Module code</a> »</li>
|
||||
<li><a href="../pylorax.html" >pylorax</a> »</li>
|
||||
</ul>
|
||||
</div>
|
||||
<div class="footer">
|
||||
© Copyright 2017, Red Hat, Inc..
|
||||
© Copyright 2018, Red Hat, Inc..
|
||||
Created using <a href="http://sphinx.pocoo.org/">Sphinx</a> 1.1.3.
|
||||
</div>
|
||||
</body>
|
||||
|
@ -8,7 +8,7 @@
|
||||
<head>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
|
||||
|
||||
<title>pylorax.imgutils — Lorax 19.7.10 documentation</title>
|
||||
<title>pylorax.imgutils — Lorax 19.7.11 documentation</title>
|
||||
|
||||
<link rel="stylesheet" href="../../_static/default.css" type="text/css" />
|
||||
<link rel="stylesheet" href="../../_static/pygments.css" type="text/css" />
|
||||
@ -16,7 +16,7 @@
|
||||
<script type="text/javascript">
|
||||
var DOCUMENTATION_OPTIONS = {
|
||||
URL_ROOT: '../../',
|
||||
VERSION: '19.7.10',
|
||||
VERSION: '19.7.11',
|
||||
COLLAPSE_INDEX: false,
|
||||
FILE_SUFFIX: '.html',
|
||||
HAS_SOURCE: true
|
||||
@ -25,8 +25,8 @@
|
||||
<script type="text/javascript" src="../../_static/jquery.js"></script>
|
||||
<script type="text/javascript" src="../../_static/underscore.js"></script>
|
||||
<script type="text/javascript" src="../../_static/doctools.js"></script>
|
||||
<link rel="top" title="Lorax 19.7.10 documentation" href="../../index.html" />
|
||||
<link rel="up" title="Module code" href="../index.html" />
|
||||
<link rel="top" title="Lorax 19.7.11 documentation" href="../../index.html" />
|
||||
<link rel="up" title="pylorax" href="../pylorax.html" />
|
||||
</head>
|
||||
<body>
|
||||
<div class="related">
|
||||
@ -38,8 +38,9 @@
|
||||
<li class="right" >
|
||||
<a href="../../py-modindex.html" title="Python Module Index"
|
||||
>modules</a> |</li>
|
||||
<li><a href="../../index.html">Lorax 19.7.10 documentation</a> »</li>
|
||||
<li><a href="../index.html" accesskey="U">Module code</a> »</li>
|
||||
<li><a href="../../index.html">Lorax 19.7.11 documentation</a> »</li>
|
||||
<li><a href="../index.html" >Module code</a> »</li>
|
||||
<li><a href="../pylorax.html" accesskey="U">pylorax</a> »</li>
|
||||
</ul>
|
||||
</div>
|
||||
|
||||
@ -547,12 +548,13 @@
|
||||
<li class="right" >
|
||||
<a href="../../py-modindex.html" title="Python Module Index"
|
||||
>modules</a> |</li>
|
||||
<li><a href="../../index.html">Lorax 19.7.10 documentation</a> »</li>
|
||||
<li><a href="../../index.html">Lorax 19.7.11 documentation</a> »</li>
|
||||
<li><a href="../index.html" >Module code</a> »</li>
|
||||
<li><a href="../pylorax.html" >pylorax</a> »</li>
|
||||
</ul>
|
||||
</div>
|
||||
<div class="footer">
|
||||
© Copyright 2017, Red Hat, Inc..
|
||||
© Copyright 2018, Red Hat, Inc..
|
||||
Created using <a href="http://sphinx.pocoo.org/">Sphinx</a> 1.1.3.
|
||||
</div>
|
||||
</body>
|
||||
|
@ -8,7 +8,7 @@
|
||||
<head>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
|
||||
|
||||
<title>pylorax.installer — Lorax 19.7.10 documentation</title>
|
||||
<title>pylorax.installer — Lorax 19.7.11 documentation</title>
|
||||
|
||||
<link rel="stylesheet" href="../../_static/default.css" type="text/css" />
|
||||
<link rel="stylesheet" href="../../_static/pygments.css" type="text/css" />
|
||||
@ -16,7 +16,7 @@
|
||||
<script type="text/javascript">
|
||||
var DOCUMENTATION_OPTIONS = {
|
||||
URL_ROOT: '../../',
|
||||
VERSION: '19.7.10',
|
||||
VERSION: '19.7.11',
|
||||
COLLAPSE_INDEX: false,
|
||||
FILE_SUFFIX: '.html',
|
||||
HAS_SOURCE: true
|
||||
@ -25,8 +25,8 @@
|
||||
<script type="text/javascript" src="../../_static/jquery.js"></script>
|
||||
<script type="text/javascript" src="../../_static/underscore.js"></script>
|
||||
<script type="text/javascript" src="../../_static/doctools.js"></script>
|
||||
<link rel="top" title="Lorax 19.7.10 documentation" href="../../index.html" />
|
||||
<link rel="up" title="Module code" href="../index.html" />
|
||||
<link rel="top" title="Lorax 19.7.11 documentation" href="../../index.html" />
|
||||
<link rel="up" title="pylorax" href="../pylorax.html" />
|
||||
</head>
|
||||
<body>
|
||||
<div class="related">
|
||||
@ -38,8 +38,9 @@
|
||||
<li class="right" >
|
||||
<a href="../../py-modindex.html" title="Python Module Index"
|
||||
>modules</a> |</li>
|
||||
<li><a href="../../index.html">Lorax 19.7.10 documentation</a> »</li>
|
||||
<li><a href="../index.html" accesskey="U">Module code</a> »</li>
|
||||
<li><a href="../../index.html">Lorax 19.7.11 documentation</a> »</li>
|
||||
<li><a href="../index.html" >Module code</a> »</li>
|
||||
<li><a href="../pylorax.html" accesskey="U">pylorax</a> »</li>
|
||||
</ul>
|
||||
</div>
|
||||
|
||||
@ -470,12 +471,13 @@
|
||||
<li class="right" >
|
||||
<a href="../../py-modindex.html" title="Python Module Index"
|
||||
>modules</a> |</li>
|
||||
<li><a href="../../index.html">Lorax 19.7.10 documentation</a> »</li>
|
||||
<li><a href="../../index.html">Lorax 19.7.11 documentation</a> »</li>
|
||||
<li><a href="../index.html" >Module code</a> »</li>
|
||||
<li><a href="../pylorax.html" >pylorax</a> »</li>
|
||||
</ul>
|
||||
</div>
|
||||
<div class="footer">
|
||||
© Copyright 2017, Red Hat, Inc..
|
||||
© Copyright 2018, Red Hat, Inc..
|
||||
Created using <a href="http://sphinx.pocoo.org/">Sphinx</a> 1.1.3.
|
||||
</div>
|
||||
</body>
|
||||
|
@ -8,7 +8,7 @@
|
||||
<head>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
|
||||
|
||||
<title>pylorax.logmonitor — Lorax 19.7.10 documentation</title>
|
||||
<title>pylorax.logmonitor — Lorax 19.7.11 documentation</title>
|
||||
|
||||
<link rel="stylesheet" href="../../_static/default.css" type="text/css" />
|
||||
<link rel="stylesheet" href="../../_static/pygments.css" type="text/css" />
|
||||
@ -16,7 +16,7 @@
|
||||
<script type="text/javascript">
|
||||
var DOCUMENTATION_OPTIONS = {
|
||||
URL_ROOT: '../../',
|
||||
VERSION: '19.7.10',
|
||||
VERSION: '19.7.11',
|
||||
COLLAPSE_INDEX: false,
|
||||
FILE_SUFFIX: '.html',
|
||||
HAS_SOURCE: true
|
||||
@ -25,8 +25,8 @@
|
||||
<script type="text/javascript" src="../../_static/jquery.js"></script>
|
||||
<script type="text/javascript" src="../../_static/underscore.js"></script>
|
||||
<script type="text/javascript" src="../../_static/doctools.js"></script>
|
||||
<link rel="top" title="Lorax 19.7.10 documentation" href="../../index.html" />
|
||||
<link rel="up" title="Module code" href="../index.html" />
|
||||
<link rel="top" title="Lorax 19.7.11 documentation" href="../../index.html" />
|
||||
<link rel="up" title="pylorax" href="../pylorax.html" />
|
||||
</head>
|
||||
<body>
|
||||
<div class="related">
|
||||
@ -38,8 +38,9 @@
|
||||
<li class="right" >
|
||||
<a href="../../py-modindex.html" title="Python Module Index"
|
||||
>modules</a> |</li>
|
||||
<li><a href="../../index.html">Lorax 19.7.10 documentation</a> »</li>
|
||||
<li><a href="../index.html" accesskey="U">Module code</a> »</li>
|
||||
<li><a href="../../index.html">Lorax 19.7.11 documentation</a> »</li>
|
||||
<li><a href="../index.html" >Module code</a> »</li>
|
||||
<li><a href="../pylorax.html" accesskey="U">pylorax</a> »</li>
|
||||
</ul>
|
||||
</div>
|
||||
|
||||
@ -205,12 +206,13 @@
|
||||
<li class="right" >
|
||||
<a href="../../py-modindex.html" title="Python Module Index"
|
||||
>modules</a> |</li>
|
||||
<li><a href="../../index.html">Lorax 19.7.10 documentation</a> »</li>
|
||||
<li><a href="../../index.html">Lorax 19.7.11 documentation</a> »</li>
|
||||
<li><a href="../index.html" >Module code</a> »</li>
|
||||
<li><a href="../pylorax.html" >pylorax</a> »</li>
|
||||
</ul>
|
||||
</div>
|
||||
<div class="footer">
|
||||
© Copyright 2017, Red Hat, Inc..
|
||||
© Copyright 2018, Red Hat, Inc..
|
||||
Created using <a href="http://sphinx.pocoo.org/">Sphinx</a> 1.1.3.
|
||||
</div>
|
||||
</body>
|
||||
|
@ -8,7 +8,7 @@
|
||||
<head>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
|
||||
|
||||
<title>pylorax.ltmpl — Lorax 19.7.10 documentation</title>
|
||||
<title>pylorax.ltmpl — Lorax 19.7.11 documentation</title>
|
||||
|
||||
<link rel="stylesheet" href="../../_static/default.css" type="text/css" />
|
||||
<link rel="stylesheet" href="../../_static/pygments.css" type="text/css" />
|
||||
@ -16,7 +16,7 @@
|
||||
<script type="text/javascript">
|
||||
var DOCUMENTATION_OPTIONS = {
|
||||
URL_ROOT: '../../',
|
||||
VERSION: '19.7.10',
|
||||
VERSION: '19.7.11',
|
||||
COLLAPSE_INDEX: false,
|
||||
FILE_SUFFIX: '.html',
|
||||
HAS_SOURCE: true
|
||||
@ -25,8 +25,8 @@
|
||||
<script type="text/javascript" src="../../_static/jquery.js"></script>
|
||||
<script type="text/javascript" src="../../_static/underscore.js"></script>
|
||||
<script type="text/javascript" src="../../_static/doctools.js"></script>
|
||||
<link rel="top" title="Lorax 19.7.10 documentation" href="../../index.html" />
|
||||
<link rel="up" title="Module code" href="../index.html" />
|
||||
<link rel="top" title="Lorax 19.7.11 documentation" href="../../index.html" />
|
||||
<link rel="up" title="pylorax" href="../pylorax.html" />
|
||||
</head>
|
||||
<body>
|
||||
<div class="related">
|
||||
@ -38,8 +38,9 @@
|
||||
<li class="right" >
|
||||
<a href="../../py-modindex.html" title="Python Module Index"
|
||||
>modules</a> |</li>
|
||||
<li><a href="../../index.html">Lorax 19.7.10 documentation</a> »</li>
|
||||
<li><a href="../index.html" accesskey="U">Module code</a> »</li>
|
||||
<li><a href="../../index.html">Lorax 19.7.11 documentation</a> »</li>
|
||||
<li><a href="../index.html" >Module code</a> »</li>
|
||||
<li><a href="../pylorax.html" accesskey="U">pylorax</a> »</li>
|
||||
</ul>
|
||||
</div>
|
||||
|
||||
@ -747,12 +748,13 @@
|
||||
<li class="right" >
|
||||
<a href="../../py-modindex.html" title="Python Module Index"
|
||||
>modules</a> |</li>
|
||||
<li><a href="../../index.html">Lorax 19.7.10 documentation</a> »</li>
|
||||
<li><a href="../../index.html">Lorax 19.7.11 documentation</a> »</li>
|
||||
<li><a href="../index.html" >Module code</a> »</li>
|
||||
<li><a href="../pylorax.html" >pylorax</a> »</li>
|
||||
</ul>
|
||||
</div>
|
||||
<div class="footer">
|
||||
© Copyright 2017, Red Hat, Inc..
|
||||
© Copyright 2018, Red Hat, Inc..
|
||||
Created using <a href="http://sphinx.pocoo.org/">Sphinx</a> 1.1.3.
|
||||
</div>
|
||||
</body>
|
||||
|
@ -8,7 +8,7 @@
|
||||
<head>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
|
||||
|
||||
<title>pylorax.sysutils — Lorax 19.7.10 documentation</title>
|
||||
<title>pylorax.sysutils — Lorax 19.7.11 documentation</title>
|
||||
|
||||
<link rel="stylesheet" href="../../_static/default.css" type="text/css" />
|
||||
<link rel="stylesheet" href="../../_static/pygments.css" type="text/css" />
|
||||
@ -16,7 +16,7 @@
|
||||
<script type="text/javascript">
|
||||
var DOCUMENTATION_OPTIONS = {
|
||||
URL_ROOT: '../../',
|
||||
VERSION: '19.7.10',
|
||||
VERSION: '19.7.11',
|
||||
COLLAPSE_INDEX: false,
|
||||
FILE_SUFFIX: '.html',
|
||||
HAS_SOURCE: true
|
||||
@ -25,8 +25,8 @@
|
||||
<script type="text/javascript" src="../../_static/jquery.js"></script>
|
||||
<script type="text/javascript" src="../../_static/underscore.js"></script>
|
||||
<script type="text/javascript" src="../../_static/doctools.js"></script>
|
||||
<link rel="top" title="Lorax 19.7.10 documentation" href="../../index.html" />
|
||||
<link rel="up" title="Module code" href="../index.html" />
|
||||
<link rel="top" title="Lorax 19.7.11 documentation" href="../../index.html" />
|
||||
<link rel="up" title="pylorax" href="../pylorax.html" />
|
||||
</head>
|
||||
<body>
|
||||
<div class="related">
|
||||
@ -38,8 +38,9 @@
|
||||
<li class="right" >
|
||||
<a href="../../py-modindex.html" title="Python Module Index"
|
||||
>modules</a> |</li>
|
||||
<li><a href="../../index.html">Lorax 19.7.10 documentation</a> »</li>
|
||||
<li><a href="../index.html" accesskey="U">Module code</a> »</li>
|
||||
<li><a href="../../index.html">Lorax 19.7.11 documentation</a> »</li>
|
||||
<li><a href="../index.html" >Module code</a> »</li>
|
||||
<li><a href="../pylorax.html" accesskey="U">pylorax</a> »</li>
|
||||
</ul>
|
||||
</div>
|
||||
|
||||
@ -190,12 +191,13 @@
|
||||
<li class="right" >
|
||||
<a href="../../py-modindex.html" title="Python Module Index"
|
||||
>modules</a> |</li>
|
||||
<li><a href="../../index.html">Lorax 19.7.10 documentation</a> »</li>
|
||||
<li><a href="../../index.html">Lorax 19.7.11 documentation</a> »</li>
|
||||
<li><a href="../index.html" >Module code</a> »</li>
|
||||
<li><a href="../pylorax.html" >pylorax</a> »</li>
|
||||
</ul>
|
||||
</div>
|
||||
<div class="footer">
|
||||
© Copyright 2017, Red Hat, Inc..
|
||||
© Copyright 2018, Red Hat, Inc..
|
||||
Created using <a href="http://sphinx.pocoo.org/">Sphinx</a> 1.1.3.
|
||||
</div>
|
||||
</body>
|
||||
|
@ -8,7 +8,7 @@
|
||||
<head>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
|
||||
|
||||
<title>pylorax.treebuilder — Lorax 19.7.10 documentation</title>
|
||||
<title>pylorax.treebuilder — Lorax 19.7.11 documentation</title>
|
||||
|
||||
<link rel="stylesheet" href="../../_static/default.css" type="text/css" />
|
||||
<link rel="stylesheet" href="../../_static/pygments.css" type="text/css" />
|
||||
@ -16,7 +16,7 @@
|
||||
<script type="text/javascript">
|
||||
var DOCUMENTATION_OPTIONS = {
|
||||
URL_ROOT: '../../',
|
||||
VERSION: '19.7.10',
|
||||
VERSION: '19.7.11',
|
||||
COLLAPSE_INDEX: false,
|
||||
FILE_SUFFIX: '.html',
|
||||
HAS_SOURCE: true
|
||||
@ -25,8 +25,8 @@
|
||||
<script type="text/javascript" src="../../_static/jquery.js"></script>
|
||||
<script type="text/javascript" src="../../_static/underscore.js"></script>
|
||||
<script type="text/javascript" src="../../_static/doctools.js"></script>
|
||||
<link rel="top" title="Lorax 19.7.10 documentation" href="../../index.html" />
|
||||
<link rel="up" title="Module code" href="../index.html" />
|
||||
<link rel="top" title="Lorax 19.7.11 documentation" href="../../index.html" />
|
||||
<link rel="up" title="pylorax" href="../pylorax.html" />
|
||||
</head>
|
||||
<body>
|
||||
<div class="related">
|
||||
@ -38,8 +38,9 @@
|
||||
<li class="right" >
|
||||
<a href="../../py-modindex.html" title="Python Module Index"
|
||||
>modules</a> |</li>
|
||||
<li><a href="../../index.html">Lorax 19.7.10 documentation</a> »</li>
|
||||
<li><a href="../index.html" accesskey="U">Module code</a> »</li>
|
||||
<li><a href="../../index.html">Lorax 19.7.11 documentation</a> »</li>
|
||||
<li><a href="../index.html" >Module code</a> »</li>
|
||||
<li><a href="../pylorax.html" accesskey="U">pylorax</a> »</li>
|
||||
</ul>
|
||||
</div>
|
||||
|
||||
@ -402,12 +403,13 @@
|
||||
<li class="right" >
|
||||
<a href="../../py-modindex.html" title="Python Module Index"
|
||||
>modules</a> |</li>
|
||||
<li><a href="../../index.html">Lorax 19.7.10 documentation</a> »</li>
|
||||
<li><a href="../../index.html">Lorax 19.7.11 documentation</a> »</li>
|
||||
<li><a href="../index.html" >Module code</a> »</li>
|
||||
<li><a href="../pylorax.html" >pylorax</a> »</li>
|
||||
</ul>
|
||||
</div>
|
||||
<div class="footer">
|
||||
© Copyright 2017, Red Hat, Inc..
|
||||
© Copyright 2018, Red Hat, Inc..
|
||||
Created using <a href="http://sphinx.pocoo.org/">Sphinx</a> 1.1.3.
|
||||
</div>
|
||||
</body>
|
||||
|
@ -8,7 +8,7 @@
|
||||
<head>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
|
||||
|
||||
<title>pylorax.treeinfo — Lorax 19.7.10 documentation</title>
|
||||
<title>pylorax.treeinfo — Lorax 19.7.11 documentation</title>
|
||||
|
||||
<link rel="stylesheet" href="../../_static/default.css" type="text/css" />
|
||||
<link rel="stylesheet" href="../../_static/pygments.css" type="text/css" />
|
||||
@ -16,7 +16,7 @@
|
||||
<script type="text/javascript">
|
||||
var DOCUMENTATION_OPTIONS = {
|
||||
URL_ROOT: '../../',
|
||||
VERSION: '19.7.10',
|
||||
VERSION: '19.7.11',
|
||||
COLLAPSE_INDEX: false,
|
||||
FILE_SUFFIX: '.html',
|
||||
HAS_SOURCE: true
|
||||
@ -25,8 +25,8 @@
|
||||
<script type="text/javascript" src="../../_static/jquery.js"></script>
|
||||
<script type="text/javascript" src="../../_static/underscore.js"></script>
|
||||
<script type="text/javascript" src="../../_static/doctools.js"></script>
|
||||
<link rel="top" title="Lorax 19.7.10 documentation" href="../../index.html" />
|
||||
<link rel="up" title="Module code" href="../index.html" />
|
||||
<link rel="top" title="Lorax 19.7.11 documentation" href="../../index.html" />
|
||||
<link rel="up" title="pylorax" href="../pylorax.html" />
|
||||
</head>
|
||||
<body>
|
||||
<div class="related">
|
||||
@ -38,8 +38,9 @@
|
||||
<li class="right" >
|
||||
<a href="../../py-modindex.html" title="Python Module Index"
|
||||
>modules</a> |</li>
|
||||
<li><a href="../../index.html">Lorax 19.7.10 documentation</a> »</li>
|
||||
<li><a href="../index.html" accesskey="U">Module code</a> »</li>
|
||||
<li><a href="../../index.html">Lorax 19.7.11 documentation</a> »</li>
|
||||
<li><a href="../index.html" >Module code</a> »</li>
|
||||
<li><a href="../pylorax.html" accesskey="U">pylorax</a> »</li>
|
||||
</ul>
|
||||
</div>
|
||||
|
||||
@ -139,12 +140,13 @@
|
||||
<li class="right" >
|
||||
<a href="../../py-modindex.html" title="Python Module Index"
|
||||
>modules</a> |</li>
|
||||
<li><a href="../../index.html">Lorax 19.7.10 documentation</a> »</li>
|
||||
<li><a href="../../index.html">Lorax 19.7.11 documentation</a> »</li>
|
||||
<li><a href="../index.html" >Module code</a> »</li>
|
||||
<li><a href="../pylorax.html" >pylorax</a> »</li>
|
||||
</ul>
|
||||
</div>
|
||||
<div class="footer">
|
||||
© Copyright 2017, Red Hat, Inc..
|
||||
© Copyright 2018, Red Hat, Inc..
|
||||
Created using <a href="http://sphinx.pocoo.org/">Sphinx</a> 1.1.3.
|
||||
</div>
|
||||
</body>
|
||||
|
@ -8,7 +8,7 @@
|
||||
<head>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
|
||||
|
||||
<title>pylorax.yumhelper — Lorax 19.7.10 documentation</title>
|
||||
<title>pylorax.yumhelper — Lorax 19.7.11 documentation</title>
|
||||
|
||||
<link rel="stylesheet" href="../../_static/default.css" type="text/css" />
|
||||
<link rel="stylesheet" href="../../_static/pygments.css" type="text/css" />
|
||||
@ -16,7 +16,7 @@
|
||||
<script type="text/javascript">
|
||||
var DOCUMENTATION_OPTIONS = {
|
||||
URL_ROOT: '../../',
|
||||
VERSION: '19.7.10',
|
||||
VERSION: '19.7.11',
|
||||
COLLAPSE_INDEX: false,
|
||||
FILE_SUFFIX: '.html',
|
||||
HAS_SOURCE: true
|
||||
@ -25,8 +25,8 @@
|
||||
<script type="text/javascript" src="../../_static/jquery.js"></script>
|
||||
<script type="text/javascript" src="../../_static/underscore.js"></script>
|
||||
<script type="text/javascript" src="../../_static/doctools.js"></script>
|
||||
<link rel="top" title="Lorax 19.7.10 documentation" href="../../index.html" />
|
||||
<link rel="up" title="Module code" href="../index.html" />
|
||||
<link rel="top" title="Lorax 19.7.11 documentation" href="../../index.html" />
|
||||
<link rel="up" title="pylorax" href="../pylorax.html" />
|
||||
</head>
|
||||
<body>
|
||||
<div class="related">
|
||||
@ -38,8 +38,9 @@
|
||||
<li class="right" >
|
||||
<a href="../../py-modindex.html" title="Python Module Index"
|
||||
>modules</a> |</li>
|
||||
<li><a href="../../index.html">Lorax 19.7.10 documentation</a> »</li>
|
||||
<li><a href="../index.html" accesskey="U">Module code</a> »</li>
|
||||
<li><a href="../../index.html">Lorax 19.7.11 documentation</a> »</li>
|
||||
<li><a href="../index.html" >Module code</a> »</li>
|
||||
<li><a href="../pylorax.html" accesskey="U">pylorax</a> »</li>
|
||||
</ul>
|
||||
</div>
|
||||
|
||||
@ -207,12 +208,13 @@
|
||||
<li class="right" >
|
||||
<a href="../../py-modindex.html" title="Python Module Index"
|
||||
>modules</a> |</li>
|
||||
<li><a href="../../index.html">Lorax 19.7.10 documentation</a> »</li>
|
||||
<li><a href="../../index.html">Lorax 19.7.11 documentation</a> »</li>
|
||||
<li><a href="../index.html" >Module code</a> »</li>
|
||||
<li><a href="../pylorax.html" >pylorax</a> »</li>
|
||||
</ul>
|
||||
</div>
|
||||
<div class="footer">
|
||||
© Copyright 2017, Red Hat, Inc..
|
||||
© Copyright 2018, Red Hat, Inc..
|
||||
Created using <a href="http://sphinx.pocoo.org/">Sphinx</a> 1.1.3.
|
||||
</div>
|
||||
</body>
|
||||
|
51
lorax-composer/_sources/composer.cli.txt
Normal file
51
lorax-composer/_sources/composer.cli.txt
Normal file
@ -0,0 +1,51 @@
|
||||
cli Package
|
||||
===========
|
||||
|
||||
:mod:`cli` Package
|
||||
------------------
|
||||
|
||||
.. automodule:: composer.cli
|
||||
:members:
|
||||
:undoc-members:
|
||||
:show-inheritance:
|
||||
|
||||
:mod:`compose` Module
|
||||
---------------------
|
||||
|
||||
.. automodule:: composer.cli.compose
|
||||
:members:
|
||||
:undoc-members:
|
||||
:show-inheritance:
|
||||
|
||||
:mod:`modules` Module
|
||||
---------------------
|
||||
|
||||
.. automodule:: composer.cli.modules
|
||||
:members:
|
||||
:undoc-members:
|
||||
:show-inheritance:
|
||||
|
||||
:mod:`projects` Module
|
||||
----------------------
|
||||
|
||||
.. automodule:: composer.cli.projects
|
||||
:members:
|
||||
:undoc-members:
|
||||
:show-inheritance:
|
||||
|
||||
:mod:`recipes` Module
|
||||
---------------------
|
||||
|
||||
.. automodule:: composer.cli.recipes
|
||||
:members:
|
||||
:undoc-members:
|
||||
:show-inheritance:
|
||||
|
||||
:mod:`utilities` Module
|
||||
-----------------------
|
||||
|
||||
.. automodule:: composer.cli.utilities
|
||||
:members:
|
||||
:undoc-members:
|
||||
:show-inheritance:
|
||||
|
34
lorax-composer/_sources/composer.txt
Normal file
34
lorax-composer/_sources/composer.txt
Normal file
@ -0,0 +1,34 @@
|
||||
composer Package
|
||||
================
|
||||
|
||||
:mod:`composer` Package
|
||||
-----------------------
|
||||
|
||||
.. automodule:: composer
|
||||
:members:
|
||||
:undoc-members:
|
||||
:show-inheritance:
|
||||
|
||||
:mod:`http_client` Module
|
||||
-------------------------
|
||||
|
||||
.. automodule:: composer.http_client
|
||||
:members:
|
||||
:undoc-members:
|
||||
:show-inheritance:
|
||||
|
||||
:mod:`unix_socket` Module
|
||||
-------------------------
|
||||
|
||||
.. automodule:: composer.unix_socket
|
||||
:members:
|
||||
:undoc-members:
|
||||
:show-inheritance:
|
||||
|
||||
Subpackages
|
||||
-----------
|
||||
|
||||
.. toctree::
|
||||
|
||||
composer.cli
|
||||
|
391
lorax-composer/_sources/livemedia-creator.txt
Normal file
391
lorax-composer/_sources/livemedia-creator.txt
Normal file
@ -0,0 +1,391 @@
|
||||
livemedia-creator
|
||||
=================
|
||||
|
||||
:Authors:
|
||||
Brian C. Lane <bcl@redhat.com>
|
||||
|
||||
livemedia-creator uses `Anaconda <https://github.com/rhinstaller/anaconda>`_,
|
||||
`kickstart <https://github.com/rhinstaller/pykickstart>`_ and `Lorax
|
||||
<https://github.com/rhinstaller/lorax>`_ to create bootable media that use the
|
||||
same install path as a normal system installation. It can be used to make live
|
||||
isos, bootable (partitioned) disk images, tarfiles, and filesystem images for
|
||||
use with virtualization and container solutions like libvirt, docker, and
|
||||
OpenStack.
|
||||
|
||||
The general idea is to use virt-install with kickstart and an Anaconda boot.iso to
|
||||
install into a disk image and then use the disk image to create the bootable
|
||||
media.
|
||||
|
||||
livemedia-creator --help will describe all of the options available. At the
|
||||
minimum you need:
|
||||
|
||||
``--make-iso`` to create a final bootable .iso or one of the other ``--make-*`` options.
|
||||
|
||||
``--iso`` to specify the Anaconda install media to use with virt-install.
|
||||
|
||||
``--ks`` to select the kickstart file describing what to install.
|
||||
|
||||
To use livemedia-creator with virtualization you will need to have virt-install installed.
|
||||
|
||||
If you are going to be using Anaconda directly, with ``--no-virt`` mode, make sure
|
||||
you have the anaconda-tui package installed.
|
||||
|
||||
Conventions used in this document:
|
||||
|
||||
``lmc`` is an abbreviation for livemedia-creator.
|
||||
|
||||
``builder`` is the system where livemedia-creator is being run
|
||||
|
||||
``image`` is the disk image being created by running livemedia-creator
|
||||
|
||||
|
||||
livemedia-creator cmdline arguments
|
||||
-----------------------------------
|
||||
|
||||
See the output from ``livemedia-creator --help`` for the commandline arguments.
|
||||
|
||||
Quickstart
|
||||
----------
|
||||
|
||||
Run this to create a bootable live iso::
|
||||
|
||||
sudo livemedia-creator --make-iso \
|
||||
--iso=/extra/iso/boot.iso --ks=./docs/rhel7-livemedia.ks
|
||||
|
||||
You can run it directly from the lorax git repo like this::
|
||||
|
||||
sudo PATH=./src/sbin/:$PATH PYTHONPATH=./src/ ./src/sbin/livemedia-creator \
|
||||
--make-iso --iso=/extra/iso/boot.iso \
|
||||
--ks=./docs/rhel7-livemedia.ks --lorax-templates=./share/
|
||||
|
||||
You can observe the installation using vnc. The logs will show what port was
|
||||
chosen, or you can use a specific port by passing it. eg. ``--vnc vnc:127.0.0.1:5``
|
||||
|
||||
This is usually a good idea when testing changes to the kickstart. lmc tries
|
||||
to monitor the logs for fatal errors, but may not catch everything.
|
||||
|
||||
|
||||
How ISO creation works
|
||||
----------------------
|
||||
|
||||
There are 2 stages, the install stage which produces a disk or filesystem image
|
||||
as its output, and the boot media creation which uses the image as its input.
|
||||
Normally you would run both stages, but it is possible to stop after the
|
||||
install stage, by using ``--image-only``, or to skip the install stage and use
|
||||
a previously created disk image by passing ``--disk-image`` or ``--fs-image``
|
||||
|
||||
When creating an iso virt-install boots using the passed Anaconda installer iso
|
||||
and installs the system based on the kickstart. The ``%post`` section of the
|
||||
kickstart is used to customize the installed system in the same way that
|
||||
current spin-kickstarts do.
|
||||
|
||||
livemedia-creator monitors the install process for problems by watching the
|
||||
install logs. They are written to the current directory or to the base
|
||||
directory specified by the --logfile command. You can also monitor the install
|
||||
by using a vnc client. This is recommended when first modifying a kickstart,
|
||||
since there are still places where Anaconda may get stuck without the log
|
||||
monitor catching it.
|
||||
|
||||
The output from this process is a partitioned disk image. kpartx can be used
|
||||
to mount and examine it when there is a problem with the install. It can also
|
||||
be booted using kvm.
|
||||
|
||||
When creating an iso the disk image's / partition is copied into a formatted
|
||||
filesystem image which is then used as the input to lorax for creation of the
|
||||
final media.
|
||||
|
||||
The final image is created by lorax, using the templates in /usr/share/lorax/live/
|
||||
or the live directory below the directory specified by ``--lorax-templates``. The
|
||||
templates are written using the Mako template system with some extra commands
|
||||
added by lorax.
|
||||
|
||||
|
||||
Kickstarts
|
||||
----------
|
||||
|
||||
The docs/ directory includes several example kickstarts, one to create a live
|
||||
desktop iso using GNOME, and another to create a minimal disk image. When
|
||||
creating your own kickstarts you should start with the minimal example, it
|
||||
includes several needed packages that are not always included by dependencies.
|
||||
|
||||
Or you can use existing spin kickstarts to create live media with a few
|
||||
changes. Here are the steps I used to convert the Fedora XFCE spin.
|
||||
|
||||
1. Flatten the xfce kickstart using ksflatten
|
||||
2. Add zerombr so you don't get the disk init dialog
|
||||
3. Add clearpart --all
|
||||
4. Add swap partition
|
||||
5. bootloader target
|
||||
6. Add shutdown to the kickstart
|
||||
7. Add network --bootproto=dhcp --activate to activate the network
|
||||
This works for F16 builds but for F15 and before you need to pass
|
||||
something on the cmdline that activate the network, like sshd:
|
||||
|
||||
``livemedia-creator --kernel-args="sshd"``
|
||||
|
||||
8. Add a root password::
|
||||
|
||||
rootpw rootme
|
||||
network --bootproto=dhcp --activate
|
||||
zerombr
|
||||
clearpart --all
|
||||
bootloader --location=mbr
|
||||
part swap --size=512
|
||||
shutdown
|
||||
|
||||
9. In the livesys script section of the %post remove the root password. This
|
||||
really depends on how the spin wants to work. You could add the live user
|
||||
that you create to the %wheel group so that sudo works if you wanted to.
|
||||
|
||||
``passwd -d root > /dev/null``
|
||||
|
||||
10. Remove /etc/fstab in %post, dracut handles mounting the rootfs
|
||||
|
||||
``cat /dev/null > /dev/fstab``
|
||||
|
||||
Do this only for live iso's, the filesystem will be mounted read only if
|
||||
there is no /etc/fstab
|
||||
|
||||
11. Don't delete initramfs files from /boot in %post
|
||||
12. When creating live iso's you need to have, at least, these packages in the %package section::
|
||||
dracut-config-generic
|
||||
dracut-live
|
||||
-dracut-config-rescue
|
||||
grub-efi
|
||||
memtest86+
|
||||
syslinux
|
||||
|
||||
One drawback to using virt-install is that it pulls the packages from the repo
|
||||
each time you run it. To speed things up you either need a local mirror of the
|
||||
packages, or you can use a caching proxy. When using a proxy you pass it to
|
||||
livemedia-creator like this:
|
||||
|
||||
``--proxy=http://proxy.yourdomain.com:3128``
|
||||
|
||||
You also need to use a specific mirror instead of mirrormanager so that the
|
||||
packages will get cached, so your kickstart url would look like:
|
||||
|
||||
``url --url="http://dl.fedoraproject.org/pub/fedora/linux/development/rawhide/x86_64/os/"``
|
||||
|
||||
You can also add an update repo, but don't name it updates. Add --proxy to it
|
||||
as well.
|
||||
|
||||
|
||||
Anaconda image install (no-virt)
|
||||
--------------------------------
|
||||
|
||||
You can create images without using virt-install by passing ``--no-virt`` on
|
||||
the cmdline. This will use Anaconda's directory install feature to handle the
|
||||
install. There are a couple of things to keep in mind when doing this:
|
||||
|
||||
1. It will be most reliable when building images for the same release that the
|
||||
host is running. Because Anaconda has expectations about the system it is
|
||||
running under you may encounter strange bugs if you try to build newer or
|
||||
older releases.
|
||||
|
||||
2. Make sure selinux is set to permissive or disabled. It won't install
|
||||
correctly with selinux set to enforcing yet.
|
||||
|
||||
3. It may totally trash your host. So far I haven't had this happen, but the
|
||||
possibility exists that a bug in Anaconda could result in it operating on
|
||||
real devices. I recommend running it in a virt or on a system that you can
|
||||
afford to lose all data from.
|
||||
|
||||
The logs from anaconda will be placed in an ./anaconda/ directory in either
|
||||
the current directory or in the directory used for --logfile
|
||||
|
||||
Example cmdline:
|
||||
|
||||
``sudo livemedia-creator --make-iso --no-virt --ks=./rhel7-livemedia.ks``
|
||||
|
||||
.. note::
|
||||
Using no-virt to create a partitioned disk image (eg. --make-disk or
|
||||
--make-vagrant) will only create disks usable on the host platform (BIOS
|
||||
or UEFI). You can create BIOS partitioned disk images on UEFI by using
|
||||
virt.
|
||||
|
||||
|
||||
AMI Images
|
||||
----------
|
||||
|
||||
Amazon EC2 images can be created by using the --make-ami switch and an appropriate
|
||||
kickstart file. All of the work to customize the image is handled by the kickstart.
|
||||
The example currently included was modified from the cloud-kickstarts version so
|
||||
that it would work with livemedia-creator.
|
||||
|
||||
Example cmdline:
|
||||
|
||||
``sudo livemedia-creator --make-ami --iso=/path/to/boot.iso --ks=./docs/rhel7-livemedia-ec2.ks``
|
||||
|
||||
This will produce an ami-root.img file in the working directory.
|
||||
|
||||
At this time I have not tested the image with EC2. Feedback would be welcome.
|
||||
|
||||
|
||||
Appliance Creation
|
||||
------------------
|
||||
|
||||
livemedia-creator can now replace appliance-tools by using the --make-appliance
|
||||
switch. This will create the partitioned disk image and an XML file that can be
|
||||
used with virt-image to setup a virtual system.
|
||||
|
||||
The XML is generated using the Mako template from
|
||||
/usr/share/lorax/appliance/libvirt.xml You can use a different template by
|
||||
passing ``--app-template <template path>``
|
||||
|
||||
Documentation on the Mako template system can be found at the `Mako site
|
||||
<http://docs.makotemplates.org/en/latest/index.html>`_
|
||||
|
||||
The name of the final output XML is appliance.xml, this can be changed with
|
||||
``--app-file <file path>``
|
||||
|
||||
The following variables are passed to the template:
|
||||
|
||||
``disks``
|
||||
A list of disk_info about each disk.
|
||||
Each entry has the following attributes:
|
||||
|
||||
``name``
|
||||
base name of the disk image file
|
||||
|
||||
``format``
|
||||
"raw"
|
||||
|
||||
``checksum_type``
|
||||
"sha256"
|
||||
|
||||
``checksum``
|
||||
sha256 checksum of the disk image
|
||||
|
||||
``name``
|
||||
Name of appliance, from --app-name argument
|
||||
|
||||
``arch``
|
||||
Architecture
|
||||
|
||||
``memory``
|
||||
Memory in KB (from ``--ram``)
|
||||
|
||||
``vcpus``
|
||||
from ``--vcpus``
|
||||
|
||||
``networks``
|
||||
list of networks from the kickstart or []
|
||||
|
||||
``title``
|
||||
from ``--title``
|
||||
|
||||
``project``
|
||||
from ``--project``
|
||||
|
||||
``releasever``
|
||||
from ``--releasever``
|
||||
|
||||
The created image can be imported into libvirt using:
|
||||
|
||||
``virt-image appliance.xml``
|
||||
|
||||
You can also create qcow2 appliance images using ``--image-type=qcow2``, for example::
|
||||
|
||||
sudo livemedia-creator --make-appliance --iso=/path/to/boot.iso --ks=./docs/rhel7-minimal.ks \
|
||||
--image-type=qcow2 --app-file=minimal-test.xml --image-name=minimal-test.img
|
||||
|
||||
|
||||
Filesystem Image Creation
|
||||
-------------------------
|
||||
|
||||
livemedia-creator can be used to create un-partitined filesystem images using
|
||||
the ``--make-fsimage`` option. As of version 21.8 this works with both virt and
|
||||
no-virt modes of operation. Previously it was only available with no-virt.
|
||||
|
||||
Kickstarts should have a single / partition with no extra mountpoints.
|
||||
|
||||
``livemedia-creator --make-fsimage --iso=/path/to/boot.iso --ks=./docs/rhel7-minimal.ks``
|
||||
|
||||
You can name the output image with ``--image-name`` and set a label on the filesystem with ``--fs-label``
|
||||
|
||||
|
||||
TAR File Creation
|
||||
-----------------
|
||||
|
||||
The ``--make-tar`` command can be used to create a tar of the root filesystem. By
|
||||
default it is compressed using xz, but this can be changed using the
|
||||
``--compression`` and ``--compress-arg`` options. This option works with both virt and
|
||||
no-virt install methods.
|
||||
|
||||
As with ``--make-fsimage`` the kickstart should be limited to a single / partition.
|
||||
|
||||
For example::
|
||||
|
||||
livemedia-creator --make-tar --iso=/path/to/boot.iso --ks=./docs/rhel7-minimal.ks \
|
||||
--image-name=rhel7-root.tar.xz
|
||||
|
||||
|
||||
Live Image for PXE Boot
|
||||
-----------------------
|
||||
|
||||
The ``--make-pxe-live`` command will produce squashfs image containing live root
|
||||
filesystem that can be used for pxe boot. Directory with results will contain
|
||||
the live image, kernel image, initrd image and template of pxe configuration
|
||||
for the images.
|
||||
|
||||
|
||||
Atomic Live Image for PXE Boot
|
||||
------------------------------
|
||||
|
||||
The ``--make-ostree-live`` command will produce the same result as ``--make-pxe-live``
|
||||
for installations of Atomic Host. Example kickstart for such an installation
|
||||
using Atomic installer iso with local repo included in the image can be found
|
||||
in docs/rhel-atomic-pxe-live.ks.
|
||||
|
||||
The PXE images can also be created with ``--no-virt`` by using the example
|
||||
kickstart in docs/rhel-atomic-pxe-live-novirt.ks. This also works inside the
|
||||
mock environment.
|
||||
|
||||
|
||||
Debugging problems
|
||||
------------------
|
||||
|
||||
Sometimes an installation will get stuck. When using virt-install the logs will
|
||||
be written to ./virt-install.log and most of the time any problems that happen
|
||||
will be near the end of the file. lmc tries to detect common errors and will
|
||||
cancel the installation when they happen. But not everything can be caught.
|
||||
When creating a new kickstart it is helpful to use vnc so that you can monitor
|
||||
the installation as it happens, and if it gets stuck without lmc detecting the
|
||||
problem you can switch to tty1 and examine the system directly.
|
||||
|
||||
If it does get stuck the best way to cancel is to use kill -9 on the virt-install pid,
|
||||
lmc will detect that the process died and cleanup.
|
||||
|
||||
If lmc didn't handle the cleanup for some reason you can do this:
|
||||
1. ``sudo umount /tmp/lmc-XXXX`` to unmount the iso from its mountpoint.
|
||||
2. ``sudo rm -rf /tmp/lmc-XXXX``
|
||||
3. ``sudo rm /var/tmp/lmc-disk-XXXXX`` to remove the disk image.
|
||||
|
||||
Note that lmc uses the lmc- prefix for all of its temporary files and
|
||||
directories to make it easier to find and clean up leftovers.
|
||||
|
||||
The logs from the virt-install run are stored in virt-install.log, logs from
|
||||
livemedia-creator are in livemedia.log and program.log
|
||||
|
||||
You can add ``--image-only`` to skip the .iso creation and examine the resulting
|
||||
disk image. Or you can pass ``--keep-image`` to keep it around after the iso has
|
||||
been created.
|
||||
|
||||
Cleaning up aborted ``--no-virt`` installs can sometimes be accomplished by
|
||||
running the ``anaconda-cleanup`` script. As of Fedora 18 anaconda is
|
||||
multi-threaded and it can sometimes become stuck and refuse to exit. When this
|
||||
happens you can usually clean up by first killing the anaconda process then
|
||||
running ``anaconda-cleanup``.
|
||||
|
||||
|
||||
Hacking
|
||||
-------
|
||||
|
||||
Development on this will take place as part of the lorax project, and on the
|
||||
anaconda-devel-list mailing list, and `on github <https://github.com/rhinstaller/lorax>`_
|
||||
|
||||
Feedback, enhancements and bugs are welcome. You can use `bugzilla
|
||||
<https://bugzilla.redhat.com/enter_bug.cgi?product=Fedora&component=lorax>`_ to
|
||||
report bugs against the lorax component.
|
||||
|
148
lorax-composer/_sources/lorax.txt
Normal file
148
lorax-composer/_sources/lorax.txt
Normal file
@ -0,0 +1,148 @@
|
||||
Lorax
|
||||
=====
|
||||
|
||||
:Authors:
|
||||
Brian C. Lane <bcl@redhat.com>
|
||||
|
||||
"I am the Lorax. I speak for the trees [and images]."
|
||||
|
||||
The `lorax <https://github.com/rhinstaller/lorax>`_ tool is used to create the
|
||||
`Anaconda <https://github.com/rhinstaller/anaconda>`_ installer boot.iso as
|
||||
well as the basic release tree, and .treeinfo metadata file. Its dependencies
|
||||
are fairly light-weight because it needs to be able to run in a mock chroot
|
||||
environment. It is best to run lorax from the same release as is being targeted
|
||||
because the templates may have release specific logic in them. eg. Use the
|
||||
rawhide version to build the boot.iso for rawhide, along with the rawhide
|
||||
repositories.
|
||||
|
||||
|
||||
lorax cmdline arguments
|
||||
-----------------------
|
||||
|
||||
See the output from ``lorax --help`` for the commandline arguments.
|
||||
|
||||
Quickstart
|
||||
----------
|
||||
|
||||
Run this as root to create a boot.iso in ``./results/``::
|
||||
|
||||
yum install lorax
|
||||
setenforce 0
|
||||
lorax -p RHEL -v 7 -r 7 \
|
||||
-s http://mirror.centos.org/centos-7/7/os/x86_64/ \
|
||||
-s http://mirror.centos.org/centos-7/7/updates/x86_64/ \
|
||||
./results/
|
||||
setenforce 1
|
||||
|
||||
You can add your own repos with ``-s`` and packages with higher NVRs will
|
||||
override the ones in the distribution repositories.
|
||||
|
||||
Under ``./results/`` will be the release tree files: .discinfo, .treeinfo, everything that
|
||||
goes onto the boot.iso, the pxeboot directory, and the boot.iso under ``./images/``.
|
||||
|
||||
|
||||
Running inside of mock
|
||||
----------------------
|
||||
|
||||
If you are using lorax with mock v1.3.4 or later you will need to pass
|
||||
``--old-chroot`` to mock. Mock now defaults to using systemd-nspawn which cannot
|
||||
create the needed loop device nodes. Passing ``--old-chroot`` will use the old
|
||||
system where ``/dev/loop*`` is setup for you.
|
||||
|
||||
|
||||
How it works
|
||||
------------
|
||||
|
||||
Lorax uses `yum <https://github.com/rpm-software-management/yum>`_ to install
|
||||
packages into a temporary directory, sets up configuration files, it then
|
||||
removes unneeded files to save space, and creates a squashfs filesystem of the
|
||||
files. The iso is then built using a generic initramfs and the kernel from the
|
||||
selected repositories.
|
||||
|
||||
To drive these processes Lorax uses a custom template system, based on `Mako
|
||||
templates <http://www.makotemplates.org/>`_ with the addition of custom
|
||||
commands (documented in :class:`pylorax.ltmpl.LoraxTemplateRunner`). Mako
|
||||
supports ``%if/%endif`` blocks as well as free-form python code inside ``<%
|
||||
%>`` tags and variable substitution with ``${}``. The default templates are
|
||||
shipped with lorax in ``/usr/share/lorax/`` and use the
|
||||
``.tmpl`` extension.
|
||||
|
||||
|
||||
runtime-install.tmpl
|
||||
~~~~~~~~~~~~~~~~~~~~
|
||||
|
||||
The ``runtime-install.tmpl`` template lists packages to be installed using the
|
||||
``installpkg`` command. This template is fairly simple, installing common packages and
|
||||
architecture specific packages. It must end with the ``run_pkg_transaction``
|
||||
command which tells dnf to download and install the packages.
|
||||
|
||||
|
||||
runtime-postinstall.tmpl
|
||||
~~~~~~~~~~~~~~~~~~~~~~~~
|
||||
|
||||
The ``runtime-postinstall.tmpl`` template is where the system configuration
|
||||
happens. The installer environment is similar to a normal running system, but
|
||||
needs some special handling. Configuration files are setup, systemd is told to
|
||||
start the anaconda.target instead of a default system target, and a number of
|
||||
unneeded services are disabled, some of which can interfere with the
|
||||
installation. A number of template commands are used here:
|
||||
|
||||
* :func:`append <pylorax.ltmpl.LoraxTemplateRunner.append>` to add text to a file.
|
||||
* :func:`chmod <pylorax.ltmpl.LoraxTemplateRunner.chmod>` changes the file's mode.
|
||||
* :func:`gconfset <pylorax.ltmpl.LoraxTemplateRunner.gconfset>` runs gconfset.
|
||||
* :func:`install <pylorax.ltmpl.LoraxTemplateRunner.install>` to install a file into the installroot.
|
||||
* :func:`mkdir <pylorax.ltmpl.LoraxTemplateRunner.mkdir>` makes a new directory.
|
||||
* :func:`move <pylorax.ltmpl.LoraxTemplateRunner.move>` to move a file into the installroot
|
||||
* :func:`replace <pylorax.ltmpl.LoraxTemplateRunner.replace>` does text substitution in a file
|
||||
* :func:`remove <pylorax.ltmpl.LoraxTemplateRunner.remove>` deletes a file
|
||||
* :func:`runcmd <pylorax.ltmpl.LoraxTemplateRunner.runcmd>` run arbitrary commands.
|
||||
* :func:`symlink <pylorax.ltmpl.LoraxTemplateRunner.symlink>` creates a symlink
|
||||
* :func:`systemctl <pylorax.ltmpl.LoraxTemplateRunner.systemctl>` runs systemctl in the installroot
|
||||
|
||||
|
||||
runtime-cleanup.tmpl
|
||||
~~~~~~~~~~~~~~~~~~~~
|
||||
|
||||
The ``runtime-cleanup.tmpl`` template is used to remove files that aren't strictly needed
|
||||
by the installation environment. In addition to the ``remove`` template command it uses:
|
||||
|
||||
* :func:`removepkg <pylorax.ltmpl.LoraxTemplateRunner.removepkg>`
|
||||
remove all of a specific package's contents. A package may be pulled in as a dependency, but
|
||||
not really used. eg. sound support.
|
||||
* :func:`removefrom <pylorax.ltmpl.LoraxTemplateRunner.removefrom>`
|
||||
Removes some files from a package. A file glob can be used, or the --allbut option to
|
||||
remove everything except a select few.
|
||||
* :func:`removekmod <pylorax.ltmpl.LoraxTemplateRunner.removekmod>`
|
||||
Removes kernel modules
|
||||
|
||||
|
||||
The squashfs filesystem
|
||||
~~~~~~~~~~~~~~~~~~~~~~~
|
||||
|
||||
After ``runtime-*.tmpl`` templates have finished their work lorax creates an
|
||||
empty ext4 filesystem, copies the remaining files to it, and makes a squashfs
|
||||
filesystem of it. This file is the / of the boot.iso's installer environment
|
||||
and is what is in the LiveOS/squashfs.img file on the iso.
|
||||
|
||||
|
||||
iso creation
|
||||
~~~~~~~~~~~~
|
||||
|
||||
The iso creation is handled by another set of templates. The one used depends
|
||||
on the architecture that the iso is being created for. They are also stored in
|
||||
``/usr/share/lorax/`` and are named after the arch, like
|
||||
``x86.tmpl`` and ``aarch64.tmpl``. They handle creation of the tree, copying
|
||||
configuration template files, configuration variable substitution, treeinfo
|
||||
metadata (via the :func:`treeinfo <pylorax.ltmpl.LoraxTemplateRunner.treeinfo>`
|
||||
template command). Kernel and initrd are copied from the installroot to their
|
||||
final locations and then mkisofs is run to create the boot.iso
|
||||
|
||||
|
||||
Custom Templates
|
||||
----------------
|
||||
|
||||
The default set of templates and configuration files are shipped in the
|
||||
``/usr/share/lorax/`` directory. You can make a copy of them and place them
|
||||
into another directory and then select the new template directory by passing
|
||||
``--sharedir`` to lorax.
|
||||
|
@ -1,7 +1,8 @@
|
||||
pylorax
|
||||
=======
|
||||
src
|
||||
===
|
||||
|
||||
.. toctree::
|
||||
:maxdepth: 4
|
||||
|
||||
composer
|
||||
pylorax
|
||||
|
27
lorax-composer/_sources/product-images.txt
Normal file
27
lorax-composer/_sources/product-images.txt
Normal file
@ -0,0 +1,27 @@
|
||||
Product and Updates Images
|
||||
==========================
|
||||
|
||||
Lorax now supports creation of product.img and updates.img as part of the build
|
||||
process. This is implemented using the installimg template command which will
|
||||
take the contents of a directory and create a compressed archive from it. The
|
||||
directory must be created by one of the packages installed by
|
||||
runtime-install.tmpl or by passing ``--installpkgs <pkgname>`` to lorax at
|
||||
runtime. The x86, ppc, ppc64le and aarch64 templates all look for
|
||||
/usr/share/lorax/product/ and /usr/share/lorax/updates/ directories in the
|
||||
install chroot while creating the final install tree. If there are files in
|
||||
those directories lorax will create images/product.img and/or
|
||||
images/updates.img
|
||||
|
||||
These archives are just like an anaconda updates image -- their contents are
|
||||
copied over the top of the filesystem at boot time so that you can drop in
|
||||
files to add to or replace anything on the filesystem.
|
||||
|
||||
Anaconda has several places that it looks for updates, the one for product.img
|
||||
is in /run/install/product. So for example, to add an installclass to Anaconda
|
||||
you would put your custom class here:
|
||||
|
||||
``/usr/share/lorax/product/run/install/product/pyanaconda/installclasses/custom.py``
|
||||
|
||||
If the packages containing the product/updates files are not included as part
|
||||
of normal dependencies you can add specific packages with the ``--installpkgs``
|
||||
command or the installpkgs paramater of :class:`pylorax.treebuilder.RuntimeBuilder`
|
@ -4,7 +4,7 @@ pylorax Package
|
||||
:mod:`pylorax` Package
|
||||
----------------------
|
||||
|
||||
.. automodule:: pylorax.__init__
|
||||
.. automodule:: pylorax
|
||||
:members:
|
||||
:undoc-members:
|
||||
:show-inheritance:
|
||||
|
952
lorax-composer/composer.cli.html
Normal file
952
lorax-composer/composer.cli.html
Normal file
@ -0,0 +1,952 @@
|
||||
|
||||
|
||||
<!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>cli Package — Lorax 19.7.11 documentation</title>
|
||||
|
||||
<link rel="stylesheet" href="_static/default.css" type="text/css" />
|
||||
<link rel="stylesheet" href="_static/pygments.css" type="text/css" />
|
||||
|
||||
<script type="text/javascript">
|
||||
var DOCUMENTATION_OPTIONS = {
|
||||
URL_ROOT: '',
|
||||
VERSION: '19.7.11',
|
||||
COLLAPSE_INDEX: false,
|
||||
FILE_SUFFIX: '.html',
|
||||
HAS_SOURCE: true
|
||||
};
|
||||
</script>
|
||||
<script type="text/javascript" src="_static/jquery.js"></script>
|
||||
<script type="text/javascript" src="_static/underscore.js"></script>
|
||||
<script type="text/javascript" src="_static/doctools.js"></script>
|
||||
<link rel="top" title="Lorax 19.7.11 documentation" href="index.html" />
|
||||
<link rel="up" title="composer Package" href="composer.html" />
|
||||
<link rel="next" title="pylorax Package" href="pylorax.html" />
|
||||
<link rel="prev" title="composer Package" href="composer.html" />
|
||||
</head>
|
||||
<body>
|
||||
<div class="related">
|
||||
<h3>Navigation</h3>
|
||||
<ul>
|
||||
<li class="right" style="margin-right: 10px">
|
||||
<a href="genindex.html" title="General Index"
|
||||
accesskey="I">index</a></li>
|
||||
<li class="right" >
|
||||
<a href="py-modindex.html" title="Python Module Index"
|
||||
>modules</a> |</li>
|
||||
<li class="right" >
|
||||
<a href="pylorax.html" title="pylorax Package"
|
||||
accesskey="N">next</a> |</li>
|
||||
<li class="right" >
|
||||
<a href="composer.html" title="composer Package"
|
||||
accesskey="P">previous</a> |</li>
|
||||
<li><a href="index.html">Lorax 19.7.11 documentation</a> »</li>
|
||||
<li><a href="modules.html" >src</a> »</li>
|
||||
<li><a href="composer.html" accesskey="U">composer Package</a> »</li>
|
||||
</ul>
|
||||
</div>
|
||||
|
||||
<div class="document">
|
||||
<div class="documentwrapper">
|
||||
<div class="bodywrapper">
|
||||
<div class="body">
|
||||
|
||||
<div class="section" id="cli-package">
|
||||
<h1>cli Package<a class="headerlink" href="#cli-package" title="Permalink to this headline">¶</a></h1>
|
||||
<div class="section" id="id1">
|
||||
<h2><tt class="xref py py-mod docutils literal"><span class="pre">cli</span></tt> Package<a class="headerlink" href="#id1" title="Permalink to this headline">¶</a></h2>
|
||||
<span class="target" id="module-composer.cli"></span><dl class="function">
|
||||
<dt id="composer.cli.main">
|
||||
<tt class="descclassname">composer.cli.</tt><tt class="descname">main</tt><big>(</big><em>opts</em><big>)</big><a class="reference internal" href="_modules/composer/cli.html#main"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#composer.cli.main" title="Permalink to this definition">¶</a></dt>
|
||||
<dd><p>Main program execution</p>
|
||||
<table class="docutils field-list" frame="void" rules="none">
|
||||
<col class="field-name" />
|
||||
<col class="field-body" />
|
||||
<tbody valign="top">
|
||||
<tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><strong>opts</strong> (<a class="reference external" href="https://docs.python.org/2/library/argparse.html#argparse.Namespace" title="(in Python v2.7)"><em>argparse.Namespace</em></a>) – Cmdline arguments</td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
</dd></dl>
|
||||
|
||||
</div>
|
||||
<div class="section" id="module-composer.cli.compose">
|
||||
<span id="compose-module"></span><h2><tt class="xref py py-mod docutils literal"><span class="pre">compose</span></tt> Module<a class="headerlink" href="#module-composer.cli.compose" title="Permalink to this headline">¶</a></h2>
|
||||
<dl class="function">
|
||||
<dt id="composer.cli.compose.compose_cancel">
|
||||
<tt class="descclassname">composer.cli.compose.</tt><tt class="descname">compose_cancel</tt><big>(</big><em>socket_path</em>, <em>api_version</em>, <em>args</em>, <em>show_json=False</em>, <em>testmode=0</em><big>)</big><a class="reference internal" href="_modules/composer/cli/compose.html#compose_cancel"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#composer.cli.compose.compose_cancel" title="Permalink to this definition">¶</a></dt>
|
||||
<dd><p>Cancel a running compose</p>
|
||||
<table class="docutils field-list" frame="void" rules="none">
|
||||
<col class="field-name" />
|
||||
<col class="field-body" />
|
||||
<tbody valign="top">
|
||||
<tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><ul class="first last simple">
|
||||
<li><strong>socket_path</strong> (<a class="reference external" href="https://docs.python.org/2/library/functions.html#str" title="(in Python v2.7)"><em>str</em></a>) – Path to the Unix socket to use for API communication</li>
|
||||
<li><strong>api_version</strong> (<a class="reference external" href="https://docs.python.org/2/library/functions.html#str" title="(in Python v2.7)"><em>str</em></a>) – Version of the API to talk to. eg. “0”</li>
|
||||
<li><strong>args</strong> (<em>list of str</em>) – List of remaining arguments from the cmdline</li>
|
||||
<li><strong>show_json</strong> (<a class="reference external" href="https://docs.python.org/2/library/functions.html#bool" title="(in Python v2.7)"><em>bool</em></a>) – Set to True to show the JSON output instead of the human readable output</li>
|
||||
</ul>
|
||||
</td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
<p>compose cancel <uuid></p>
|
||||
<p>This will cancel a running compose. It does nothing if the compose has finished.</p>
|
||||
</dd></dl>
|
||||
|
||||
<dl class="function">
|
||||
<dt id="composer.cli.compose.compose_cmd">
|
||||
<tt class="descclassname">composer.cli.compose.</tt><tt class="descname">compose_cmd</tt><big>(</big><em>opts</em><big>)</big><a class="reference internal" href="_modules/composer/cli/compose.html#compose_cmd"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#composer.cli.compose.compose_cmd" title="Permalink to this definition">¶</a></dt>
|
||||
<dd><p>Process compose commands</p>
|
||||
<table class="docutils field-list" frame="void" rules="none">
|
||||
<col class="field-name" />
|
||||
<col class="field-body" />
|
||||
<tbody valign="top">
|
||||
<tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><strong>opts</strong> (<a class="reference external" href="https://docs.python.org/2/library/argparse.html#argparse.Namespace" title="(in Python v2.7)"><em>argparse.Namespace</em></a>) – Cmdline arguments</td>
|
||||
</tr>
|
||||
<tr class="field-even field"><th class="field-name">Returns:</th><td class="field-body">Value to return from sys.exit()</td>
|
||||
</tr>
|
||||
<tr class="field-odd field"><th class="field-name">Return type:</th><td class="field-body">int</td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
<p>This dispatches the compose commands to a function</p>
|
||||
</dd></dl>
|
||||
|
||||
<dl class="function">
|
||||
<dt id="composer.cli.compose.compose_delete">
|
||||
<tt class="descclassname">composer.cli.compose.</tt><tt class="descname">compose_delete</tt><big>(</big><em>socket_path</em>, <em>api_version</em>, <em>args</em>, <em>show_json=False</em>, <em>testmode=0</em><big>)</big><a class="reference internal" href="_modules/composer/cli/compose.html#compose_delete"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#composer.cli.compose.compose_delete" title="Permalink to this definition">¶</a></dt>
|
||||
<dd><p>Delete a finished compose’s results</p>
|
||||
<table class="docutils field-list" frame="void" rules="none">
|
||||
<col class="field-name" />
|
||||
<col class="field-body" />
|
||||
<tbody valign="top">
|
||||
<tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><ul class="first last simple">
|
||||
<li><strong>socket_path</strong> (<a class="reference external" href="https://docs.python.org/2/library/functions.html#str" title="(in Python v2.7)"><em>str</em></a>) – Path to the Unix socket to use for API communication</li>
|
||||
<li><strong>api_version</strong> (<a class="reference external" href="https://docs.python.org/2/library/functions.html#str" title="(in Python v2.7)"><em>str</em></a>) – Version of the API to talk to. eg. “0”</li>
|
||||
<li><strong>args</strong> (<em>list of str</em>) – List of remaining arguments from the cmdline</li>
|
||||
<li><strong>show_json</strong> (<a class="reference external" href="https://docs.python.org/2/library/functions.html#bool" title="(in Python v2.7)"><em>bool</em></a>) – Set to True to show the JSON output instead of the human readable output</li>
|
||||
</ul>
|
||||
</td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
<p>compose delete <uuid,...></p>
|
||||
<p>Delete the listed compose results. It will only delete results for composes that have finished
|
||||
or failed, not a running compose.</p>
|
||||
</dd></dl>
|
||||
|
||||
<dl class="function">
|
||||
<dt id="composer.cli.compose.compose_details">
|
||||
<tt class="descclassname">composer.cli.compose.</tt><tt class="descname">compose_details</tt><big>(</big><em>socket_path</em>, <em>api_version</em>, <em>args</em>, <em>show_json=False</em>, <em>testmode=0</em><big>)</big><a class="reference internal" href="_modules/composer/cli/compose.html#compose_details"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#composer.cli.compose.compose_details" title="Permalink to this definition">¶</a></dt>
|
||||
<dd><p>Return detailed information about the compose</p>
|
||||
<table class="docutils field-list" frame="void" rules="none">
|
||||
<col class="field-name" />
|
||||
<col class="field-body" />
|
||||
<tbody valign="top">
|
||||
<tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><ul class="first last simple">
|
||||
<li><strong>socket_path</strong> (<a class="reference external" href="https://docs.python.org/2/library/functions.html#str" title="(in Python v2.7)"><em>str</em></a>) – Path to the Unix socket to use for API communication</li>
|
||||
<li><strong>api_version</strong> (<a class="reference external" href="https://docs.python.org/2/library/functions.html#str" title="(in Python v2.7)"><em>str</em></a>) – Version of the API to talk to. eg. “0”</li>
|
||||
<li><strong>args</strong> (<em>list of str</em>) – List of remaining arguments from the cmdline</li>
|
||||
<li><strong>show_json</strong> (<a class="reference external" href="https://docs.python.org/2/library/functions.html#bool" title="(in Python v2.7)"><em>bool</em></a>) – Set to True to show the JSON output instead of the human readable output</li>
|
||||
</ul>
|
||||
</td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
<p>compose details <uuid></p>
|
||||
<p>This returns information about the compose, including the recipe and the dependencies.</p>
|
||||
</dd></dl>
|
||||
|
||||
<dl class="function">
|
||||
<dt id="composer.cli.compose.compose_image">
|
||||
<tt class="descclassname">composer.cli.compose.</tt><tt class="descname">compose_image</tt><big>(</big><em>socket_path</em>, <em>api_version</em>, <em>args</em>, <em>show_json=False</em>, <em>testmode=0</em><big>)</big><a class="reference internal" href="_modules/composer/cli/compose.html#compose_image"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#composer.cli.compose.compose_image" title="Permalink to this definition">¶</a></dt>
|
||||
<dd><p>Download the compose’s output image</p>
|
||||
<table class="docutils field-list" frame="void" rules="none">
|
||||
<col class="field-name" />
|
||||
<col class="field-body" />
|
||||
<tbody valign="top">
|
||||
<tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><ul class="first last simple">
|
||||
<li><strong>socket_path</strong> (<a class="reference external" href="https://docs.python.org/2/library/functions.html#str" title="(in Python v2.7)"><em>str</em></a>) – Path to the Unix socket to use for API communication</li>
|
||||
<li><strong>api_version</strong> (<a class="reference external" href="https://docs.python.org/2/library/functions.html#str" title="(in Python v2.7)"><em>str</em></a>) – Version of the API to talk to. eg. “0”</li>
|
||||
<li><strong>args</strong> (<em>list of str</em>) – List of remaining arguments from the cmdline</li>
|
||||
<li><strong>show_json</strong> (<a class="reference external" href="https://docs.python.org/2/library/functions.html#bool" title="(in Python v2.7)"><em>bool</em></a>) – Set to True to show the JSON output instead of the human readable output</li>
|
||||
</ul>
|
||||
</td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
<p>compose image <uuid></p>
|
||||
<p>This downloads only the result image, saving it as the image name, which depends on the type
|
||||
of compose that was selected.</p>
|
||||
</dd></dl>
|
||||
|
||||
<dl class="function">
|
||||
<dt id="composer.cli.compose.compose_log">
|
||||
<tt class="descclassname">composer.cli.compose.</tt><tt class="descname">compose_log</tt><big>(</big><em>socket_path</em>, <em>api_version</em>, <em>args</em>, <em>show_json=False</em>, <em>testmode=0</em><big>)</big><a class="reference internal" href="_modules/composer/cli/compose.html#compose_log"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#composer.cli.compose.compose_log" title="Permalink to this definition">¶</a></dt>
|
||||
<dd><p>Show the last part of the compose log</p>
|
||||
<table class="docutils field-list" frame="void" rules="none">
|
||||
<col class="field-name" />
|
||||
<col class="field-body" />
|
||||
<tbody valign="top">
|
||||
<tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><ul class="first last simple">
|
||||
<li><strong>socket_path</strong> (<a class="reference external" href="https://docs.python.org/2/library/functions.html#str" title="(in Python v2.7)"><em>str</em></a>) – Path to the Unix socket to use for API communication</li>
|
||||
<li><strong>api_version</strong> (<a class="reference external" href="https://docs.python.org/2/library/functions.html#str" title="(in Python v2.7)"><em>str</em></a>) – Version of the API to talk to. eg. “0”</li>
|
||||
<li><strong>args</strong> (<em>list of str</em>) – List of remaining arguments from the cmdline</li>
|
||||
<li><strong>show_json</strong> (<a class="reference external" href="https://docs.python.org/2/library/functions.html#bool" title="(in Python v2.7)"><em>bool</em></a>) – Set to True to show the JSON output instead of the human readable output</li>
|
||||
</ul>
|
||||
</td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
<p>compose log <uuid> [<size>kB]</p>
|
||||
<p>This will display the last 1kB of the compose’s log file. Can be used to follow progress
|
||||
during the build.</p>
|
||||
</dd></dl>
|
||||
|
||||
<dl class="function">
|
||||
<dt id="composer.cli.compose.compose_logs">
|
||||
<tt class="descclassname">composer.cli.compose.</tt><tt class="descname">compose_logs</tt><big>(</big><em>socket_path</em>, <em>api_version</em>, <em>args</em>, <em>show_json=False</em>, <em>testmode=0</em><big>)</big><a class="reference internal" href="_modules/composer/cli/compose.html#compose_logs"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#composer.cli.compose.compose_logs" title="Permalink to this definition">¶</a></dt>
|
||||
<dd><p>Download a tar of the compose’s logs</p>
|
||||
<table class="docutils field-list" frame="void" rules="none">
|
||||
<col class="field-name" />
|
||||
<col class="field-body" />
|
||||
<tbody valign="top">
|
||||
<tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><ul class="first last simple">
|
||||
<li><strong>socket_path</strong> (<a class="reference external" href="https://docs.python.org/2/library/functions.html#str" title="(in Python v2.7)"><em>str</em></a>) – Path to the Unix socket to use for API communication</li>
|
||||
<li><strong>api_version</strong> (<a class="reference external" href="https://docs.python.org/2/library/functions.html#str" title="(in Python v2.7)"><em>str</em></a>) – Version of the API to talk to. eg. “0”</li>
|
||||
<li><strong>args</strong> (<em>list of str</em>) – List of remaining arguments from the cmdline</li>
|
||||
<li><strong>show_json</strong> (<a class="reference external" href="https://docs.python.org/2/library/functions.html#bool" title="(in Python v2.7)"><em>bool</em></a>) – Set to True to show the JSON output instead of the human readable output</li>
|
||||
</ul>
|
||||
</td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
<p>compose logs <uuid></p>
|
||||
<p>Saves the logs as uuid-logs.tar</p>
|
||||
</dd></dl>
|
||||
|
||||
<dl class="function">
|
||||
<dt id="composer.cli.compose.compose_metadata">
|
||||
<tt class="descclassname">composer.cli.compose.</tt><tt class="descname">compose_metadata</tt><big>(</big><em>socket_path</em>, <em>api_version</em>, <em>args</em>, <em>show_json=False</em>, <em>testmode=0</em><big>)</big><a class="reference internal" href="_modules/composer/cli/compose.html#compose_metadata"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#composer.cli.compose.compose_metadata" title="Permalink to this definition">¶</a></dt>
|
||||
<dd><p>Download a tar file of the compose’s metadata</p>
|
||||
<table class="docutils field-list" frame="void" rules="none">
|
||||
<col class="field-name" />
|
||||
<col class="field-body" />
|
||||
<tbody valign="top">
|
||||
<tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><ul class="first last simple">
|
||||
<li><strong>socket_path</strong> (<a class="reference external" href="https://docs.python.org/2/library/functions.html#str" title="(in Python v2.7)"><em>str</em></a>) – Path to the Unix socket to use for API communication</li>
|
||||
<li><strong>api_version</strong> (<a class="reference external" href="https://docs.python.org/2/library/functions.html#str" title="(in Python v2.7)"><em>str</em></a>) – Version of the API to talk to. eg. “0”</li>
|
||||
<li><strong>args</strong> (<em>list of str</em>) – List of remaining arguments from the cmdline</li>
|
||||
<li><strong>show_json</strong> (<a class="reference external" href="https://docs.python.org/2/library/functions.html#bool" title="(in Python v2.7)"><em>bool</em></a>) – Set to True to show the JSON output instead of the human readable output</li>
|
||||
</ul>
|
||||
</td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
<p>compose metadata <uuid></p>
|
||||
<p>Saves the metadata as uuid-metadata.tar</p>
|
||||
</dd></dl>
|
||||
|
||||
<dl class="function">
|
||||
<dt id="composer.cli.compose.compose_results">
|
||||
<tt class="descclassname">composer.cli.compose.</tt><tt class="descname">compose_results</tt><big>(</big><em>socket_path</em>, <em>api_version</em>, <em>args</em>, <em>show_json=False</em>, <em>testmode=0</em><big>)</big><a class="reference internal" href="_modules/composer/cli/compose.html#compose_results"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#composer.cli.compose.compose_results" title="Permalink to this definition">¶</a></dt>
|
||||
<dd><p>Download a tar file of the compose’s results</p>
|
||||
<table class="docutils field-list" frame="void" rules="none">
|
||||
<col class="field-name" />
|
||||
<col class="field-body" />
|
||||
<tbody valign="top">
|
||||
<tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><ul class="first last simple">
|
||||
<li><strong>socket_path</strong> (<a class="reference external" href="https://docs.python.org/2/library/functions.html#str" title="(in Python v2.7)"><em>str</em></a>) – Path to the Unix socket to use for API communication</li>
|
||||
<li><strong>api_version</strong> (<a class="reference external" href="https://docs.python.org/2/library/functions.html#str" title="(in Python v2.7)"><em>str</em></a>) – Version of the API to talk to. eg. “0”</li>
|
||||
<li><strong>args</strong> (<em>list of str</em>) – List of remaining arguments from the cmdline</li>
|
||||
<li><strong>show_json</strong> (<a class="reference external" href="https://docs.python.org/2/library/functions.html#bool" title="(in Python v2.7)"><em>bool</em></a>) – Set to True to show the JSON output instead of the human readable output</li>
|
||||
</ul>
|
||||
</td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
<p>compose results <uuid></p>
|
||||
<p>The results includes the metadata, output image, and logs.
|
||||
It is saved as uuid.tar</p>
|
||||
</dd></dl>
|
||||
|
||||
<dl class="function">
|
||||
<dt id="composer.cli.compose.compose_start">
|
||||
<tt class="descclassname">composer.cli.compose.</tt><tt class="descname">compose_start</tt><big>(</big><em>socket_path</em>, <em>api_version</em>, <em>args</em>, <em>show_json=False</em>, <em>testmode=0</em><big>)</big><a class="reference internal" href="_modules/composer/cli/compose.html#compose_start"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#composer.cli.compose.compose_start" title="Permalink to this definition">¶</a></dt>
|
||||
<dd><p>Start a new compose using the selected recipe and type</p>
|
||||
<table class="docutils field-list" frame="void" rules="none">
|
||||
<col class="field-name" />
|
||||
<col class="field-body" />
|
||||
<tbody valign="top">
|
||||
<tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><ul class="first last simple">
|
||||
<li><strong>socket_path</strong> (<a class="reference external" href="https://docs.python.org/2/library/functions.html#str" title="(in Python v2.7)"><em>str</em></a>) – Path to the Unix socket to use for API communication</li>
|
||||
<li><strong>api_version</strong> (<a class="reference external" href="https://docs.python.org/2/library/functions.html#str" title="(in Python v2.7)"><em>str</em></a>) – Version of the API to talk to. eg. “0”</li>
|
||||
<li><strong>args</strong> (<em>list of str</em>) – List of remaining arguments from the cmdline</li>
|
||||
<li><strong>show_json</strong> (<a class="reference external" href="https://docs.python.org/2/library/functions.html#bool" title="(in Python v2.7)"><em>bool</em></a>) – Set to True to show the JSON output instead of the human readable output</li>
|
||||
</ul>
|
||||
</td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
<p>compose start <recipe-name> <compose-type></p>
|
||||
</dd></dl>
|
||||
|
||||
<dl class="function">
|
||||
<dt id="composer.cli.compose.compose_status">
|
||||
<tt class="descclassname">composer.cli.compose.</tt><tt class="descname">compose_status</tt><big>(</big><em>socket_path</em>, <em>api_version</em>, <em>args</em>, <em>show_json=False</em>, <em>testmode=0</em><big>)</big><a class="reference internal" href="_modules/composer/cli/compose.html#compose_status"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#composer.cli.compose.compose_status" title="Permalink to this definition">¶</a></dt>
|
||||
<dd><p>Return the status of all known composes</p>
|
||||
<table class="docutils field-list" frame="void" rules="none">
|
||||
<col class="field-name" />
|
||||
<col class="field-body" />
|
||||
<tbody valign="top">
|
||||
<tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><ul class="first last simple">
|
||||
<li><strong>socket_path</strong> (<a class="reference external" href="https://docs.python.org/2/library/functions.html#str" title="(in Python v2.7)"><em>str</em></a>) – Path to the Unix socket to use for API communication</li>
|
||||
<li><strong>api_version</strong> (<a class="reference external" href="https://docs.python.org/2/library/functions.html#str" title="(in Python v2.7)"><em>str</em></a>) – Version of the API to talk to. eg. “0”</li>
|
||||
<li><strong>args</strong> (<em>list of str</em>) – List of remaining arguments from the cmdline</li>
|
||||
<li><strong>show_json</strong> (<a class="reference external" href="https://docs.python.org/2/library/functions.html#bool" title="(in Python v2.7)"><em>bool</em></a>) – Set to True to show the JSON output instead of the human readable output</li>
|
||||
</ul>
|
||||
</td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
<p>This doesn’t map directly to an API command, it combines the results from queue, finished,
|
||||
and failed so raw JSON output is not available.</p>
|
||||
</dd></dl>
|
||||
|
||||
<dl class="function">
|
||||
<dt id="composer.cli.compose.compose_types">
|
||||
<tt class="descclassname">composer.cli.compose.</tt><tt class="descname">compose_types</tt><big>(</big><em>socket_path</em>, <em>api_version</em>, <em>args</em>, <em>show_json=False</em><big>)</big><a class="reference internal" href="_modules/composer/cli/compose.html#compose_types"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#composer.cli.compose.compose_types" title="Permalink to this definition">¶</a></dt>
|
||||
<dd><p>Return information about the supported compose types</p>
|
||||
<table class="docutils field-list" frame="void" rules="none">
|
||||
<col class="field-name" />
|
||||
<col class="field-body" />
|
||||
<tbody valign="top">
|
||||
<tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><ul class="first last simple">
|
||||
<li><strong>socket_path</strong> (<a class="reference external" href="https://docs.python.org/2/library/functions.html#str" title="(in Python v2.7)"><em>str</em></a>) – Path to the Unix socket to use for API communication</li>
|
||||
<li><strong>api_version</strong> (<a class="reference external" href="https://docs.python.org/2/library/functions.html#str" title="(in Python v2.7)"><em>str</em></a>) – Version of the API to talk to. eg. “0”</li>
|
||||
<li><strong>args</strong> (<em>list of str</em>) – List of remaining arguments from the cmdline</li>
|
||||
<li><strong>show_json</strong> (<a class="reference external" href="https://docs.python.org/2/library/functions.html#bool" title="(in Python v2.7)"><em>bool</em></a>) – Set to True to show the JSON output instead of the human readable output</li>
|
||||
</ul>
|
||||
</td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
<p>Add additional details to types that are known to composer-cli. Raw JSON output does not
|
||||
include this extra information.</p>
|
||||
</dd></dl>
|
||||
|
||||
</div>
|
||||
<div class="section" id="module-composer.cli.modules">
|
||||
<span id="modules-module"></span><h2><tt class="xref py py-mod docutils literal"><span class="pre">modules</span></tt> Module<a class="headerlink" href="#module-composer.cli.modules" title="Permalink to this headline">¶</a></h2>
|
||||
<dl class="function">
|
||||
<dt id="composer.cli.modules.modules_cmd">
|
||||
<tt class="descclassname">composer.cli.modules.</tt><tt class="descname">modules_cmd</tt><big>(</big><em>opts</em><big>)</big><a class="reference internal" href="_modules/composer/cli/modules.html#modules_cmd"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#composer.cli.modules.modules_cmd" title="Permalink to this definition">¶</a></dt>
|
||||
<dd><p>Process modules commands</p>
|
||||
<table class="docutils field-list" frame="void" rules="none">
|
||||
<col class="field-name" />
|
||||
<col class="field-body" />
|
||||
<tbody valign="top">
|
||||
<tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><strong>opts</strong> (<a class="reference external" href="https://docs.python.org/2/library/argparse.html#argparse.Namespace" title="(in Python v2.7)"><em>argparse.Namespace</em></a>) – Cmdline arguments</td>
|
||||
</tr>
|
||||
<tr class="field-even field"><th class="field-name">Returns:</th><td class="field-body">Value to return from sys.exit()</td>
|
||||
</tr>
|
||||
<tr class="field-odd field"><th class="field-name">Return type:</th><td class="field-body">int</td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
</dd></dl>
|
||||
|
||||
</div>
|
||||
<div class="section" id="module-composer.cli.projects">
|
||||
<span id="projects-module"></span><h2><tt class="xref py py-mod docutils literal"><span class="pre">projects</span></tt> Module<a class="headerlink" href="#module-composer.cli.projects" title="Permalink to this headline">¶</a></h2>
|
||||
<dl class="function">
|
||||
<dt id="composer.cli.projects.projects_cmd">
|
||||
<tt class="descclassname">composer.cli.projects.</tt><tt class="descname">projects_cmd</tt><big>(</big><em>opts</em><big>)</big><a class="reference internal" href="_modules/composer/cli/projects.html#projects_cmd"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#composer.cli.projects.projects_cmd" title="Permalink to this definition">¶</a></dt>
|
||||
<dd><p>Process projects commands</p>
|
||||
<table class="docutils field-list" frame="void" rules="none">
|
||||
<col class="field-name" />
|
||||
<col class="field-body" />
|
||||
<tbody valign="top">
|
||||
<tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><strong>opts</strong> (<a class="reference external" href="https://docs.python.org/2/library/argparse.html#argparse.Namespace" title="(in Python v2.7)"><em>argparse.Namespace</em></a>) – Cmdline arguments</td>
|
||||
</tr>
|
||||
<tr class="field-even field"><th class="field-name">Returns:</th><td class="field-body">Value to return from sys.exit()</td>
|
||||
</tr>
|
||||
<tr class="field-odd field"><th class="field-name">Return type:</th><td class="field-body">int</td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
</dd></dl>
|
||||
|
||||
<dl class="function">
|
||||
<dt id="composer.cli.projects.projects_info">
|
||||
<tt class="descclassname">composer.cli.projects.</tt><tt class="descname">projects_info</tt><big>(</big><em>socket_path</em>, <em>api_version</em>, <em>args</em>, <em>show_json=False</em><big>)</big><a class="reference internal" href="_modules/composer/cli/projects.html#projects_info"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#composer.cli.projects.projects_info" title="Permalink to this definition">¶</a></dt>
|
||||
<dd><p>Output info on a list of projects</p>
|
||||
<table class="docutils field-list" frame="void" rules="none">
|
||||
<col class="field-name" />
|
||||
<col class="field-body" />
|
||||
<tbody valign="top">
|
||||
<tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><ul class="first last simple">
|
||||
<li><strong>socket_path</strong> (<a class="reference external" href="https://docs.python.org/2/library/functions.html#str" title="(in Python v2.7)"><em>str</em></a>) – Path to the Unix socket to use for API communication</li>
|
||||
<li><strong>api_version</strong> (<a class="reference external" href="https://docs.python.org/2/library/functions.html#str" title="(in Python v2.7)"><em>str</em></a>) – Version of the API to talk to. eg. “0”</li>
|
||||
<li><strong>args</strong> (<em>list of str</em>) – List of remaining arguments from the cmdline</li>
|
||||
<li><strong>show_json</strong> (<a class="reference external" href="https://docs.python.org/2/library/functions.html#bool" title="(in Python v2.7)"><em>bool</em></a>) – Set to True to show the JSON output instead of the human readable output</li>
|
||||
</ul>
|
||||
</td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
<p>projects info <project,...></p>
|
||||
</dd></dl>
|
||||
|
||||
<dl class="function">
|
||||
<dt id="composer.cli.projects.projects_list">
|
||||
<tt class="descclassname">composer.cli.projects.</tt><tt class="descname">projects_list</tt><big>(</big><em>socket_path</em>, <em>api_version</em>, <em>args</em>, <em>show_json=False</em><big>)</big><a class="reference internal" href="_modules/composer/cli/projects.html#projects_list"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#composer.cli.projects.projects_list" title="Permalink to this definition">¶</a></dt>
|
||||
<dd><p>Output the list of available projects</p>
|
||||
<table class="docutils field-list" frame="void" rules="none">
|
||||
<col class="field-name" />
|
||||
<col class="field-body" />
|
||||
<tbody valign="top">
|
||||
<tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><ul class="first last simple">
|
||||
<li><strong>socket_path</strong> (<a class="reference external" href="https://docs.python.org/2/library/functions.html#str" title="(in Python v2.7)"><em>str</em></a>) – Path to the Unix socket to use for API communication</li>
|
||||
<li><strong>api_version</strong> (<a class="reference external" href="https://docs.python.org/2/library/functions.html#str" title="(in Python v2.7)"><em>str</em></a>) – Version of the API to talk to. eg. “0”</li>
|
||||
<li><strong>args</strong> (<em>list of str</em>) – List of remaining arguments from the cmdline</li>
|
||||
<li><strong>show_json</strong> (<a class="reference external" href="https://docs.python.org/2/library/functions.html#bool" title="(in Python v2.7)"><em>bool</em></a>) – Set to True to show the JSON output instead of the human readable output</li>
|
||||
</ul>
|
||||
</td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
<p>projects list</p>
|
||||
</dd></dl>
|
||||
|
||||
</div>
|
||||
<div class="section" id="module-composer.cli.recipes">
|
||||
<span id="recipes-module"></span><h2><tt class="xref py py-mod docutils literal"><span class="pre">recipes</span></tt> Module<a class="headerlink" href="#module-composer.cli.recipes" title="Permalink to this headline">¶</a></h2>
|
||||
<dl class="function">
|
||||
<dt id="composer.cli.recipes.prettyCommitDetails">
|
||||
<tt class="descclassname">composer.cli.recipes.</tt><tt class="descname">prettyCommitDetails</tt><big>(</big><em>change</em>, <em>indent=4</em><big>)</big><a class="reference internal" href="_modules/composer/cli/recipes.html#prettyCommitDetails"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#composer.cli.recipes.prettyCommitDetails" title="Permalink to this definition">¶</a></dt>
|
||||
<dd><p>Print the recipe’s change in a nice way</p>
|
||||
<table class="docutils field-list" frame="void" rules="none">
|
||||
<col class="field-name" />
|
||||
<col class="field-body" />
|
||||
<tbody valign="top">
|
||||
<tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><ul class="first last simple">
|
||||
<li><strong>change</strong> (<a class="reference external" href="https://docs.python.org/2/library/stdtypes.html#dict" title="(in Python v2.7)"><em>dict</em></a>) – The individual recipe change dict</li>
|
||||
<li><strong>indent</strong> (<a class="reference external" href="https://docs.python.org/2/library/functions.html#int" title="(in Python v2.7)"><em>int</em></a>) – Number of spaces to indent</li>
|
||||
</ul>
|
||||
</td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
</dd></dl>
|
||||
|
||||
<dl class="function">
|
||||
<dt id="composer.cli.recipes.prettyDiffEntry">
|
||||
<tt class="descclassname">composer.cli.recipes.</tt><tt class="descname">prettyDiffEntry</tt><big>(</big><em>diff</em><big>)</big><a class="reference internal" href="_modules/composer/cli/recipes.html#prettyDiffEntry"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#composer.cli.recipes.prettyDiffEntry" title="Permalink to this definition">¶</a></dt>
|
||||
<dd><p>Generate nice diff entry string.</p>
|
||||
<table class="docutils field-list" frame="void" rules="none">
|
||||
<col class="field-name" />
|
||||
<col class="field-body" />
|
||||
<tbody valign="top">
|
||||
<tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><strong>diff</strong> (<a class="reference external" href="https://docs.python.org/2/library/stdtypes.html#dict" title="(in Python v2.7)"><em>dict</em></a>) – Difference entry dict</td>
|
||||
</tr>
|
||||
<tr class="field-even field"><th class="field-name">Returns:</th><td class="field-body">Nice string</td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
</dd></dl>
|
||||
|
||||
<dl class="function">
|
||||
<dt id="composer.cli.recipes.recipes_changes">
|
||||
<tt class="descclassname">composer.cli.recipes.</tt><tt class="descname">recipes_changes</tt><big>(</big><em>socket_path</em>, <em>api_version</em>, <em>args</em>, <em>show_json=False</em><big>)</big><a class="reference internal" href="_modules/composer/cli/recipes.html#recipes_changes"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#composer.cli.recipes.recipes_changes" title="Permalink to this definition">¶</a></dt>
|
||||
<dd><p>Display the changes for each of the recipes</p>
|
||||
<table class="docutils field-list" frame="void" rules="none">
|
||||
<col class="field-name" />
|
||||
<col class="field-body" />
|
||||
<tbody valign="top">
|
||||
<tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><ul class="first last simple">
|
||||
<li><strong>socket_path</strong> (<a class="reference external" href="https://docs.python.org/2/library/functions.html#str" title="(in Python v2.7)"><em>str</em></a>) – Path to the Unix socket to use for API communication</li>
|
||||
<li><strong>api_version</strong> (<a class="reference external" href="https://docs.python.org/2/library/functions.html#str" title="(in Python v2.7)"><em>str</em></a>) – Version of the API to talk to. eg. “0”</li>
|
||||
<li><strong>args</strong> (<em>list of str</em>) – List of remaining arguments from the cmdline</li>
|
||||
<li><strong>show_json</strong> (<a class="reference external" href="https://docs.python.org/2/library/functions.html#bool" title="(in Python v2.7)"><em>bool</em></a>) – Set to True to show the JSON output instead of the human readable output</li>
|
||||
</ul>
|
||||
</td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
<p>recipes changes <recipe,...> Display the changes for each recipe.</p>
|
||||
</dd></dl>
|
||||
|
||||
<dl class="function">
|
||||
<dt id="composer.cli.recipes.recipes_cmd">
|
||||
<tt class="descclassname">composer.cli.recipes.</tt><tt class="descname">recipes_cmd</tt><big>(</big><em>opts</em><big>)</big><a class="reference internal" href="_modules/composer/cli/recipes.html#recipes_cmd"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#composer.cli.recipes.recipes_cmd" title="Permalink to this definition">¶</a></dt>
|
||||
<dd><p>Process recipes commands</p>
|
||||
<table class="docutils field-list" frame="void" rules="none">
|
||||
<col class="field-name" />
|
||||
<col class="field-body" />
|
||||
<tbody valign="top">
|
||||
<tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><strong>opts</strong> (<a class="reference external" href="https://docs.python.org/2/library/argparse.html#argparse.Namespace" title="(in Python v2.7)"><em>argparse.Namespace</em></a>) – Cmdline arguments</td>
|
||||
</tr>
|
||||
<tr class="field-even field"><th class="field-name">Returns:</th><td class="field-body">Value to return from sys.exit()</td>
|
||||
</tr>
|
||||
<tr class="field-odd field"><th class="field-name">Return type:</th><td class="field-body">int</td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
<p>This dispatches the recipes commands to a function</p>
|
||||
</dd></dl>
|
||||
|
||||
<dl class="function">
|
||||
<dt id="composer.cli.recipes.recipes_delete">
|
||||
<tt class="descclassname">composer.cli.recipes.</tt><tt class="descname">recipes_delete</tt><big>(</big><em>socket_path</em>, <em>api_version</em>, <em>args</em>, <em>show_json=False</em><big>)</big><a class="reference internal" href="_modules/composer/cli/recipes.html#recipes_delete"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#composer.cli.recipes.recipes_delete" title="Permalink to this definition">¶</a></dt>
|
||||
<dd><p>Delete a recipe from the server</p>
|
||||
<table class="docutils field-list" frame="void" rules="none">
|
||||
<col class="field-name" />
|
||||
<col class="field-body" />
|
||||
<tbody valign="top">
|
||||
<tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><ul class="first last simple">
|
||||
<li><strong>socket_path</strong> (<a class="reference external" href="https://docs.python.org/2/library/functions.html#str" title="(in Python v2.7)"><em>str</em></a>) – Path to the Unix socket to use for API communication</li>
|
||||
<li><strong>api_version</strong> (<a class="reference external" href="https://docs.python.org/2/library/functions.html#str" title="(in Python v2.7)"><em>str</em></a>) – Version of the API to talk to. eg. “0”</li>
|
||||
<li><strong>args</strong> (<em>list of str</em>) – List of remaining arguments from the cmdline</li>
|
||||
<li><strong>show_json</strong> (<a class="reference external" href="https://docs.python.org/2/library/functions.html#bool" title="(in Python v2.7)"><em>bool</em></a>) – Set to True to show the JSON output instead of the human readable output</li>
|
||||
</ul>
|
||||
</td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
<p>delete <recipe> Delete a recipe from the server</p>
|
||||
</dd></dl>
|
||||
|
||||
<dl class="function">
|
||||
<dt id="composer.cli.recipes.recipes_depsolve">
|
||||
<tt class="descclassname">composer.cli.recipes.</tt><tt class="descname">recipes_depsolve</tt><big>(</big><em>socket_path</em>, <em>api_version</em>, <em>args</em>, <em>show_json=False</em><big>)</big><a class="reference internal" href="_modules/composer/cli/recipes.html#recipes_depsolve"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#composer.cli.recipes.recipes_depsolve" title="Permalink to this definition">¶</a></dt>
|
||||
<dd><p>Display the packages needed to install the recipe</p>
|
||||
<table class="docutils field-list" frame="void" rules="none">
|
||||
<col class="field-name" />
|
||||
<col class="field-body" />
|
||||
<tbody valign="top">
|
||||
<tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><ul class="first last simple">
|
||||
<li><strong>socket_path</strong> (<a class="reference external" href="https://docs.python.org/2/library/functions.html#str" title="(in Python v2.7)"><em>str</em></a>) – Path to the Unix socket to use for API communication</li>
|
||||
<li><strong>api_version</strong> (<a class="reference external" href="https://docs.python.org/2/library/functions.html#str" title="(in Python v2.7)"><em>str</em></a>) – Version of the API to talk to. eg. “0”</li>
|
||||
<li><strong>args</strong> (<em>list of str</em>) – List of remaining arguments from the cmdline</li>
|
||||
<li><strong>show_json</strong> (<a class="reference external" href="https://docs.python.org/2/library/functions.html#bool" title="(in Python v2.7)"><em>bool</em></a>) – Set to True to show the JSON output instead of the human readable output</li>
|
||||
</ul>
|
||||
</td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
<p>recipes depsolve <recipe,...> Display the packages needed to install the recipe.</p>
|
||||
</dd></dl>
|
||||
|
||||
<dl class="function">
|
||||
<dt id="composer.cli.recipes.recipes_diff">
|
||||
<tt class="descclassname">composer.cli.recipes.</tt><tt class="descname">recipes_diff</tt><big>(</big><em>socket_path</em>, <em>api_version</em>, <em>args</em>, <em>show_json=False</em><big>)</big><a class="reference internal" href="_modules/composer/cli/recipes.html#recipes_diff"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#composer.cli.recipes.recipes_diff" title="Permalink to this definition">¶</a></dt>
|
||||
<dd><p>Display the differences between 2 versions of a recipe</p>
|
||||
<table class="docutils field-list" frame="void" rules="none">
|
||||
<col class="field-name" />
|
||||
<col class="field-body" />
|
||||
<tbody valign="top">
|
||||
<tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><ul class="first last simple">
|
||||
<li><strong>socket_path</strong> (<a class="reference external" href="https://docs.python.org/2/library/functions.html#str" title="(in Python v2.7)"><em>str</em></a>) – Path to the Unix socket to use for API communication</li>
|
||||
<li><strong>api_version</strong> (<a class="reference external" href="https://docs.python.org/2/library/functions.html#str" title="(in Python v2.7)"><em>str</em></a>) – Version of the API to talk to. eg. “0”</li>
|
||||
<li><strong>args</strong> (<em>list of str</em>) – List of remaining arguments from the cmdline</li>
|
||||
<li><strong>show_json</strong> (<a class="reference external" href="https://docs.python.org/2/library/functions.html#bool" title="(in Python v2.7)"><em>bool</em></a>) – Set to True to show the JSON output instead of the human readable output</li>
|
||||
</ul>
|
||||
</td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
<dl class="docutils">
|
||||
<dt>recipes diff <recipe-name> Display the differences between 2 versions of a recipe.</dt>
|
||||
<dd><from-commit> Commit hash or NEWEST
|
||||
<to-commit> Commit hash, NEWEST, or WORKSPACE</dd>
|
||||
</dl>
|
||||
</dd></dl>
|
||||
|
||||
<dl class="function">
|
||||
<dt id="composer.cli.recipes.recipes_freeze">
|
||||
<tt class="descclassname">composer.cli.recipes.</tt><tt class="descname">recipes_freeze</tt><big>(</big><em>socket_path</em>, <em>api_version</em>, <em>args</em>, <em>show_json=False</em><big>)</big><a class="reference internal" href="_modules/composer/cli/recipes.html#recipes_freeze"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#composer.cli.recipes.recipes_freeze" title="Permalink to this definition">¶</a></dt>
|
||||
<dd><p>Handle the recipes freeze commands</p>
|
||||
<table class="docutils field-list" frame="void" rules="none">
|
||||
<col class="field-name" />
|
||||
<col class="field-body" />
|
||||
<tbody valign="top">
|
||||
<tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><ul class="first last simple">
|
||||
<li><strong>socket_path</strong> (<a class="reference external" href="https://docs.python.org/2/library/functions.html#str" title="(in Python v2.7)"><em>str</em></a>) – Path to the Unix socket to use for API communication</li>
|
||||
<li><strong>api_version</strong> (<a class="reference external" href="https://docs.python.org/2/library/functions.html#str" title="(in Python v2.7)"><em>str</em></a>) – Version of the API to talk to. eg. “0”</li>
|
||||
<li><strong>args</strong> (<em>list of str</em>) – List of remaining arguments from the cmdline</li>
|
||||
<li><strong>show_json</strong> (<a class="reference external" href="https://docs.python.org/2/library/functions.html#bool" title="(in Python v2.7)"><em>bool</em></a>) – Set to True to show the JSON output instead of the human readable output</li>
|
||||
</ul>
|
||||
</td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
<p>recipes freeze <recipe,...> Display the frozen recipe’s modules and packages.
|
||||
recipes freeze show <recipe,...> Display the frozen recipe in TOML format.
|
||||
recipes freeze save <recipe,...> Save the frozen recipe to a file, <recipe-name>.frozen.toml.</p>
|
||||
</dd></dl>
|
||||
|
||||
<dl class="function">
|
||||
<dt id="composer.cli.recipes.recipes_freeze_save">
|
||||
<tt class="descclassname">composer.cli.recipes.</tt><tt class="descname">recipes_freeze_save</tt><big>(</big><em>socket_path</em>, <em>api_version</em>, <em>args</em>, <em>show_json=False</em><big>)</big><a class="reference internal" href="_modules/composer/cli/recipes.html#recipes_freeze_save"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#composer.cli.recipes.recipes_freeze_save" title="Permalink to this definition">¶</a></dt>
|
||||
<dd><p>Save the frozen recipe to a TOML file</p>
|
||||
<table class="docutils field-list" frame="void" rules="none">
|
||||
<col class="field-name" />
|
||||
<col class="field-body" />
|
||||
<tbody valign="top">
|
||||
<tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><ul class="first last simple">
|
||||
<li><strong>socket_path</strong> (<a class="reference external" href="https://docs.python.org/2/library/functions.html#str" title="(in Python v2.7)"><em>str</em></a>) – Path to the Unix socket to use for API communication</li>
|
||||
<li><strong>api_version</strong> (<a class="reference external" href="https://docs.python.org/2/library/functions.html#str" title="(in Python v2.7)"><em>str</em></a>) – Version of the API to talk to. eg. “0”</li>
|
||||
<li><strong>args</strong> (<em>list of str</em>) – List of remaining arguments from the cmdline</li>
|
||||
<li><strong>show_json</strong> (<a class="reference external" href="https://docs.python.org/2/library/functions.html#bool" title="(in Python v2.7)"><em>bool</em></a>) – Set to True to show the JSON output instead of the human readable output</li>
|
||||
</ul>
|
||||
</td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
<p>recipes freeze save <recipe,...> Save the frozen recipe to a file, <recipe-name>.frozen.toml.</p>
|
||||
</dd></dl>
|
||||
|
||||
<dl class="function">
|
||||
<dt id="composer.cli.recipes.recipes_freeze_show">
|
||||
<tt class="descclassname">composer.cli.recipes.</tt><tt class="descname">recipes_freeze_show</tt><big>(</big><em>socket_path</em>, <em>api_version</em>, <em>args</em>, <em>show_json=False</em><big>)</big><a class="reference internal" href="_modules/composer/cli/recipes.html#recipes_freeze_show"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#composer.cli.recipes.recipes_freeze_show" title="Permalink to this definition">¶</a></dt>
|
||||
<dd><p>Show the frozen recipe in TOML format</p>
|
||||
<table class="docutils field-list" frame="void" rules="none">
|
||||
<col class="field-name" />
|
||||
<col class="field-body" />
|
||||
<tbody valign="top">
|
||||
<tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><ul class="first last simple">
|
||||
<li><strong>socket_path</strong> (<a class="reference external" href="https://docs.python.org/2/library/functions.html#str" title="(in Python v2.7)"><em>str</em></a>) – Path to the Unix socket to use for API communication</li>
|
||||
<li><strong>api_version</strong> (<a class="reference external" href="https://docs.python.org/2/library/functions.html#str" title="(in Python v2.7)"><em>str</em></a>) – Version of the API to talk to. eg. “0”</li>
|
||||
<li><strong>args</strong> (<em>list of str</em>) – List of remaining arguments from the cmdline</li>
|
||||
<li><strong>show_json</strong> (<a class="reference external" href="https://docs.python.org/2/library/functions.html#bool" title="(in Python v2.7)"><em>bool</em></a>) – Set to True to show the JSON output instead of the human readable output</li>
|
||||
</ul>
|
||||
</td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
<p>recipes freeze show <recipe,...> Display the frozen recipe in TOML format.</p>
|
||||
</dd></dl>
|
||||
|
||||
<dl class="function">
|
||||
<dt id="composer.cli.recipes.recipes_list">
|
||||
<tt class="descclassname">composer.cli.recipes.</tt><tt class="descname">recipes_list</tt><big>(</big><em>socket_path</em>, <em>api_version</em>, <em>args</em>, <em>show_json=False</em><big>)</big><a class="reference internal" href="_modules/composer/cli/recipes.html#recipes_list"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#composer.cli.recipes.recipes_list" title="Permalink to this definition">¶</a></dt>
|
||||
<dd><p>Output the list of available recipes</p>
|
||||
<table class="docutils field-list" frame="void" rules="none">
|
||||
<col class="field-name" />
|
||||
<col class="field-body" />
|
||||
<tbody valign="top">
|
||||
<tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><ul class="first last simple">
|
||||
<li><strong>socket_path</strong> (<a class="reference external" href="https://docs.python.org/2/library/functions.html#str" title="(in Python v2.7)"><em>str</em></a>) – Path to the Unix socket to use for API communication</li>
|
||||
<li><strong>api_version</strong> (<a class="reference external" href="https://docs.python.org/2/library/functions.html#str" title="(in Python v2.7)"><em>str</em></a>) – Version of the API to talk to. eg. “0”</li>
|
||||
<li><strong>args</strong> (<em>list of str</em>) – List of remaining arguments from the cmdline</li>
|
||||
<li><strong>show_json</strong> (<a class="reference external" href="https://docs.python.org/2/library/functions.html#bool" title="(in Python v2.7)"><em>bool</em></a>) – Set to True to show the JSON output instead of the human readable output</li>
|
||||
</ul>
|
||||
</td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
<p>recipes list</p>
|
||||
</dd></dl>
|
||||
|
||||
<dl class="function">
|
||||
<dt id="composer.cli.recipes.recipes_push">
|
||||
<tt class="descclassname">composer.cli.recipes.</tt><tt class="descname">recipes_push</tt><big>(</big><em>socket_path</em>, <em>api_version</em>, <em>args</em>, <em>show_json=False</em><big>)</big><a class="reference internal" href="_modules/composer/cli/recipes.html#recipes_push"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#composer.cli.recipes.recipes_push" title="Permalink to this definition">¶</a></dt>
|
||||
<dd><p>Push a recipe TOML file to the server, updating the recipe</p>
|
||||
<table class="docutils field-list" frame="void" rules="none">
|
||||
<col class="field-name" />
|
||||
<col class="field-body" />
|
||||
<tbody valign="top">
|
||||
<tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><ul class="first last simple">
|
||||
<li><strong>socket_path</strong> (<a class="reference external" href="https://docs.python.org/2/library/functions.html#str" title="(in Python v2.7)"><em>str</em></a>) – Path to the Unix socket to use for API communication</li>
|
||||
<li><strong>api_version</strong> (<a class="reference external" href="https://docs.python.org/2/library/functions.html#str" title="(in Python v2.7)"><em>str</em></a>) – Version of the API to talk to. eg. “0”</li>
|
||||
<li><strong>args</strong> (<em>list of str</em>) – List of remaining arguments from the cmdline</li>
|
||||
<li><strong>show_json</strong> (<a class="reference external" href="https://docs.python.org/2/library/functions.html#bool" title="(in Python v2.7)"><em>bool</em></a>) – Set to True to show the JSON output instead of the human readable output</li>
|
||||
</ul>
|
||||
</td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
<p>push <recipe> Push a recipe TOML file to the server.</p>
|
||||
</dd></dl>
|
||||
|
||||
<dl class="function">
|
||||
<dt id="composer.cli.recipes.recipes_save">
|
||||
<tt class="descclassname">composer.cli.recipes.</tt><tt class="descname">recipes_save</tt><big>(</big><em>socket_path</em>, <em>api_version</em>, <em>args</em>, <em>show_json=False</em><big>)</big><a class="reference internal" href="_modules/composer/cli/recipes.html#recipes_save"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#composer.cli.recipes.recipes_save" title="Permalink to this definition">¶</a></dt>
|
||||
<dd><p>Save the recipe to a TOML file</p>
|
||||
<table class="docutils field-list" frame="void" rules="none">
|
||||
<col class="field-name" />
|
||||
<col class="field-body" />
|
||||
<tbody valign="top">
|
||||
<tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><ul class="first last simple">
|
||||
<li><strong>socket_path</strong> (<a class="reference external" href="https://docs.python.org/2/library/functions.html#str" title="(in Python v2.7)"><em>str</em></a>) – Path to the Unix socket to use for API communication</li>
|
||||
<li><strong>api_version</strong> (<a class="reference external" href="https://docs.python.org/2/library/functions.html#str" title="(in Python v2.7)"><em>str</em></a>) – Version of the API to talk to. eg. “0”</li>
|
||||
<li><strong>args</strong> (<em>list of str</em>) – List of remaining arguments from the cmdline</li>
|
||||
<li><strong>show_json</strong> (<a class="reference external" href="https://docs.python.org/2/library/functions.html#bool" title="(in Python v2.7)"><em>bool</em></a>) – Set to True to show the JSON output instead of the human readable output</li>
|
||||
</ul>
|
||||
</td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
<p>recipes save <recipe,...> Save the recipe to a file, <recipe-name>.toml</p>
|
||||
</dd></dl>
|
||||
|
||||
<dl class="function">
|
||||
<dt id="composer.cli.recipes.recipes_show">
|
||||
<tt class="descclassname">composer.cli.recipes.</tt><tt class="descname">recipes_show</tt><big>(</big><em>socket_path</em>, <em>api_version</em>, <em>args</em>, <em>show_json=False</em><big>)</big><a class="reference internal" href="_modules/composer/cli/recipes.html#recipes_show"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#composer.cli.recipes.recipes_show" title="Permalink to this definition">¶</a></dt>
|
||||
<dd><p>Show the recipes, in TOML format</p>
|
||||
<table class="docutils field-list" frame="void" rules="none">
|
||||
<col class="field-name" />
|
||||
<col class="field-body" />
|
||||
<tbody valign="top">
|
||||
<tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><ul class="first last simple">
|
||||
<li><strong>socket_path</strong> (<a class="reference external" href="https://docs.python.org/2/library/functions.html#str" title="(in Python v2.7)"><em>str</em></a>) – Path to the Unix socket to use for API communication</li>
|
||||
<li><strong>api_version</strong> (<a class="reference external" href="https://docs.python.org/2/library/functions.html#str" title="(in Python v2.7)"><em>str</em></a>) – Version of the API to talk to. eg. “0”</li>
|
||||
<li><strong>args</strong> (<em>list of str</em>) – List of remaining arguments from the cmdline</li>
|
||||
<li><strong>show_json</strong> (<a class="reference external" href="https://docs.python.org/2/library/functions.html#bool" title="(in Python v2.7)"><em>bool</em></a>) – Set to True to show the JSON output instead of the human readable output</li>
|
||||
</ul>
|
||||
</td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
<p>recipes show <recipe,...> Display the recipe in TOML format.</p>
|
||||
<p>Multiple recipes will be separated by</p>
|
||||
</dd></dl>
|
||||
|
||||
<dl class="function">
|
||||
<dt id="composer.cli.recipes.recipes_tag">
|
||||
<tt class="descclassname">composer.cli.recipes.</tt><tt class="descname">recipes_tag</tt><big>(</big><em>socket_path</em>, <em>api_version</em>, <em>args</em>, <em>show_json=False</em><big>)</big><a class="reference internal" href="_modules/composer/cli/recipes.html#recipes_tag"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#composer.cli.recipes.recipes_tag" title="Permalink to this definition">¶</a></dt>
|
||||
<dd><p>Tag the most recent recipe commit as a release</p>
|
||||
<table class="docutils field-list" frame="void" rules="none">
|
||||
<col class="field-name" />
|
||||
<col class="field-body" />
|
||||
<tbody valign="top">
|
||||
<tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><ul class="first last simple">
|
||||
<li><strong>socket_path</strong> (<a class="reference external" href="https://docs.python.org/2/library/functions.html#str" title="(in Python v2.7)"><em>str</em></a>) – Path to the Unix socket to use for API communication</li>
|
||||
<li><strong>api_version</strong> (<a class="reference external" href="https://docs.python.org/2/library/functions.html#str" title="(in Python v2.7)"><em>str</em></a>) – Version of the API to talk to. eg. “0”</li>
|
||||
<li><strong>args</strong> (<em>list of str</em>) – List of remaining arguments from the cmdline</li>
|
||||
<li><strong>show_json</strong> (<a class="reference external" href="https://docs.python.org/2/library/functions.html#bool" title="(in Python v2.7)"><em>bool</em></a>) – Set to True to show the JSON output instead of the human readable output</li>
|
||||
</ul>
|
||||
</td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
<p>recipes tag <recipe> Tag the most recent recipe commit as a release.</p>
|
||||
</dd></dl>
|
||||
|
||||
<dl class="function">
|
||||
<dt id="composer.cli.recipes.recipes_undo">
|
||||
<tt class="descclassname">composer.cli.recipes.</tt><tt class="descname">recipes_undo</tt><big>(</big><em>socket_path</em>, <em>api_version</em>, <em>args</em>, <em>show_json=False</em><big>)</big><a class="reference internal" href="_modules/composer/cli/recipes.html#recipes_undo"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#composer.cli.recipes.recipes_undo" title="Permalink to this definition">¶</a></dt>
|
||||
<dd><p>Undo changes to a recipe</p>
|
||||
<table class="docutils field-list" frame="void" rules="none">
|
||||
<col class="field-name" />
|
||||
<col class="field-body" />
|
||||
<tbody valign="top">
|
||||
<tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><ul class="first last simple">
|
||||
<li><strong>socket_path</strong> (<a class="reference external" href="https://docs.python.org/2/library/functions.html#str" title="(in Python v2.7)"><em>str</em></a>) – Path to the Unix socket to use for API communication</li>
|
||||
<li><strong>api_version</strong> (<a class="reference external" href="https://docs.python.org/2/library/functions.html#str" title="(in Python v2.7)"><em>str</em></a>) – Version of the API to talk to. eg. “0”</li>
|
||||
<li><strong>args</strong> (<em>list of str</em>) – List of remaining arguments from the cmdline</li>
|
||||
<li><strong>show_json</strong> (<a class="reference external" href="https://docs.python.org/2/library/functions.html#bool" title="(in Python v2.7)"><em>bool</em></a>) – Set to True to show the JSON output instead of the human readable output</li>
|
||||
</ul>
|
||||
</td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
<p>recipes undo <recipe> <commit> Undo changes to a recipe by reverting to the selected commit.</p>
|
||||
</dd></dl>
|
||||
|
||||
<dl class="function">
|
||||
<dt id="composer.cli.recipes.recipes_workspace">
|
||||
<tt class="descclassname">composer.cli.recipes.</tt><tt class="descname">recipes_workspace</tt><big>(</big><em>socket_path</em>, <em>api_version</em>, <em>args</em>, <em>show_json=False</em><big>)</big><a class="reference internal" href="_modules/composer/cli/recipes.html#recipes_workspace"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#composer.cli.recipes.recipes_workspace" title="Permalink to this definition">¶</a></dt>
|
||||
<dd><p>Push the recipe TOML to the temporary workspace storage</p>
|
||||
<table class="docutils field-list" frame="void" rules="none">
|
||||
<col class="field-name" />
|
||||
<col class="field-body" />
|
||||
<tbody valign="top">
|
||||
<tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><ul class="first last simple">
|
||||
<li><strong>socket_path</strong> (<a class="reference external" href="https://docs.python.org/2/library/functions.html#str" title="(in Python v2.7)"><em>str</em></a>) – Path to the Unix socket to use for API communication</li>
|
||||
<li><strong>api_version</strong> (<a class="reference external" href="https://docs.python.org/2/library/functions.html#str" title="(in Python v2.7)"><em>str</em></a>) – Version of the API to talk to. eg. “0”</li>
|
||||
<li><strong>args</strong> (<em>list of str</em>) – List of remaining arguments from the cmdline</li>
|
||||
<li><strong>show_json</strong> (<a class="reference external" href="https://docs.python.org/2/library/functions.html#bool" title="(in Python v2.7)"><em>bool</em></a>) – Set to True to show the JSON output instead of the human readable output</li>
|
||||
</ul>
|
||||
</td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
<p>recipes workspace <recipe> Push the recipe TOML to the temporary workspace storage.</p>
|
||||
</dd></dl>
|
||||
|
||||
</div>
|
||||
<div class="section" id="module-composer.cli.utilities">
|
||||
<span id="utilities-module"></span><h2><tt class="xref py py-mod docutils literal"><span class="pre">utilities</span></tt> Module<a class="headerlink" href="#module-composer.cli.utilities" title="Permalink to this headline">¶</a></h2>
|
||||
<dl class="function">
|
||||
<dt id="composer.cli.utilities.argify">
|
||||
<tt class="descclassname">composer.cli.utilities.</tt><tt class="descname">argify</tt><big>(</big><em>args</em><big>)</big><a class="reference internal" href="_modules/composer/cli/utilities.html#argify"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#composer.cli.utilities.argify" title="Permalink to this definition">¶</a></dt>
|
||||
<dd><p>Take a list of human args and return a list with each item</p>
|
||||
<table class="docutils field-list" frame="void" rules="none">
|
||||
<col class="field-name" />
|
||||
<col class="field-body" />
|
||||
<tbody valign="top">
|
||||
<tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><strong>args</strong> (<em>list of str</em>) – list of strings with possible commas and spaces</td>
|
||||
</tr>
|
||||
<tr class="field-even field"><th class="field-name">Returns:</th><td class="field-body">List of all the items</td>
|
||||
</tr>
|
||||
<tr class="field-odd field"><th class="field-name">Return type:</th><td class="field-body">list of str</td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
<p>Examples:</p>
|
||||
<p>[“one,two”, “three”, ”,four”, ”,five,”] returns [“one”, “two”, “three”, “four”, “five”]</p>
|
||||
</dd></dl>
|
||||
|
||||
<dl class="function">
|
||||
<dt id="composer.cli.utilities.frozen_toml_filename">
|
||||
<tt class="descclassname">composer.cli.utilities.</tt><tt class="descname">frozen_toml_filename</tt><big>(</big><em>recipe_name</em><big>)</big><a class="reference internal" href="_modules/composer/cli/utilities.html#frozen_toml_filename"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#composer.cli.utilities.frozen_toml_filename" title="Permalink to this definition">¶</a></dt>
|
||||
<dd><p>Convert a recipe name into a filename.toml</p>
|
||||
<table class="docutils field-list" frame="void" rules="none">
|
||||
<col class="field-name" />
|
||||
<col class="field-body" />
|
||||
<tbody valign="top">
|
||||
<tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><strong>recipe_name</strong> (<a class="reference external" href="https://docs.python.org/2/library/functions.html#str" title="(in Python v2.7)"><em>str</em></a>) – The recipe’s name</td>
|
||||
</tr>
|
||||
<tr class="field-even field"><th class="field-name">Returns:</th><td class="field-body">The recipe name with ‘ ‘ converted to - and .toml appended</td>
|
||||
</tr>
|
||||
<tr class="field-odd field"><th class="field-name">Return type:</th><td class="field-body">str</td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
</dd></dl>
|
||||
|
||||
<dl class="function">
|
||||
<dt id="composer.cli.utilities.handle_api_result">
|
||||
<tt class="descclassname">composer.cli.utilities.</tt><tt class="descname">handle_api_result</tt><big>(</big><em>result</em>, <em>show_json=False</em><big>)</big><a class="reference internal" href="_modules/composer/cli/utilities.html#handle_api_result"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#composer.cli.utilities.handle_api_result" title="Permalink to this definition">¶</a></dt>
|
||||
<dd><p>Log any errors, return the correct value</p>
|
||||
<table class="docutils field-list" frame="void" rules="none">
|
||||
<col class="field-name" />
|
||||
<col class="field-body" />
|
||||
<tbody valign="top">
|
||||
<tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><strong>result</strong> (<a class="reference external" href="https://docs.python.org/2/library/stdtypes.html#dict" title="(in Python v2.7)"><em>dict</em></a>) – JSON result from the http query</td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
</dd></dl>
|
||||
|
||||
<dl class="function">
|
||||
<dt id="composer.cli.utilities.packageNEVRA">
|
||||
<tt class="descclassname">composer.cli.utilities.</tt><tt class="descname">packageNEVRA</tt><big>(</big><em>pkg</em><big>)</big><a class="reference internal" href="_modules/composer/cli/utilities.html#packageNEVRA"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#composer.cli.utilities.packageNEVRA" title="Permalink to this definition">¶</a></dt>
|
||||
<dd><p>Return the package info as a NEVRA</p>
|
||||
<table class="docutils field-list" frame="void" rules="none">
|
||||
<col class="field-name" />
|
||||
<col class="field-body" />
|
||||
<tbody valign="top">
|
||||
<tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><strong>pkg</strong> (<a class="reference external" href="https://docs.python.org/2/library/stdtypes.html#dict" title="(in Python v2.7)"><em>dict</em></a>) – The package details</td>
|
||||
</tr>
|
||||
<tr class="field-even field"><th class="field-name">Returns:</th><td class="field-body">name-[epoch:]version-release-arch</td>
|
||||
</tr>
|
||||
<tr class="field-odd field"><th class="field-name">Return type:</th><td class="field-body">str</td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
</dd></dl>
|
||||
|
||||
<dl class="function">
|
||||
<dt id="composer.cli.utilities.toml_filename">
|
||||
<tt class="descclassname">composer.cli.utilities.</tt><tt class="descname">toml_filename</tt><big>(</big><em>recipe_name</em><big>)</big><a class="reference internal" href="_modules/composer/cli/utilities.html#toml_filename"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#composer.cli.utilities.toml_filename" title="Permalink to this definition">¶</a></dt>
|
||||
<dd><p>Convert a recipe name into a filename.toml</p>
|
||||
<table class="docutils field-list" frame="void" rules="none">
|
||||
<col class="field-name" />
|
||||
<col class="field-body" />
|
||||
<tbody valign="top">
|
||||
<tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><strong>recipe_name</strong> (<a class="reference external" href="https://docs.python.org/2/library/functions.html#str" title="(in Python v2.7)"><em>str</em></a>) – The recipe’s name</td>
|
||||
</tr>
|
||||
<tr class="field-even field"><th class="field-name">Returns:</th><td class="field-body">The recipe name with ‘ ‘ converted to - and .toml appended</td>
|
||||
</tr>
|
||||
<tr class="field-odd field"><th class="field-name">Return type:</th><td class="field-body">str</td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
</dd></dl>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="sphinxsidebar">
|
||||
<div class="sphinxsidebarwrapper">
|
||||
<h3><a href="index.html">Table Of Contents</a></h3>
|
||||
<ul>
|
||||
<li><a class="reference internal" href="#">cli Package</a><ul>
|
||||
<li><a class="reference internal" href="#id1"><tt class="docutils literal"><span class="pre">cli</span></tt> Package</a></li>
|
||||
<li><a class="reference internal" href="#module-composer.cli.compose"><tt class="docutils literal"><span class="pre">compose</span></tt> Module</a></li>
|
||||
<li><a class="reference internal" href="#module-composer.cli.modules"><tt class="docutils literal"><span class="pre">modules</span></tt> Module</a></li>
|
||||
<li><a class="reference internal" href="#module-composer.cli.projects"><tt class="docutils literal"><span class="pre">projects</span></tt> Module</a></li>
|
||||
<li><a class="reference internal" href="#module-composer.cli.recipes"><tt class="docutils literal"><span class="pre">recipes</span></tt> Module</a></li>
|
||||
<li><a class="reference internal" href="#module-composer.cli.utilities"><tt class="docutils literal"><span class="pre">utilities</span></tt> Module</a></li>
|
||||
</ul>
|
||||
</li>
|
||||
</ul>
|
||||
|
||||
<h4>Previous topic</h4>
|
||||
<p class="topless"><a href="composer.html"
|
||||
title="previous chapter">composer Package</a></p>
|
||||
<h4>Next topic</h4>
|
||||
<p class="topless"><a href="pylorax.html"
|
||||
title="next chapter">pylorax Package</a></p>
|
||||
<h3>This Page</h3>
|
||||
<ul class="this-page-menu">
|
||||
<li><a href="_sources/composer.cli.txt"
|
||||
rel="nofollow">Show Source</a></li>
|
||||
</ul>
|
||||
<div id="searchbox" style="display: none">
|
||||
<h3>Quick search</h3>
|
||||
<form class="search" action="search.html" method="get">
|
||||
<input type="text" name="q" />
|
||||
<input type="submit" value="Go" />
|
||||
<input type="hidden" name="check_keywords" value="yes" />
|
||||
<input type="hidden" name="area" value="default" />
|
||||
</form>
|
||||
<p class="searchtip" style="font-size: 90%">
|
||||
Enter search terms or a module, class or function name.
|
||||
</p>
|
||||
</div>
|
||||
<script type="text/javascript">$('#searchbox').show(0);</script>
|
||||
</div>
|
||||
</div>
|
||||
<div class="clearer"></div>
|
||||
</div>
|
||||
<div class="related">
|
||||
<h3>Navigation</h3>
|
||||
<ul>
|
||||
<li class="right" style="margin-right: 10px">
|
||||
<a href="genindex.html" title="General Index"
|
||||
>index</a></li>
|
||||
<li class="right" >
|
||||
<a href="py-modindex.html" title="Python Module Index"
|
||||
>modules</a> |</li>
|
||||
<li class="right" >
|
||||
<a href="pylorax.html" title="pylorax Package"
|
||||
>next</a> |</li>
|
||||
<li class="right" >
|
||||
<a href="composer.html" title="composer Package"
|
||||
>previous</a> |</li>
|
||||
<li><a href="index.html">Lorax 19.7.11 documentation</a> »</li>
|
||||
<li><a href="modules.html" >src</a> »</li>
|
||||
<li><a href="composer.html" >composer Package</a> »</li>
|
||||
</ul>
|
||||
</div>
|
||||
<div class="footer">
|
||||
© Copyright 2018, Red Hat, Inc..
|
||||
Created using <a href="http://sphinx.pocoo.org/">Sphinx</a> 1.1.3.
|
||||
</div>
|
||||
</body>
|
||||
</html>
|
385
lorax-composer/composer.html
Normal file
385
lorax-composer/composer.html
Normal file
@ -0,0 +1,385 @@
|
||||
|
||||
|
||||
<!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>composer Package — Lorax 19.7.11 documentation</title>
|
||||
|
||||
<link rel="stylesheet" href="_static/default.css" type="text/css" />
|
||||
<link rel="stylesheet" href="_static/pygments.css" type="text/css" />
|
||||
|
||||
<script type="text/javascript">
|
||||
var DOCUMENTATION_OPTIONS = {
|
||||
URL_ROOT: '',
|
||||
VERSION: '19.7.11',
|
||||
COLLAPSE_INDEX: false,
|
||||
FILE_SUFFIX: '.html',
|
||||
HAS_SOURCE: true
|
||||
};
|
||||
</script>
|
||||
<script type="text/javascript" src="_static/jquery.js"></script>
|
||||
<script type="text/javascript" src="_static/underscore.js"></script>
|
||||
<script type="text/javascript" src="_static/doctools.js"></script>
|
||||
<link rel="top" title="Lorax 19.7.11 documentation" href="index.html" />
|
||||
<link rel="up" title="src" href="modules.html" />
|
||||
<link rel="next" title="cli Package" href="composer.cli.html" />
|
||||
<link rel="prev" title="src" href="modules.html" />
|
||||
</head>
|
||||
<body>
|
||||
<div class="related">
|
||||
<h3>Navigation</h3>
|
||||
<ul>
|
||||
<li class="right" style="margin-right: 10px">
|
||||
<a href="genindex.html" title="General Index"
|
||||
accesskey="I">index</a></li>
|
||||
<li class="right" >
|
||||
<a href="py-modindex.html" title="Python Module Index"
|
||||
>modules</a> |</li>
|
||||
<li class="right" >
|
||||
<a href="composer.cli.html" title="cli Package"
|
||||
accesskey="N">next</a> |</li>
|
||||
<li class="right" >
|
||||
<a href="modules.html" title="src"
|
||||
accesskey="P">previous</a> |</li>
|
||||
<li><a href="index.html">Lorax 19.7.11 documentation</a> »</li>
|
||||
<li><a href="modules.html" accesskey="U">src</a> »</li>
|
||||
</ul>
|
||||
</div>
|
||||
|
||||
<div class="document">
|
||||
<div class="documentwrapper">
|
||||
<div class="bodywrapper">
|
||||
<div class="body">
|
||||
|
||||
<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="id1">
|
||||
<h2><a class="reference internal" href="#module-composer" title="composer"><tt class="xref py py-mod docutils literal"><span class="pre">composer</span></tt></a> Package<a class="headerlink" href="#id1" title="Permalink to this headline">¶</a></h2>
|
||||
<span class="target" id="module-composer"></span></div>
|
||||
<div class="section" id="module-composer.http_client">
|
||||
<span id="http-client-module"></span><h2><tt class="xref py py-mod docutils literal"><span class="pre">http_client</span></tt> Module<a class="headerlink" href="#module-composer.http_client" title="Permalink to this headline">¶</a></h2>
|
||||
<dl class="function">
|
||||
<dt id="composer.http_client.api_url">
|
||||
<tt class="descclassname">composer.http_client.</tt><tt class="descname">api_url</tt><big>(</big><em>api_version</em>, <em>url</em><big>)</big><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>
|
||||
<table class="docutils field-list" frame="void" rules="none">
|
||||
<col class="field-name" />
|
||||
<col class="field-body" />
|
||||
<tbody valign="top">
|
||||
<tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><ul class="first simple">
|
||||
<li><strong>api_version</strong> (<a class="reference external" href="https://docs.python.org/2/library/functions.html#str" title="(in Python v2.7)"><em>str</em></a>) – The version of the API to talk to. eg. “0”</li>
|
||||
<li><strong>url</strong> (<a class="reference external" href="https://docs.python.org/2/library/functions.html#str" title="(in Python v2.7)"><em>str</em></a>) – The API route to talk to</li>
|
||||
</ul>
|
||||
</td>
|
||||
</tr>
|
||||
<tr class="field-even field"><th class="field-name">Returns:</th><td class="field-body"><p class="first">The full url to use for the route and API version</p>
|
||||
</td>
|
||||
</tr>
|
||||
<tr class="field-odd field"><th class="field-name">Return type:</th><td class="field-body"><p class="first last">str</p>
|
||||
</td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
</dd></dl>
|
||||
|
||||
<dl class="function">
|
||||
<dt id="composer.http_client.delete_url_json">
|
||||
<tt class="descclassname">composer.http_client.</tt><tt class="descname">delete_url_json</tt><big>(</big><em>socket_path</em>, <em>url</em><big>)</big><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>
|
||||
<table class="docutils field-list" frame="void" rules="none">
|
||||
<col class="field-name" />
|
||||
<col class="field-body" />
|
||||
<tbody valign="top">
|
||||
<tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><ul class="first simple">
|
||||
<li><strong>socket_path</strong> (<a class="reference external" href="https://docs.python.org/2/library/functions.html#str" title="(in Python v2.7)"><em>str</em></a>) – Path to the Unix socket to use for API communication</li>
|
||||
<li><strong>url</strong> (<a class="reference external" href="https://docs.python.org/2/library/functions.html#str" title="(in Python v2.7)"><em>str</em></a>) – URL to send DELETE to</li>
|
||||
</ul>
|
||||
</td>
|
||||
</tr>
|
||||
<tr class="field-even field"><th class="field-name">Returns:</th><td class="field-body"><p class="first">The json response from the server</p>
|
||||
</td>
|
||||
</tr>
|
||||
<tr class="field-odd field"><th class="field-name">Return type:</th><td class="field-body"><p class="first last">dict</p>
|
||||
</td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
</dd></dl>
|
||||
|
||||
<dl class="function">
|
||||
<dt id="composer.http_client.download_file">
|
||||
<tt class="descclassname">composer.http_client.</tt><tt class="descname">download_file</tt><big>(</big><em>socket_path</em>, <em>url</em>, <em>progress=True</em><big>)</big><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>
|
||||
<table class="docutils field-list" frame="void" rules="none">
|
||||
<col class="field-name" />
|
||||
<col class="field-body" />
|
||||
<tbody valign="top">
|
||||
<tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><ul class="first last simple">
|
||||
<li><strong>socket_path</strong> (<a class="reference external" href="https://docs.python.org/2/library/functions.html#str" title="(in Python v2.7)"><em>str</em></a>) – Path to the Unix socket to use for API communication</li>
|
||||
<li><strong>url</strong> (<a class="reference external" href="https://docs.python.org/2/library/functions.html#str" title="(in Python v2.7)"><em>str</em></a>) – URL to send POST to</li>
|
||||
</ul>
|
||||
</td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
</dd></dl>
|
||||
|
||||
<dl class="function">
|
||||
<dt id="composer.http_client.get_filename">
|
||||
<tt class="descclassname">composer.http_client.</tt><tt class="descname">get_filename</tt><big>(</big><em>headers</em><big>)</big><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>
|
||||
<table class="docutils field-list" frame="void" rules="none">
|
||||
<col class="field-name" />
|
||||
<col class="field-body" />
|
||||
<tbody valign="top">
|
||||
<tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><strong>response</strong> (<em>Response</em>) – The urllib3 response object</td>
|
||||
</tr>
|
||||
<tr class="field-even field"><th class="field-name">Raises :</th><td class="field-body">RuntimeError if it cannot find a filename in the header</td>
|
||||
</tr>
|
||||
<tr class="field-odd field"><th class="field-name">Returns:</th><td class="field-body">Filename from content-disposition header</td>
|
||||
</tr>
|
||||
<tr class="field-even field"><th class="field-name">Return type:</th><td class="field-body">str</td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
</dd></dl>
|
||||
|
||||
<dl class="function">
|
||||
<dt id="composer.http_client.get_url_json">
|
||||
<tt class="descclassname">composer.http_client.</tt><tt class="descname">get_url_json</tt><big>(</big><em>socket_path</em>, <em>url</em><big>)</big><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>
|
||||
<table class="docutils field-list" frame="void" rules="none">
|
||||
<col class="field-name" />
|
||||
<col class="field-body" />
|
||||
<tbody valign="top">
|
||||
<tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><ul class="first simple">
|
||||
<li><strong>socket_path</strong> (<a class="reference external" href="https://docs.python.org/2/library/functions.html#str" title="(in Python v2.7)"><em>str</em></a>) – Path to the Unix socket to use for API communication</li>
|
||||
<li><strong>url</strong> (<a class="reference external" href="https://docs.python.org/2/library/functions.html#str" title="(in Python v2.7)"><em>str</em></a>) – URL to request</li>
|
||||
</ul>
|
||||
</td>
|
||||
</tr>
|
||||
<tr class="field-even field"><th class="field-name">Returns:</th><td class="field-body"><p class="first">The json response from the server</p>
|
||||
</td>
|
||||
</tr>
|
||||
<tr class="field-odd field"><th class="field-name">Return type:</th><td class="field-body"><p class="first last">dict</p>
|
||||
</td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
</dd></dl>
|
||||
|
||||
<dl class="function">
|
||||
<dt id="composer.http_client.get_url_raw">
|
||||
<tt class="descclassname">composer.http_client.</tt><tt class="descname">get_url_raw</tt><big>(</big><em>socket_path</em>, <em>url</em><big>)</big><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>
|
||||
<table class="docutils field-list" frame="void" rules="none">
|
||||
<col class="field-name" />
|
||||
<col class="field-body" />
|
||||
<tbody valign="top">
|
||||
<tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><ul class="first simple">
|
||||
<li><strong>socket_path</strong> (<a class="reference external" href="https://docs.python.org/2/library/functions.html#str" title="(in Python v2.7)"><em>str</em></a>) – Path to the Unix socket to use for API communication</li>
|
||||
<li><strong>url</strong> (<a class="reference external" href="https://docs.python.org/2/library/functions.html#str" title="(in Python v2.7)"><em>str</em></a>) – URL to request</li>
|
||||
</ul>
|
||||
</td>
|
||||
</tr>
|
||||
<tr class="field-even field"><th class="field-name">Returns:</th><td class="field-body"><p class="first">The raw response from the server</p>
|
||||
</td>
|
||||
</tr>
|
||||
<tr class="field-odd field"><th class="field-name">Return type:</th><td class="field-body"><p class="first last">str</p>
|
||||
</td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
</dd></dl>
|
||||
|
||||
<dl class="function">
|
||||
<dt id="composer.http_client.post_url">
|
||||
<tt class="descclassname">composer.http_client.</tt><tt class="descname">post_url</tt><big>(</big><em>socket_path</em>, <em>url</em>, <em>body</em><big>)</big><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>
|
||||
<table class="docutils field-list" frame="void" rules="none">
|
||||
<col class="field-name" />
|
||||
<col class="field-body" />
|
||||
<tbody valign="top">
|
||||
<tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><ul class="first simple">
|
||||
<li><strong>socket_path</strong> (<a class="reference external" href="https://docs.python.org/2/library/functions.html#str" title="(in Python v2.7)"><em>str</em></a>) – Path to the Unix socket to use for API communication</li>
|
||||
<li><strong>url</strong> (<a class="reference external" href="https://docs.python.org/2/library/functions.html#str" title="(in Python v2.7)"><em>str</em></a>) – URL to send POST to</li>
|
||||
<li><strong>body</strong> (<a class="reference external" href="https://docs.python.org/2/library/functions.html#str" title="(in Python v2.7)"><em>str</em></a>) – The data for the body of the POST</li>
|
||||
</ul>
|
||||
</td>
|
||||
</tr>
|
||||
<tr class="field-even field"><th class="field-name">Returns:</th><td class="field-body"><p class="first">The json response from the server</p>
|
||||
</td>
|
||||
</tr>
|
||||
<tr class="field-odd field"><th class="field-name">Return type:</th><td class="field-body"><p class="first last">dict</p>
|
||||
</td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
</dd></dl>
|
||||
|
||||
<dl class="function">
|
||||
<dt id="composer.http_client.post_url_json">
|
||||
<tt class="descclassname">composer.http_client.</tt><tt class="descname">post_url_json</tt><big>(</big><em>socket_path</em>, <em>url</em>, <em>body</em><big>)</big><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>
|
||||
<table class="docutils field-list" frame="void" rules="none">
|
||||
<col class="field-name" />
|
||||
<col class="field-body" />
|
||||
<tbody valign="top">
|
||||
<tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><ul class="first simple">
|
||||
<li><strong>socket_path</strong> (<a class="reference external" href="https://docs.python.org/2/library/functions.html#str" title="(in Python v2.7)"><em>str</em></a>) – Path to the Unix socket to use for API communication</li>
|
||||
<li><strong>url</strong> (<a class="reference external" href="https://docs.python.org/2/library/functions.html#str" title="(in Python v2.7)"><em>str</em></a>) – URL to send POST to</li>
|
||||
<li><strong>body</strong> (<a class="reference external" href="https://docs.python.org/2/library/functions.html#str" title="(in Python v2.7)"><em>str</em></a>) – The data for the body of the POST</li>
|
||||
</ul>
|
||||
</td>
|
||||
</tr>
|
||||
<tr class="field-even field"><th class="field-name">Returns:</th><td class="field-body"><p class="first">The json response from the server</p>
|
||||
</td>
|
||||
</tr>
|
||||
<tr class="field-odd field"><th class="field-name">Return type:</th><td class="field-body"><p class="first last">dict</p>
|
||||
</td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
</dd></dl>
|
||||
|
||||
<dl class="function">
|
||||
<dt id="composer.http_client.post_url_toml">
|
||||
<tt class="descclassname">composer.http_client.</tt><tt class="descname">post_url_toml</tt><big>(</big><em>socket_path</em>, <em>url</em>, <em>body</em><big>)</big><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 recipe to the URL</p>
|
||||
<table class="docutils field-list" frame="void" rules="none">
|
||||
<col class="field-name" />
|
||||
<col class="field-body" />
|
||||
<tbody valign="top">
|
||||
<tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><ul class="first simple">
|
||||
<li><strong>socket_path</strong> (<a class="reference external" href="https://docs.python.org/2/library/functions.html#str" title="(in Python v2.7)"><em>str</em></a>) – Path to the Unix socket to use for API communication</li>
|
||||
<li><strong>url</strong> (<a class="reference external" href="https://docs.python.org/2/library/functions.html#str" title="(in Python v2.7)"><em>str</em></a>) – URL to send POST to</li>
|
||||
<li><strong>body</strong> (<a class="reference external" href="https://docs.python.org/2/library/functions.html#str" title="(in Python v2.7)"><em>str</em></a>) – The data for the body of the POST</li>
|
||||
</ul>
|
||||
</td>
|
||||
</tr>
|
||||
<tr class="field-even field"><th class="field-name">Returns:</th><td class="field-body"><p class="first">The json response from the server</p>
|
||||
</td>
|
||||
</tr>
|
||||
<tr class="field-odd field"><th class="field-name">Return type:</th><td class="field-body"><p class="first last">dict</p>
|
||||
</td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
</dd></dl>
|
||||
|
||||
</div>
|
||||
<div class="section" id="module-composer.unix_socket">
|
||||
<span id="unix-socket-module"></span><h2><tt class="xref py py-mod docutils literal"><span class="pre">unix_socket</span></tt> Module<a class="headerlink" href="#module-composer.unix_socket" title="Permalink to this headline">¶</a></h2>
|
||||
<dl class="class">
|
||||
<dt id="composer.unix_socket.UnixHTTPConnection">
|
||||
<em class="property">class </em><tt class="descclassname">composer.unix_socket.</tt><tt class="descname">UnixHTTPConnection</tt><big>(</big><em>socket_path</em>, <em>timeout=60</em><big>)</big><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>
|
||||
<dd><p>Bases: <a class="reference external" href="https://docs.python.org/2/library/httplib.html#httplib.HTTPConnection" title="(in Python v2.7)"><tt class="xref py py-class docutils literal"><span class="pre">httplib.HTTPConnection</span></tt></a>, <a class="reference external" href="https://docs.python.org/2/library/functions.html#object" title="(in Python v2.7)"><tt class="xref py py-class docutils literal"><span class="pre">object</span></tt></a></p>
|
||||
<dl class="method">
|
||||
<dt id="composer.unix_socket.UnixHTTPConnection.connect">
|
||||
<tt class="descname">connect</tt><big>(</big><big>)</big><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></dd></dl>
|
||||
|
||||
</dd></dl>
|
||||
|
||||
<dl class="class">
|
||||
<dt id="composer.unix_socket.UnixHTTPConnectionPool">
|
||||
<em class="property">class </em><tt class="descclassname">composer.unix_socket.</tt><tt class="descname">UnixHTTPConnectionPool</tt><big>(</big><em>socket_path</em>, <em>timeout=60</em><big>)</big><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: <tt class="xref py py-class docutils literal"><span class="pre">urllib3.connectionpool.HTTPConnectionPool</span></tt></p>
|
||||
</dd></dl>
|
||||
|
||||
</div>
|
||||
<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">cli Package</a><ul>
|
||||
<li class="toctree-l2"><a class="reference internal" href="composer.cli.html#id1"><tt class="docutils literal"><span class="pre">cli</span></tt> Package</a></li>
|
||||
<li class="toctree-l2"><a class="reference internal" href="composer.cli.html#module-composer.cli.compose"><tt class="docutils literal"><span class="pre">compose</span></tt> Module</a></li>
|
||||
<li class="toctree-l2"><a class="reference internal" href="composer.cli.html#module-composer.cli.modules"><tt class="docutils literal"><span class="pre">modules</span></tt> Module</a></li>
|
||||
<li class="toctree-l2"><a class="reference internal" href="composer.cli.html#module-composer.cli.projects"><tt class="docutils literal"><span class="pre">projects</span></tt> Module</a></li>
|
||||
<li class="toctree-l2"><a class="reference internal" href="composer.cli.html#module-composer.cli.recipes"><tt class="docutils literal"><span class="pre">recipes</span></tt> Module</a></li>
|
||||
<li class="toctree-l2"><a class="reference internal" href="composer.cli.html#module-composer.cli.utilities"><tt class="docutils literal"><span class="pre">utilities</span></tt> Module</a></li>
|
||||
</ul>
|
||||
</li>
|
||||
</ul>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="sphinxsidebar">
|
||||
<div class="sphinxsidebarwrapper">
|
||||
<h3><a href="index.html">Table Of Contents</a></h3>
|
||||
<ul>
|
||||
<li><a class="reference internal" href="#">composer Package</a><ul>
|
||||
<li><a class="reference internal" href="#id1"><tt class="docutils literal"><span class="pre">composer</span></tt> Package</a></li>
|
||||
<li><a class="reference internal" href="#module-composer.http_client"><tt class="docutils literal"><span class="pre">http_client</span></tt> Module</a></li>
|
||||
<li><a class="reference internal" href="#module-composer.unix_socket"><tt class="docutils literal"><span class="pre">unix_socket</span></tt> Module</a></li>
|
||||
<li><a class="reference internal" href="#subpackages">Subpackages</a><ul>
|
||||
</ul>
|
||||
</li>
|
||||
</ul>
|
||||
</li>
|
||||
</ul>
|
||||
|
||||
<h4>Previous topic</h4>
|
||||
<p class="topless"><a href="modules.html"
|
||||
title="previous chapter">src</a></p>
|
||||
<h4>Next topic</h4>
|
||||
<p class="topless"><a href="composer.cli.html"
|
||||
title="next chapter">cli Package</a></p>
|
||||
<h3>This Page</h3>
|
||||
<ul class="this-page-menu">
|
||||
<li><a href="_sources/composer.txt"
|
||||
rel="nofollow">Show Source</a></li>
|
||||
</ul>
|
||||
<div id="searchbox" style="display: none">
|
||||
<h3>Quick search</h3>
|
||||
<form class="search" action="search.html" method="get">
|
||||
<input type="text" name="q" />
|
||||
<input type="submit" value="Go" />
|
||||
<input type="hidden" name="check_keywords" value="yes" />
|
||||
<input type="hidden" name="area" value="default" />
|
||||
</form>
|
||||
<p class="searchtip" style="font-size: 90%">
|
||||
Enter search terms or a module, class or function name.
|
||||
</p>
|
||||
</div>
|
||||
<script type="text/javascript">$('#searchbox').show(0);</script>
|
||||
</div>
|
||||
</div>
|
||||
<div class="clearer"></div>
|
||||
</div>
|
||||
<div class="related">
|
||||
<h3>Navigation</h3>
|
||||
<ul>
|
||||
<li class="right" style="margin-right: 10px">
|
||||
<a href="genindex.html" title="General Index"
|
||||
>index</a></li>
|
||||
<li class="right" >
|
||||
<a href="py-modindex.html" title="Python Module Index"
|
||||
>modules</a> |</li>
|
||||
<li class="right" >
|
||||
<a href="composer.cli.html" title="cli Package"
|
||||
>next</a> |</li>
|
||||
<li class="right" >
|
||||
<a href="modules.html" title="src"
|
||||
>previous</a> |</li>
|
||||
<li><a href="index.html">Lorax 19.7.11 documentation</a> »</li>
|
||||
<li><a href="modules.html" >src</a> »</li>
|
||||
</ul>
|
||||
</div>
|
||||
<div class="footer">
|
||||
© Copyright 2018, Red Hat, Inc..
|
||||
Created using <a href="http://sphinx.pocoo.org/">Sphinx</a> 1.1.3.
|
||||
</div>
|
||||
</body>
|
||||
</html>
|
@ -10,7 +10,7 @@
|
||||
<head>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
|
||||
|
||||
<title>Index — Lorax 19.7.10 documentation</title>
|
||||
<title>Index — Lorax 19.7.11 documentation</title>
|
||||
|
||||
<link rel="stylesheet" href="_static/default.css" type="text/css" />
|
||||
<link rel="stylesheet" href="_static/pygments.css" type="text/css" />
|
||||
@ -18,7 +18,7 @@
|
||||
<script type="text/javascript">
|
||||
var DOCUMENTATION_OPTIONS = {
|
||||
URL_ROOT: '',
|
||||
VERSION: '19.7.10',
|
||||
VERSION: '19.7.11',
|
||||
COLLAPSE_INDEX: false,
|
||||
FILE_SUFFIX: '.html',
|
||||
HAS_SOURCE: true
|
||||
@ -27,7 +27,7 @@
|
||||
<script type="text/javascript" src="_static/jquery.js"></script>
|
||||
<script type="text/javascript" src="_static/underscore.js"></script>
|
||||
<script type="text/javascript" src="_static/doctools.js"></script>
|
||||
<link rel="top" title="Lorax 19.7.10 documentation" href="index.html" />
|
||||
<link rel="top" title="Lorax 19.7.11 documentation" href="index.html" />
|
||||
</head>
|
||||
<body>
|
||||
<div class="related">
|
||||
@ -39,7 +39,7 @@
|
||||
<li class="right" >
|
||||
<a href="py-modindex.html" title="Python Module Index"
|
||||
>modules</a> |</li>
|
||||
<li><a href="index.html">Lorax 19.7.10 documentation</a> »</li>
|
||||
<li><a href="index.html">Lorax 19.7.11 documentation</a> »</li>
|
||||
</ul>
|
||||
</div>
|
||||
|
||||
@ -93,6 +93,10 @@
|
||||
<dt><a href="pylorax.api.html#pylorax.api.projects.api_time">api_time() (in module pylorax.api.projects)</a>
|
||||
</dt>
|
||||
|
||||
|
||||
<dt><a href="composer.html#composer.http_client.api_url">api_url() (in module composer.http_client)</a>
|
||||
</dt>
|
||||
|
||||
</dl></td>
|
||||
<td style="width: 33%" valign="top"><dl>
|
||||
|
||||
@ -100,7 +104,11 @@
|
||||
</dt>
|
||||
|
||||
|
||||
<dt><a href="pylorax.html#pylorax.__init__.ArchData">ArchData (class in pylorax.__init__)</a>
|
||||
<dt><a href="pylorax.html#pylorax.ArchData">ArchData (class in pylorax)</a>
|
||||
</dt>
|
||||
|
||||
|
||||
<dt><a href="composer.cli.html#composer.cli.utilities.argify">argify() (in module composer.cli.utilities)</a>
|
||||
</dt>
|
||||
|
||||
</dl></td>
|
||||
@ -114,7 +122,7 @@
|
||||
</dt>
|
||||
|
||||
|
||||
<dt><a href="pylorax.html#pylorax.__init__.ArchData.bcj_arch">bcj_arch (pylorax.__init__.ArchData attribute)</a>
|
||||
<dt><a href="pylorax.html#pylorax.ArchData.bcj_arch">bcj_arch (pylorax.ArchData attribute)</a>
|
||||
</dt>
|
||||
|
||||
|
||||
@ -186,13 +194,99 @@
|
||||
</dt>
|
||||
|
||||
|
||||
<dt><a href="composer.cli.html#composer.cli.compose.compose_cancel">compose_cancel() (in module composer.cli.compose)</a>
|
||||
</dt>
|
||||
|
||||
|
||||
<dt><a href="composer.cli.html#composer.cli.compose.compose_cmd">compose_cmd() (in module composer.cli.compose)</a>
|
||||
</dt>
|
||||
|
||||
|
||||
<dt><a href="composer.cli.html#composer.cli.compose.compose_delete">compose_delete() (in module composer.cli.compose)</a>
|
||||
</dt>
|
||||
|
||||
|
||||
<dt><a href="pylorax.api.html#pylorax.api.queue.compose_detail">compose_detail() (in module pylorax.api.queue)</a>
|
||||
</dt>
|
||||
|
||||
|
||||
<dt><a href="composer.cli.html#composer.cli.compose.compose_details">compose_details() (in module composer.cli.compose)</a>
|
||||
</dt>
|
||||
|
||||
|
||||
<dt><a href="composer.cli.html#composer.cli.compose.compose_image">compose_image() (in module composer.cli.compose)</a>
|
||||
</dt>
|
||||
|
||||
|
||||
<dt><a href="composer.cli.html#composer.cli.compose.compose_log">compose_log() (in module composer.cli.compose)</a>
|
||||
</dt>
|
||||
|
||||
|
||||
<dt><a href="composer.cli.html#composer.cli.compose.compose_logs">compose_logs() (in module composer.cli.compose)</a>
|
||||
</dt>
|
||||
|
||||
|
||||
<dt><a href="composer.cli.html#composer.cli.compose.compose_metadata">compose_metadata() (in module composer.cli.compose)</a>
|
||||
</dt>
|
||||
|
||||
|
||||
<dt><a href="composer.cli.html#composer.cli.compose.compose_results">compose_results() (in module composer.cli.compose)</a>
|
||||
</dt>
|
||||
|
||||
|
||||
<dt><a href="composer.cli.html#composer.cli.compose.compose_start">compose_start() (in module composer.cli.compose)</a>
|
||||
</dt>
|
||||
|
||||
|
||||
<dt><a href="composer.cli.html#composer.cli.compose.compose_status">compose_status() (in module composer.cli.compose)</a>
|
||||
</dt>
|
||||
|
||||
</dl></td>
|
||||
<td style="width: 33%" valign="top"><dl>
|
||||
|
||||
<dt><a href="pylorax.api.html#pylorax.api.compose.compose_types">compose_types() (in module pylorax.api.compose)</a>
|
||||
<dt><a href="composer.cli.html#composer.cli.compose.compose_types">compose_types() (in module composer.cli.compose)</a>
|
||||
</dt>
|
||||
|
||||
<dd><dl>
|
||||
|
||||
<dt><a href="pylorax.api.html#pylorax.api.compose.compose_types">(in module pylorax.api.compose)</a>
|
||||
</dt>
|
||||
|
||||
</dl></dd>
|
||||
|
||||
<dt><a href="composer.html#module-composer">composer (module)</a>
|
||||
</dt>
|
||||
|
||||
|
||||
<dt><a href="composer.cli.html#module-composer.cli">composer.cli (module)</a>
|
||||
</dt>
|
||||
|
||||
|
||||
<dt><a href="composer.cli.html#module-composer.cli.compose">composer.cli.compose (module)</a>
|
||||
</dt>
|
||||
|
||||
|
||||
<dt><a href="composer.cli.html#module-composer.cli.modules">composer.cli.modules (module)</a>
|
||||
</dt>
|
||||
|
||||
|
||||
<dt><a href="composer.cli.html#module-composer.cli.projects">composer.cli.projects (module)</a>
|
||||
</dt>
|
||||
|
||||
|
||||
<dt><a href="composer.cli.html#module-composer.cli.recipes">composer.cli.recipes (module)</a>
|
||||
</dt>
|
||||
|
||||
|
||||
<dt><a href="composer.cli.html#module-composer.cli.utilities">composer.cli.utilities (module)</a>
|
||||
</dt>
|
||||
|
||||
|
||||
<dt><a href="composer.html#module-composer.http_client">composer.http_client (module)</a>
|
||||
</dt>
|
||||
|
||||
|
||||
<dt><a href="composer.html#module-composer.unix_socket">composer.unix_socket (module)</a>
|
||||
</dt>
|
||||
|
||||
|
||||
@ -209,11 +303,15 @@
|
||||
|
||||
<dd><dl>
|
||||
|
||||
<dt><a href="pylorax.html#pylorax.__init__.Lorax.configure">(pylorax.__init__.Lorax method)</a>
|
||||
<dt><a href="pylorax.html#pylorax.Lorax.configure">(pylorax.Lorax method)</a>
|
||||
</dt>
|
||||
|
||||
</dl></dd>
|
||||
|
||||
<dt><a href="composer.html#composer.unix_socket.UnixHTTPConnection.connect">connect() (composer.unix_socket.UnixHTTPConnection method)</a>
|
||||
</dt>
|
||||
|
||||
|
||||
<dt><a href="pylorax.html#pylorax.base.DataHolder.copy">copy() (pylorax.base.DataHolder method)</a>
|
||||
</dt>
|
||||
|
||||
@ -276,6 +374,10 @@
|
||||
</dt>
|
||||
|
||||
|
||||
<dt><a href="composer.html#composer.http_client.delete_url_json">delete_url_json() (in module composer.http_client)</a>
|
||||
</dt>
|
||||
|
||||
|
||||
<dt><a href="pylorax.api.html#pylorax.api.projects.dep_evra">dep_evra() (in module pylorax.api.projects)</a>
|
||||
</dt>
|
||||
|
||||
@ -318,6 +420,10 @@
|
||||
</dt>
|
||||
|
||||
|
||||
<dt><a href="composer.html#composer.http_client.download_file">download_file() (in module composer.http_client)</a>
|
||||
</dt>
|
||||
|
||||
|
||||
<dt><a href="pylorax.html#pylorax.treebuilder.TreeBuilder.dracut_hooks_path">dracut_hooks_path (pylorax.treebuilder.TreeBuilder attribute)</a>
|
||||
</dt>
|
||||
|
||||
@ -393,12 +499,12 @@
|
||||
<dt><a href="pylorax.api.html#pylorax.api.recipes.find_name">find_name() (in module pylorax.api.recipes)</a>
|
||||
</dt>
|
||||
|
||||
</dl></td>
|
||||
<td style="width: 33%" valign="top"><dl>
|
||||
|
||||
<dt><a href="pylorax.html#pylorax.creator.find_ostree_root">find_ostree_root() (in module pylorax.creator)</a>
|
||||
</dt>
|
||||
|
||||
</dl></td>
|
||||
<td style="width: 33%" valign="top"><dl>
|
||||
|
||||
<dt><a href="pylorax.html#pylorax.treebuilder.findkernels">findkernels() (in module pylorax.treebuilder)</a>
|
||||
</dt>
|
||||
@ -411,6 +517,10 @@
|
||||
<dt><a href="pylorax.api.html#pylorax.api.recipes.Recipe.freeze">freeze() (pylorax.api.recipes.Recipe method)</a>
|
||||
</dt>
|
||||
|
||||
|
||||
<dt><a href="composer.cli.html#composer.cli.utilities.frozen_toml_filename">frozen_toml_filename() (in module composer.cli.utilities)</a>
|
||||
</dt>
|
||||
|
||||
</dl></td>
|
||||
</tr></table>
|
||||
|
||||
@ -434,7 +544,7 @@
|
||||
</dt>
|
||||
|
||||
|
||||
<dt><a href="pylorax.html#pylorax.__init__.get_buildarch">get_buildarch() (in module pylorax.__init__)</a>
|
||||
<dt><a href="pylorax.html#pylorax.get_buildarch">get_buildarch() (in module pylorax)</a>
|
||||
</dt>
|
||||
|
||||
|
||||
@ -449,12 +559,16 @@
|
||||
<dt><a href="pylorax.api.html#pylorax.api.config.ComposerConfig.get_default">get_default() (pylorax.api.config.ComposerConfig method)</a>
|
||||
</dt>
|
||||
|
||||
</dl></td>
|
||||
<td style="width: 33%" valign="top"><dl>
|
||||
|
||||
<dt><a href="composer.html#composer.http_client.get_filename">get_filename() (in module composer.http_client)</a>
|
||||
</dt>
|
||||
|
||||
|
||||
<dt><a href="pylorax.html#pylorax.installer.IsoMountpoint.get_iso_label">get_iso_label() (pylorax.installer.IsoMountpoint method)</a>
|
||||
</dt>
|
||||
|
||||
</dl></td>
|
||||
<td style="width: 33%" valign="top"><dl>
|
||||
|
||||
<dt><a href="pylorax.html#pylorax.creator.KernelInfo.get_kernel_arch">get_kernel_arch() (pylorax.creator.KernelInfo method)</a>
|
||||
</dt>
|
||||
@ -476,6 +590,14 @@
|
||||
</dt>
|
||||
|
||||
|
||||
<dt><a href="composer.html#composer.http_client.get_url_json">get_url_json() (in module composer.http_client)</a>
|
||||
</dt>
|
||||
|
||||
|
||||
<dt><a href="composer.html#composer.http_client.get_url_raw">get_url_raw() (in module composer.http_client)</a>
|
||||
</dt>
|
||||
|
||||
|
||||
<dt><a href="pylorax.api.html#pylorax.api.recipes.gfile">gfile() (in module pylorax.api.recipes)</a>
|
||||
</dt>
|
||||
|
||||
@ -494,12 +616,16 @@
|
||||
</dt>
|
||||
|
||||
|
||||
<dt><a href="pylorax.html#pylorax.ltmpl.LoraxTemplateRunner.hardlink">hardlink() (pylorax.ltmpl.LoraxTemplateRunner method)</a>
|
||||
<dt><a href="composer.cli.html#composer.cli.utilities.handle_api_result">handle_api_result() (in module composer.cli.utilities)</a>
|
||||
</dt>
|
||||
|
||||
</dl></td>
|
||||
<td style="width: 33%" valign="top"><dl>
|
||||
|
||||
<dt><a href="pylorax.html#pylorax.ltmpl.LoraxTemplateRunner.hardlink">hardlink() (pylorax.ltmpl.LoraxTemplateRunner method)</a>
|
||||
</dt>
|
||||
|
||||
|
||||
<dt><a href="pylorax.api.html#pylorax.api.recipes.head_commit">head_commit() (in module pylorax.api.recipes)</a>
|
||||
</dt>
|
||||
|
||||
@ -514,11 +640,11 @@
|
||||
</dt>
|
||||
|
||||
|
||||
<dt><a href="pylorax.html#pylorax.__init__.Lorax.init_file_logging">init_file_logging() (pylorax.__init__.Lorax method)</a>
|
||||
<dt><a href="pylorax.html#pylorax.Lorax.init_file_logging">init_file_logging() (pylorax.Lorax method)</a>
|
||||
</dt>
|
||||
|
||||
|
||||
<dt><a href="pylorax.html#pylorax.__init__.Lorax.init_stream_logging">init_stream_logging() (pylorax.__init__.Lorax method)</a>
|
||||
<dt><a href="pylorax.html#pylorax.Lorax.init_stream_logging">init_stream_logging() (pylorax.Lorax method)</a>
|
||||
</dt>
|
||||
|
||||
|
||||
@ -610,7 +736,7 @@
|
||||
<table style="width: 100%" class="indextable genindextable"><tr>
|
||||
<td style="width: 33%" valign="top"><dl>
|
||||
|
||||
<dt><a href="pylorax.html#pylorax.__init__.ArchData.lib64_arches">lib64_arches (pylorax.__init__.ArchData attribute)</a>
|
||||
<dt><a href="pylorax.html#pylorax.ArchData.lib64_arches">lib64_arches (pylorax.ArchData attribute)</a>
|
||||
</dt>
|
||||
|
||||
|
||||
@ -672,7 +798,7 @@
|
||||
</dt>
|
||||
|
||||
|
||||
<dt><a href="pylorax.html#pylorax.__init__.Lorax">Lorax (class in pylorax.__init__)</a>
|
||||
<dt><a href="pylorax.html#pylorax.Lorax">Lorax (class in pylorax)</a>
|
||||
</dt>
|
||||
|
||||
|
||||
@ -702,6 +828,10 @@
|
||||
<table style="width: 100%" class="indextable genindextable"><tr>
|
||||
<td style="width: 33%" valign="top"><dl>
|
||||
|
||||
<dt><a href="composer.cli.html#composer.cli.main">main() (in module composer.cli)</a>
|
||||
</dt>
|
||||
|
||||
|
||||
<dt><a href="pylorax.html#pylorax.creator.make_appliance">make_appliance() (in module pylorax.creator)</a>
|
||||
</dt>
|
||||
|
||||
@ -796,6 +926,10 @@
|
||||
</dt>
|
||||
|
||||
|
||||
<dt><a href="composer.cli.html#composer.cli.modules.modules_cmd">modules_cmd() (in module composer.cli.modules)</a>
|
||||
</dt>
|
||||
|
||||
|
||||
<dt><a href="pylorax.api.html#pylorax.api.projects.modules_info">modules_info() (in module pylorax.api.projects)</a>
|
||||
</dt>
|
||||
|
||||
@ -858,6 +992,10 @@
|
||||
</dt>
|
||||
|
||||
|
||||
<dt><a href="composer.cli.html#composer.cli.utilities.packageNEVRA">packageNEVRA() (in module composer.cli.utilities)</a>
|
||||
</dt>
|
||||
|
||||
|
||||
<dt><a href="pylorax.html#pylorax.ltmpl.LoraxTemplate.parse">parse() (pylorax.ltmpl.LoraxTemplate method)</a>
|
||||
</dt>
|
||||
|
||||
@ -882,6 +1020,18 @@
|
||||
</dt>
|
||||
|
||||
|
||||
<dt><a href="composer.html#composer.http_client.post_url">post_url() (in module composer.http_client)</a>
|
||||
</dt>
|
||||
|
||||
|
||||
<dt><a href="composer.html#composer.http_client.post_url_json">post_url_json() (in module composer.http_client)</a>
|
||||
</dt>
|
||||
|
||||
|
||||
<dt><a href="composer.html#composer.http_client.post_url_toml">post_url_toml() (in module composer.http_client)</a>
|
||||
</dt>
|
||||
|
||||
|
||||
<dt><a href="pylorax.html#pylorax.treebuilder.RuntimeBuilder.postinstall">postinstall() (pylorax.treebuilder.RuntimeBuilder method)</a>
|
||||
</dt>
|
||||
|
||||
@ -890,17 +1040,41 @@
|
||||
</dt>
|
||||
|
||||
|
||||
<dt><a href="composer.cli.html#composer.cli.recipes.prettyCommitDetails">prettyCommitDetails() (in module composer.cli.recipes)</a>
|
||||
</dt>
|
||||
|
||||
|
||||
<dt><a href="composer.cli.html#composer.cli.recipes.prettyDiffEntry">prettyDiffEntry() (in module composer.cli.recipes)</a>
|
||||
</dt>
|
||||
|
||||
|
||||
<dt><a href="composer.cli.html#composer.cli.projects.projects_cmd">projects_cmd() (in module composer.cli.projects)</a>
|
||||
</dt>
|
||||
|
||||
|
||||
<dt><a href="pylorax.api.html#pylorax.api.projects.projects_depsolve">projects_depsolve() (in module pylorax.api.projects)</a>
|
||||
</dt>
|
||||
|
||||
|
||||
<dt><a href="pylorax.api.html#pylorax.api.projects.projects_info">projects_info() (in module pylorax.api.projects)</a>
|
||||
<dt><a href="composer.cli.html#composer.cli.projects.projects_info">projects_info() (in module composer.cli.projects)</a>
|
||||
</dt>
|
||||
|
||||
<dd><dl>
|
||||
|
||||
<dt><a href="pylorax.api.html#pylorax.api.projects.projects_list">projects_list() (in module pylorax.api.projects)</a>
|
||||
<dt><a href="pylorax.api.html#pylorax.api.projects.projects_info">(in module pylorax.api.projects)</a>
|
||||
</dt>
|
||||
|
||||
</dl></dd>
|
||||
|
||||
<dt><a href="composer.cli.html#composer.cli.projects.projects_list">projects_list() (in module composer.cli.projects)</a>
|
||||
</dt>
|
||||
|
||||
<dd><dl>
|
||||
|
||||
<dt><a href="pylorax.api.html#pylorax.api.projects.projects_list">(in module pylorax.api.projects)</a>
|
||||
</dt>
|
||||
|
||||
</dl></dd>
|
||||
|
||||
<dt><a href="pylorax.api.html#pylorax.api.projects.ProjectsError">ProjectsError</a>
|
||||
</dt>
|
||||
@ -910,7 +1084,7 @@
|
||||
</dt>
|
||||
|
||||
|
||||
<dt><a href="pylorax.html#module-pylorax.__init__">pylorax.__init__ (module)</a>
|
||||
<dt><a href="pylorax.html#module-pylorax">pylorax (module)</a>
|
||||
</dt>
|
||||
|
||||
|
||||
@ -921,6 +1095,8 @@
|
||||
<dt><a href="pylorax.api.html#module-pylorax.api.compose">pylorax.api.compose (module)</a>
|
||||
</dt>
|
||||
|
||||
</dl></td>
|
||||
<td style="width: 33%" valign="top"><dl>
|
||||
|
||||
<dt><a href="pylorax.api.html#module-pylorax.api.config">pylorax.api.config (module)</a>
|
||||
</dt>
|
||||
@ -937,8 +1113,6 @@
|
||||
<dt><a href="pylorax.api.html#module-pylorax.api.queue">pylorax.api.queue (module)</a>
|
||||
</dt>
|
||||
|
||||
</dl></td>
|
||||
<td style="width: 33%" valign="top"><dl>
|
||||
|
||||
<dt><a href="pylorax.api.html#module-pylorax.api.recipes">pylorax.api.recipes (module)</a>
|
||||
</dt>
|
||||
@ -1100,6 +1274,68 @@
|
||||
</dt>
|
||||
|
||||
|
||||
<dt><a href="composer.cli.html#composer.cli.recipes.recipes_changes">recipes_changes() (in module composer.cli.recipes)</a>
|
||||
</dt>
|
||||
|
||||
|
||||
<dt><a href="composer.cli.html#composer.cli.recipes.recipes_cmd">recipes_cmd() (in module composer.cli.recipes)</a>
|
||||
</dt>
|
||||
|
||||
|
||||
<dt><a href="composer.cli.html#composer.cli.recipes.recipes_delete">recipes_delete() (in module composer.cli.recipes)</a>
|
||||
</dt>
|
||||
|
||||
|
||||
<dt><a href="composer.cli.html#composer.cli.recipes.recipes_depsolve">recipes_depsolve() (in module composer.cli.recipes)</a>
|
||||
</dt>
|
||||
|
||||
|
||||
<dt><a href="composer.cli.html#composer.cli.recipes.recipes_diff">recipes_diff() (in module composer.cli.recipes)</a>
|
||||
</dt>
|
||||
|
||||
|
||||
<dt><a href="composer.cli.html#composer.cli.recipes.recipes_freeze">recipes_freeze() (in module composer.cli.recipes)</a>
|
||||
</dt>
|
||||
|
||||
|
||||
<dt><a href="composer.cli.html#composer.cli.recipes.recipes_freeze_save">recipes_freeze_save() (in module composer.cli.recipes)</a>
|
||||
</dt>
|
||||
|
||||
|
||||
<dt><a href="composer.cli.html#composer.cli.recipes.recipes_freeze_show">recipes_freeze_show() (in module composer.cli.recipes)</a>
|
||||
</dt>
|
||||
|
||||
|
||||
<dt><a href="composer.cli.html#composer.cli.recipes.recipes_list">recipes_list() (in module composer.cli.recipes)</a>
|
||||
</dt>
|
||||
|
||||
</dl></td>
|
||||
<td style="width: 33%" valign="top"><dl>
|
||||
|
||||
<dt><a href="composer.cli.html#composer.cli.recipes.recipes_push">recipes_push() (in module composer.cli.recipes)</a>
|
||||
</dt>
|
||||
|
||||
|
||||
<dt><a href="composer.cli.html#composer.cli.recipes.recipes_save">recipes_save() (in module composer.cli.recipes)</a>
|
||||
</dt>
|
||||
|
||||
|
||||
<dt><a href="composer.cli.html#composer.cli.recipes.recipes_show">recipes_show() (in module composer.cli.recipes)</a>
|
||||
</dt>
|
||||
|
||||
|
||||
<dt><a href="composer.cli.html#composer.cli.recipes.recipes_tag">recipes_tag() (in module composer.cli.recipes)</a>
|
||||
</dt>
|
||||
|
||||
|
||||
<dt><a href="composer.cli.html#composer.cli.recipes.recipes_undo">recipes_undo() (in module composer.cli.recipes)</a>
|
||||
</dt>
|
||||
|
||||
|
||||
<dt><a href="composer.cli.html#composer.cli.recipes.recipes_workspace">recipes_workspace() (in module composer.cli.recipes)</a>
|
||||
</dt>
|
||||
|
||||
|
||||
<dt><a href="pylorax.html#pylorax.sysutils.remove">remove() (in module pylorax.sysutils)</a>
|
||||
</dt>
|
||||
|
||||
@ -1109,8 +1345,6 @@
|
||||
</dt>
|
||||
|
||||
</dl></dd>
|
||||
</dl></td>
|
||||
<td style="width: 33%" valign="top"><dl>
|
||||
|
||||
<dt><a href="pylorax.html#pylorax.ltmpl.LoraxTemplateRunner.removefrom">removefrom() (pylorax.ltmpl.LoraxTemplateRunner method)</a>
|
||||
</dt>
|
||||
@ -1162,12 +1396,12 @@
|
||||
</dt>
|
||||
|
||||
|
||||
<dt><a href="pylorax.html#pylorax.__init__.Lorax.run">run() (pylorax.__init__.Lorax method)</a>
|
||||
<dt><a href="pylorax.html#pylorax.executils.tee.run">run() (pylorax.executils.tee method)</a>
|
||||
</dt>
|
||||
|
||||
<dd><dl>
|
||||
|
||||
<dt><a href="pylorax.html#pylorax.executils.tee.run">(pylorax.executils.tee method)</a>
|
||||
<dt><a href="pylorax.html#pylorax.Lorax.run">(pylorax.Lorax method)</a>
|
||||
</dt>
|
||||
|
||||
|
||||
@ -1275,10 +1509,14 @@
|
||||
<dt><a href="pylorax.api.html#pylorax.api.projects.tm_to_dep">tm_to_dep() (in module pylorax.api.projects)</a>
|
||||
</dt>
|
||||
|
||||
|
||||
<dt><a href="pylorax.api.html#pylorax.api.recipes.Recipe.toml">toml() (pylorax.api.recipes.Recipe method)</a>
|
||||
</dt>
|
||||
|
||||
</dl></td>
|
||||
<td style="width: 33%" valign="top"><dl>
|
||||
|
||||
<dt><a href="pylorax.api.html#pylorax.api.recipes.Recipe.toml">toml() (pylorax.api.recipes.Recipe method)</a>
|
||||
<dt><a href="composer.cli.html#composer.cli.utilities.toml_filename">toml_filename() (in module composer.cli.utilities)</a>
|
||||
</dt>
|
||||
|
||||
|
||||
@ -1318,6 +1556,14 @@
|
||||
|
||||
</dl></dd>
|
||||
|
||||
<dt><a href="composer.html#composer.unix_socket.UnixHTTPConnection">UnixHTTPConnection (class in composer.unix_socket)</a>
|
||||
</dt>
|
||||
|
||||
|
||||
<dt><a href="composer.html#composer.unix_socket.UnixHTTPConnectionPool">UnixHTTPConnectionPool (class in composer.unix_socket)</a>
|
||||
</dt>
|
||||
|
||||
|
||||
<dt><a href="pylorax.html#pylorax.yumhelper.LoraxDownloadCallback.updateProgress">updateProgress() (pylorax.yumhelper.LoraxDownloadCallback method)</a>
|
||||
</dt>
|
||||
|
||||
@ -1325,12 +1571,12 @@
|
||||
<dt><a href="pylorax.api.html#pylorax.api.queue.uuid_cancel">uuid_cancel() (in module pylorax.api.queue)</a>
|
||||
</dt>
|
||||
|
||||
</dl></td>
|
||||
<td style="width: 33%" valign="top"><dl>
|
||||
|
||||
<dt><a href="pylorax.api.html#pylorax.api.queue.uuid_delete">uuid_delete() (in module pylorax.api.queue)</a>
|
||||
</dt>
|
||||
|
||||
</dl></td>
|
||||
<td style="width: 33%" valign="top"><dl>
|
||||
|
||||
<dt><a href="pylorax.api.html#pylorax.api.queue.uuid_image">uuid_image() (in module pylorax.api.queue)</a>
|
||||
</dt>
|
||||
@ -1480,11 +1726,11 @@
|
||||
<li class="right" >
|
||||
<a href="py-modindex.html" title="Python Module Index"
|
||||
>modules</a> |</li>
|
||||
<li><a href="index.html">Lorax 19.7.10 documentation</a> »</li>
|
||||
<li><a href="index.html">Lorax 19.7.11 documentation</a> »</li>
|
||||
</ul>
|
||||
</div>
|
||||
<div class="footer">
|
||||
© Copyright 2017, Red Hat, Inc..
|
||||
© Copyright 2018, Red Hat, Inc..
|
||||
Created using <a href="http://sphinx.pocoo.org/">Sphinx</a> 1.1.3.
|
||||
</div>
|
||||
</body>
|
||||
|
@ -8,7 +8,7 @@
|
||||
<head>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
|
||||
|
||||
<title>Welcome to Lorax’s documentation! — Lorax 19.7.10 documentation</title>
|
||||
<title>Welcome to Lorax’s documentation! — Lorax 19.7.11 documentation</title>
|
||||
|
||||
<link rel="stylesheet" href="_static/default.css" type="text/css" />
|
||||
<link rel="stylesheet" href="_static/pygments.css" type="text/css" />
|
||||
@ -16,7 +16,7 @@
|
||||
<script type="text/javascript">
|
||||
var DOCUMENTATION_OPTIONS = {
|
||||
URL_ROOT: '',
|
||||
VERSION: '19.7.10',
|
||||
VERSION: '19.7.11',
|
||||
COLLAPSE_INDEX: false,
|
||||
FILE_SUFFIX: '.html',
|
||||
HAS_SOURCE: true
|
||||
@ -25,7 +25,7 @@
|
||||
<script type="text/javascript" src="_static/jquery.js"></script>
|
||||
<script type="text/javascript" src="_static/underscore.js"></script>
|
||||
<script type="text/javascript" src="_static/doctools.js"></script>
|
||||
<link rel="top" title="Lorax 19.7.10 documentation" href="#" />
|
||||
<link rel="top" title="Lorax 19.7.11 documentation" href="#" />
|
||||
<link rel="next" title="Introduction to Lorax" href="intro.html" />
|
||||
</head>
|
||||
<body>
|
||||
@ -41,7 +41,7 @@
|
||||
<li class="right" >
|
||||
<a href="intro.html" title="Introduction to Lorax"
|
||||
accesskey="N">next</a> |</li>
|
||||
<li><a href="#">Lorax 19.7.10 documentation</a> »</li>
|
||||
<li><a href="#">Lorax 19.7.11 documentation</a> »</li>
|
||||
</ul>
|
||||
</div>
|
||||
|
||||
@ -57,8 +57,11 @@
|
||||
<ul>
|
||||
<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>
|
||||
<li class="toctree-l1"><a class="reference internal" href="lorax-composer.html">lorax-composer</a></li>
|
||||
<li class="toctree-l1"><a class="reference internal" href="modules.html">pylorax</a></li>
|
||||
<li class="toctree-l1"><a class="reference internal" href="product-images.html">Product and Updates Images</a></li>
|
||||
<li class="toctree-l1"><a class="reference internal" href="modules.html">src</a></li>
|
||||
</ul>
|
||||
</div>
|
||||
</div>
|
||||
@ -122,11 +125,11 @@
|
||||
<li class="right" >
|
||||
<a href="intro.html" title="Introduction to Lorax"
|
||||
>next</a> |</li>
|
||||
<li><a href="#">Lorax 19.7.10 documentation</a> »</li>
|
||||
<li><a href="#">Lorax 19.7.11 documentation</a> »</li>
|
||||
</ul>
|
||||
</div>
|
||||
<div class="footer">
|
||||
© Copyright 2017, Red Hat, Inc..
|
||||
© Copyright 2018, Red Hat, Inc..
|
||||
Created using <a href="http://sphinx.pocoo.org/">Sphinx</a> 1.1.3.
|
||||
</div>
|
||||
</body>
|
||||
|
@ -8,7 +8,7 @@
|
||||
<head>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
|
||||
|
||||
<title>Introduction to Lorax — Lorax 19.7.10 documentation</title>
|
||||
<title>Introduction to Lorax — Lorax 19.7.11 documentation</title>
|
||||
|
||||
<link rel="stylesheet" href="_static/default.css" type="text/css" />
|
||||
<link rel="stylesheet" href="_static/pygments.css" type="text/css" />
|
||||
@ -16,7 +16,7 @@
|
||||
<script type="text/javascript">
|
||||
var DOCUMENTATION_OPTIONS = {
|
||||
URL_ROOT: '',
|
||||
VERSION: '19.7.10',
|
||||
VERSION: '19.7.11',
|
||||
COLLAPSE_INDEX: false,
|
||||
FILE_SUFFIX: '.html',
|
||||
HAS_SOURCE: true
|
||||
@ -25,8 +25,8 @@
|
||||
<script type="text/javascript" src="_static/jquery.js"></script>
|
||||
<script type="text/javascript" src="_static/underscore.js"></script>
|
||||
<script type="text/javascript" src="_static/doctools.js"></script>
|
||||
<link rel="top" title="Lorax 19.7.10 documentation" href="index.html" />
|
||||
<link rel="next" title="lorax-composer" href="lorax-composer.html" />
|
||||
<link rel="top" title="Lorax 19.7.11 documentation" href="index.html" />
|
||||
<link rel="next" title="Lorax" href="lorax.html" />
|
||||
<link rel="prev" title="Welcome to Lorax’s documentation!" href="index.html" />
|
||||
</head>
|
||||
<body>
|
||||
@ -40,12 +40,12 @@
|
||||
<a href="py-modindex.html" title="Python Module Index"
|
||||
>modules</a> |</li>
|
||||
<li class="right" >
|
||||
<a href="lorax-composer.html" title="lorax-composer"
|
||||
<a href="lorax.html" title="Lorax"
|
||||
accesskey="N">next</a> |</li>
|
||||
<li class="right" >
|
||||
<a href="index.html" title="Welcome to Lorax’s documentation!"
|
||||
accesskey="P">previous</a> |</li>
|
||||
<li><a href="index.html">Lorax 19.7.10 documentation</a> »</li>
|
||||
<li><a href="index.html">Lorax 19.7.11 documentation</a> »</li>
|
||||
</ul>
|
||||
</div>
|
||||
|
||||
@ -122,8 +122,8 @@ upd-instroot and mk-images* scripts.</p>
|
||||
<p class="topless"><a href="index.html"
|
||||
title="previous chapter">Welcome to Lorax’s documentation!</a></p>
|
||||
<h4>Next topic</h4>
|
||||
<p class="topless"><a href="lorax-composer.html"
|
||||
title="next chapter">lorax-composer</a></p>
|
||||
<p class="topless"><a href="lorax.html"
|
||||
title="next chapter">Lorax</a></p>
|
||||
<h3>This Page</h3>
|
||||
<ul class="this-page-menu">
|
||||
<li><a href="_sources/intro.txt"
|
||||
@ -156,16 +156,16 @@ upd-instroot and mk-images* scripts.</p>
|
||||
<a href="py-modindex.html" title="Python Module Index"
|
||||
>modules</a> |</li>
|
||||
<li class="right" >
|
||||
<a href="lorax-composer.html" title="lorax-composer"
|
||||
<a href="lorax.html" title="Lorax"
|
||||
>next</a> |</li>
|
||||
<li class="right" >
|
||||
<a href="index.html" title="Welcome to Lorax’s documentation!"
|
||||
>previous</a> |</li>
|
||||
<li><a href="index.html">Lorax 19.7.10 documentation</a> »</li>
|
||||
<li><a href="index.html">Lorax 19.7.11 documentation</a> »</li>
|
||||
</ul>
|
||||
</div>
|
||||
<div class="footer">
|
||||
© Copyright 2017, Red Hat, Inc..
|
||||
© Copyright 2018, Red Hat, Inc..
|
||||
Created using <a href="http://sphinx.pocoo.org/">Sphinx</a> 1.1.3.
|
||||
</div>
|
||||
</body>
|
||||
|
457
lorax-composer/livemedia-creator.html
Normal file
457
lorax-composer/livemedia-creator.html
Normal file
@ -0,0 +1,457 @@
|
||||
|
||||
|
||||
<!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>livemedia-creator — Lorax 19.7.11 documentation</title>
|
||||
|
||||
<link rel="stylesheet" href="_static/default.css" type="text/css" />
|
||||
<link rel="stylesheet" href="_static/pygments.css" type="text/css" />
|
||||
|
||||
<script type="text/javascript">
|
||||
var DOCUMENTATION_OPTIONS = {
|
||||
URL_ROOT: '',
|
||||
VERSION: '19.7.11',
|
||||
COLLAPSE_INDEX: false,
|
||||
FILE_SUFFIX: '.html',
|
||||
HAS_SOURCE: true
|
||||
};
|
||||
</script>
|
||||
<script type="text/javascript" src="_static/jquery.js"></script>
|
||||
<script type="text/javascript" src="_static/underscore.js"></script>
|
||||
<script type="text/javascript" src="_static/doctools.js"></script>
|
||||
<link rel="top" title="Lorax 19.7.11 documentation" href="index.html" />
|
||||
<link rel="next" title="lorax-composer" href="lorax-composer.html" />
|
||||
<link rel="prev" title="Lorax" href="lorax.html" />
|
||||
</head>
|
||||
<body>
|
||||
<div class="related">
|
||||
<h3>Navigation</h3>
|
||||
<ul>
|
||||
<li class="right" style="margin-right: 10px">
|
||||
<a href="genindex.html" title="General Index"
|
||||
accesskey="I">index</a></li>
|
||||
<li class="right" >
|
||||
<a href="py-modindex.html" title="Python Module Index"
|
||||
>modules</a> |</li>
|
||||
<li class="right" >
|
||||
<a href="lorax-composer.html" title="lorax-composer"
|
||||
accesskey="N">next</a> |</li>
|
||||
<li class="right" >
|
||||
<a href="lorax.html" title="Lorax"
|
||||
accesskey="P">previous</a> |</li>
|
||||
<li><a href="index.html">Lorax 19.7.11 documentation</a> »</li>
|
||||
</ul>
|
||||
</div>
|
||||
|
||||
<div class="document">
|
||||
<div class="documentwrapper">
|
||||
<div class="bodywrapper">
|
||||
<div class="body">
|
||||
|
||||
<div class="section" id="livemedia-creator">
|
||||
<h1>livemedia-creator<a class="headerlink" href="#livemedia-creator" title="Permalink to this headline">¶</a></h1>
|
||||
<table class="docutils field-list" frame="void" rules="none">
|
||||
<col class="field-name" />
|
||||
<col class="field-body" />
|
||||
<tbody valign="top">
|
||||
<tr class="field-odd field"><th class="field-name">Authors:</th><td class="field-body">Brian C. Lane <<a class="reference external" href="mailto:bcl%40redhat.com">bcl<span>@</span>redhat<span>.</span>com</a>></td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
<p>livemedia-creator uses <a class="reference external" href="https://github.com/rhinstaller/anaconda">Anaconda</a>,
|
||||
<a class="reference external" href="https://github.com/rhinstaller/pykickstart">kickstart</a> and <a class="reference external" href="https://github.com/rhinstaller/lorax">Lorax</a> to create bootable media that use the
|
||||
same install path as a normal system installation. It can be used to make live
|
||||
isos, bootable (partitioned) disk images, tarfiles, and filesystem images for
|
||||
use with virtualization and container solutions like libvirt, docker, and
|
||||
OpenStack.</p>
|
||||
<p>The general idea is to use virt-install with kickstart and an Anaconda boot.iso to
|
||||
install into a disk image and then use the disk image to create the bootable
|
||||
media.</p>
|
||||
<p>livemedia-creator –help will describe all of the options available. At the
|
||||
minimum you need:</p>
|
||||
<p><tt class="docutils literal"><span class="pre">--make-iso</span></tt> to create a final bootable .iso or one of the other <tt class="docutils literal"><span class="pre">--make-*</span></tt> options.</p>
|
||||
<p><tt class="docutils literal"><span class="pre">--iso</span></tt> to specify the Anaconda install media to use with virt-install.</p>
|
||||
<p><tt class="docutils literal"><span class="pre">--ks</span></tt> to select the kickstart file describing what to install.</p>
|
||||
<p>To use livemedia-creator with virtualization you will need to have virt-install installed.</p>
|
||||
<p>If you are going to be using Anaconda directly, with <tt class="docutils literal"><span class="pre">--no-virt</span></tt> mode, make sure
|
||||
you have the anaconda-tui package installed.</p>
|
||||
<p>Conventions used in this document:</p>
|
||||
<p><tt class="docutils literal"><span class="pre">lmc</span></tt> is an abbreviation for livemedia-creator.</p>
|
||||
<p><tt class="docutils literal"><span class="pre">builder</span></tt> is the system where livemedia-creator is being run</p>
|
||||
<p><tt class="docutils literal"><span class="pre">image</span></tt> is the disk image being created by running livemedia-creator</p>
|
||||
<div class="section" id="livemedia-creator-cmdline-arguments">
|
||||
<h2>livemedia-creator cmdline arguments<a class="headerlink" href="#livemedia-creator-cmdline-arguments" title="Permalink to this headline">¶</a></h2>
|
||||
<p>See the output from <tt class="docutils literal"><span class="pre">livemedia-creator</span> <span class="pre">--help</span></tt> for the commandline arguments.</p>
|
||||
</div>
|
||||
<div class="section" id="quickstart">
|
||||
<h2>Quickstart<a class="headerlink" href="#quickstart" title="Permalink to this headline">¶</a></h2>
|
||||
<p>Run this to create a bootable live iso:</p>
|
||||
<div class="highlight-python"><pre>sudo livemedia-creator --make-iso \
|
||||
--iso=/extra/iso/boot.iso --ks=./docs/rhel7-livemedia.ks</pre>
|
||||
</div>
|
||||
<p>You can run it directly from the lorax git repo like this:</p>
|
||||
<div class="highlight-python"><pre>sudo PATH=./src/sbin/:$PATH PYTHONPATH=./src/ ./src/sbin/livemedia-creator \
|
||||
--make-iso --iso=/extra/iso/boot.iso \
|
||||
--ks=./docs/rhel7-livemedia.ks --lorax-templates=./share/</pre>
|
||||
</div>
|
||||
<p>You can observe the installation using vnc. The logs will show what port was
|
||||
chosen, or you can use a specific port by passing it. eg. <tt class="docutils literal"><span class="pre">--vnc</span> <span class="pre">vnc:127.0.0.1:5</span></tt></p>
|
||||
<p>This is usually a good idea when testing changes to the kickstart. lmc tries
|
||||
to monitor the logs for fatal errors, but may not catch everything.</p>
|
||||
</div>
|
||||
<div class="section" id="how-iso-creation-works">
|
||||
<h2>How ISO creation works<a class="headerlink" href="#how-iso-creation-works" title="Permalink to this headline">¶</a></h2>
|
||||
<p>There are 2 stages, the install stage which produces a disk or filesystem image
|
||||
as its output, and the boot media creation which uses the image as its input.
|
||||
Normally you would run both stages, but it is possible to stop after the
|
||||
install stage, by using <tt class="docutils literal"><span class="pre">--image-only</span></tt>, or to skip the install stage and use
|
||||
a previously created disk image by passing <tt class="docutils literal"><span class="pre">--disk-image</span></tt> or <tt class="docutils literal"><span class="pre">--fs-image</span></tt></p>
|
||||
<p>When creating an iso virt-install boots using the passed Anaconda installer iso
|
||||
and installs the system based on the kickstart. The <tt class="docutils literal"><span class="pre">%post</span></tt> section of the
|
||||
kickstart is used to customize the installed system in the same way that
|
||||
current spin-kickstarts do.</p>
|
||||
<p>livemedia-creator monitors the install process for problems by watching the
|
||||
install logs. They are written to the current directory or to the base
|
||||
directory specified by the –logfile command. You can also monitor the install
|
||||
by using a vnc client. This is recommended when first modifying a kickstart,
|
||||
since there are still places where Anaconda may get stuck without the log
|
||||
monitor catching it.</p>
|
||||
<p>The output from this process is a partitioned disk image. kpartx can be used
|
||||
to mount and examine it when there is a problem with the install. It can also
|
||||
be booted using kvm.</p>
|
||||
<p>When creating an iso the disk image’s / partition is copied into a formatted
|
||||
filesystem image which is then used as the input to lorax for creation of the
|
||||
final media.</p>
|
||||
<p>The final image is created by lorax, using the templates in /usr/share/lorax/live/
|
||||
or the live directory below the directory specified by <tt class="docutils literal"><span class="pre">--lorax-templates</span></tt>. The
|
||||
templates are written using the Mako template system with some extra commands
|
||||
added by lorax.</p>
|
||||
</div>
|
||||
<div class="section" id="kickstarts">
|
||||
<h2>Kickstarts<a class="headerlink" href="#kickstarts" title="Permalink to this headline">¶</a></h2>
|
||||
<p>The docs/ directory includes several example kickstarts, one to create a live
|
||||
desktop iso using GNOME, and another to create a minimal disk image. When
|
||||
creating your own kickstarts you should start with the minimal example, it
|
||||
includes several needed packages that are not always included by dependencies.</p>
|
||||
<p>Or you can use existing spin kickstarts to create live media with a few
|
||||
changes. Here are the steps I used to convert the Fedora XFCE spin.</p>
|
||||
<ol class="arabic">
|
||||
<li><p class="first">Flatten the xfce kickstart using ksflatten</p>
|
||||
</li>
|
||||
<li><p class="first">Add zerombr so you don’t get the disk init dialog</p>
|
||||
</li>
|
||||
<li><p class="first">Add clearpart –all</p>
|
||||
</li>
|
||||
<li><p class="first">Add swap partition</p>
|
||||
</li>
|
||||
<li><p class="first">bootloader target</p>
|
||||
</li>
|
||||
<li><p class="first">Add shutdown to the kickstart</p>
|
||||
</li>
|
||||
<li><p class="first">Add network –bootproto=dhcp –activate to activate the network
|
||||
This works for F16 builds but for F15 and before you need to pass
|
||||
something on the cmdline that activate the network, like sshd:</p>
|
||||
<blockquote>
|
||||
<div><p><tt class="docutils literal"><span class="pre">livemedia-creator</span> <span class="pre">--kernel-args="sshd"</span></tt></p>
|
||||
</div></blockquote>
|
||||
</li>
|
||||
<li><p class="first">Add a root password:</p>
|
||||
<div class="highlight-python"><pre>rootpw rootme
|
||||
network --bootproto=dhcp --activate
|
||||
zerombr
|
||||
clearpart --all
|
||||
bootloader --location=mbr
|
||||
part swap --size=512
|
||||
shutdown</pre>
|
||||
</div>
|
||||
</li>
|
||||
<li><p class="first">In the livesys script section of the %post remove the root password. This
|
||||
really depends on how the spin wants to work. You could add the live user
|
||||
that you create to the %wheel group so that sudo works if you wanted to.</p>
|
||||
<blockquote>
|
||||
<div><p><tt class="docutils literal"><span class="pre">passwd</span> <span class="pre">-d</span> <span class="pre">root</span> <span class="pre">></span> <span class="pre">/dev/null</span></tt></p>
|
||||
</div></blockquote>
|
||||
</li>
|
||||
<li><p class="first">Remove /etc/fstab in %post, dracut handles mounting the rootfs</p>
|
||||
<p><tt class="docutils literal"><span class="pre">cat</span> <span class="pre">/dev/null</span> <span class="pre">></span> <span class="pre">/dev/fstab</span></tt></p>
|
||||
<p>Do this only for live iso’s, the filesystem will be mounted read only if
|
||||
there is no /etc/fstab</p>
|
||||
</li>
|
||||
<li><p class="first">Don’t delete initramfs files from /boot in %post</p>
|
||||
</li>
|
||||
<li><p class="first">When creating live iso’s you need to have, at least, these packages in the %package section::
|
||||
dracut-config-generic
|
||||
dracut-live
|
||||
-dracut-config-rescue
|
||||
grub-efi
|
||||
memtest86+
|
||||
syslinux</p>
|
||||
</li>
|
||||
</ol>
|
||||
<p>One drawback to using virt-install is that it pulls the packages from the repo
|
||||
each time you run it. To speed things up you either need a local mirror of the
|
||||
packages, or you can use a caching proxy. When using a proxy you pass it to
|
||||
livemedia-creator like this:</p>
|
||||
<blockquote>
|
||||
<div><tt class="docutils literal"><span class="pre">--proxy=http://proxy.yourdomain.com:3128</span></tt></div></blockquote>
|
||||
<p>You also need to use a specific mirror instead of mirrormanager so that the
|
||||
packages will get cached, so your kickstart url would look like:</p>
|
||||
<blockquote>
|
||||
<div><tt class="docutils literal"><span class="pre">url</span> <span class="pre">--url="http://dl.fedoraproject.org/pub/fedora/linux/development/rawhide/x86_64/os/"</span></tt></div></blockquote>
|
||||
<p>You can also add an update repo, but don’t name it updates. Add –proxy to it
|
||||
as well.</p>
|
||||
</div>
|
||||
<div class="section" id="anaconda-image-install-no-virt">
|
||||
<h2>Anaconda image install (no-virt)<a class="headerlink" href="#anaconda-image-install-no-virt" title="Permalink to this headline">¶</a></h2>
|
||||
<p>You can create images without using virt-install by passing <tt class="docutils literal"><span class="pre">--no-virt</span></tt> on
|
||||
the cmdline. This will use Anaconda’s directory install feature to handle the
|
||||
install. There are a couple of things to keep in mind when doing this:</p>
|
||||
<ol class="arabic simple">
|
||||
<li>It will be most reliable when building images for the same release that the
|
||||
host is running. Because Anaconda has expectations about the system it is
|
||||
running under you may encounter strange bugs if you try to build newer or
|
||||
older releases.</li>
|
||||
<li>Make sure selinux is set to permissive or disabled. It won’t install
|
||||
correctly with selinux set to enforcing yet.</li>
|
||||
<li>It may totally trash your host. So far I haven’t had this happen, but the
|
||||
possibility exists that a bug in Anaconda could result in it operating on
|
||||
real devices. I recommend running it in a virt or on a system that you can
|
||||
afford to lose all data from.</li>
|
||||
</ol>
|
||||
<p>The logs from anaconda will be placed in an ./anaconda/ directory in either
|
||||
the current directory or in the directory used for –logfile</p>
|
||||
<p>Example cmdline:</p>
|
||||
<p><tt class="docutils literal"><span class="pre">sudo</span> <span class="pre">livemedia-creator</span> <span class="pre">--make-iso</span> <span class="pre">--no-virt</span> <span class="pre">--ks=./rhel7-livemedia.ks</span></tt></p>
|
||||
<div class="admonition note">
|
||||
<p class="first admonition-title">Note</p>
|
||||
<p class="last">Using no-virt to create a partitioned disk image (eg. –make-disk or
|
||||
–make-vagrant) will only create disks usable on the host platform (BIOS
|
||||
or UEFI). You can create BIOS partitioned disk images on UEFI by using
|
||||
virt.</p>
|
||||
</div>
|
||||
</div>
|
||||
<div class="section" id="ami-images">
|
||||
<h2>AMI Images<a class="headerlink" href="#ami-images" title="Permalink to this headline">¶</a></h2>
|
||||
<p>Amazon EC2 images can be created by using the –make-ami switch and an appropriate
|
||||
kickstart file. All of the work to customize the image is handled by the kickstart.
|
||||
The example currently included was modified from the cloud-kickstarts version so
|
||||
that it would work with livemedia-creator.</p>
|
||||
<p>Example cmdline:</p>
|
||||
<p><tt class="docutils literal"><span class="pre">sudo</span> <span class="pre">livemedia-creator</span> <span class="pre">--make-ami</span> <span class="pre">--iso=/path/to/boot.iso</span> <span class="pre">--ks=./docs/rhel7-livemedia-ec2.ks</span></tt></p>
|
||||
<p>This will produce an ami-root.img file in the working directory.</p>
|
||||
<p>At this time I have not tested the image with EC2. Feedback would be welcome.</p>
|
||||
</div>
|
||||
<div class="section" id="appliance-creation">
|
||||
<h2>Appliance Creation<a class="headerlink" href="#appliance-creation" title="Permalink to this headline">¶</a></h2>
|
||||
<p>livemedia-creator can now replace appliance-tools by using the –make-appliance
|
||||
switch. This will create the partitioned disk image and an XML file that can be
|
||||
used with virt-image to setup a virtual system.</p>
|
||||
<p>The XML is generated using the Mako template from
|
||||
/usr/share/lorax/appliance/libvirt.xml You can use a different template by
|
||||
passing <tt class="docutils literal"><span class="pre">--app-template</span> <span class="pre"><template</span> <span class="pre">path></span></tt></p>
|
||||
<p>Documentation on the Mako template system can be found at the <a class="reference external" href="http://docs.makotemplates.org/en/latest/index.html">Mako site</a></p>
|
||||
<p>The name of the final output XML is appliance.xml, this can be changed with
|
||||
<tt class="docutils literal"><span class="pre">--app-file</span> <span class="pre"><file</span> <span class="pre">path></span></tt></p>
|
||||
<p>The following variables are passed to the template:</p>
|
||||
<blockquote>
|
||||
<div><dl class="docutils">
|
||||
<dt><tt class="docutils literal"><span class="pre">disks</span></tt></dt>
|
||||
<dd><p class="first">A list of disk_info about each disk.
|
||||
Each entry has the following attributes:</p>
|
||||
<blockquote class="last">
|
||||
<div><p><tt class="docutils literal"><span class="pre">name</span></tt>
|
||||
base name of the disk image file</p>
|
||||
<p><tt class="docutils literal"><span class="pre">format</span></tt>
|
||||
“raw”</p>
|
||||
<p><tt class="docutils literal"><span class="pre">checksum_type</span></tt>
|
||||
“sha256”</p>
|
||||
<p><tt class="docutils literal"><span class="pre">checksum</span></tt>
|
||||
sha256 checksum of the disk image</p>
|
||||
</div></blockquote>
|
||||
</dd>
|
||||
</dl>
|
||||
<p><tt class="docutils literal"><span class="pre">name</span></tt>
|
||||
Name of appliance, from –app-name argument</p>
|
||||
<p><tt class="docutils literal"><span class="pre">arch</span></tt>
|
||||
Architecture</p>
|
||||
<p><tt class="docutils literal"><span class="pre">memory</span></tt>
|
||||
Memory in KB (from <tt class="docutils literal"><span class="pre">--ram</span></tt>)</p>
|
||||
<p><tt class="docutils literal"><span class="pre">vcpus</span></tt>
|
||||
from <tt class="docutils literal"><span class="pre">--vcpus</span></tt></p>
|
||||
<p><tt class="docutils literal"><span class="pre">networks</span></tt>
|
||||
list of networks from the kickstart or []</p>
|
||||
<p><tt class="docutils literal"><span class="pre">title</span></tt>
|
||||
from <tt class="docutils literal"><span class="pre">--title</span></tt></p>
|
||||
<p><tt class="docutils literal"><span class="pre">project</span></tt>
|
||||
from <tt class="docutils literal"><span class="pre">--project</span></tt></p>
|
||||
<p><tt class="docutils literal"><span class="pre">releasever</span></tt>
|
||||
from <tt class="docutils literal"><span class="pre">--releasever</span></tt></p>
|
||||
</div></blockquote>
|
||||
<p>The created image can be imported into libvirt using:</p>
|
||||
<blockquote>
|
||||
<div><tt class="docutils literal"><span class="pre">virt-image</span> <span class="pre">appliance.xml</span></tt></div></blockquote>
|
||||
<p>You can also create qcow2 appliance images using <tt class="docutils literal"><span class="pre">--image-type=qcow2</span></tt>, for example:</p>
|
||||
<div class="highlight-python"><pre>sudo livemedia-creator --make-appliance --iso=/path/to/boot.iso --ks=./docs/rhel7-minimal.ks \
|
||||
--image-type=qcow2 --app-file=minimal-test.xml --image-name=minimal-test.img</pre>
|
||||
</div>
|
||||
</div>
|
||||
<div class="section" id="filesystem-image-creation">
|
||||
<h2>Filesystem Image Creation<a class="headerlink" href="#filesystem-image-creation" title="Permalink to this headline">¶</a></h2>
|
||||
<p>livemedia-creator can be used to create un-partitined filesystem images using
|
||||
the <tt class="docutils literal"><span class="pre">--make-fsimage</span></tt> option. As of version 21.8 this works with both virt and
|
||||
no-virt modes of operation. Previously it was only available with no-virt.</p>
|
||||
<p>Kickstarts should have a single / partition with no extra mountpoints.</p>
|
||||
<blockquote>
|
||||
<div><tt class="docutils literal"><span class="pre">livemedia-creator</span> <span class="pre">--make-fsimage</span> <span class="pre">--iso=/path/to/boot.iso</span> <span class="pre">--ks=./docs/rhel7-minimal.ks</span></tt></div></blockquote>
|
||||
<p>You can name the output image with <tt class="docutils literal"><span class="pre">--image-name</span></tt> and set a label on the filesystem with <tt class="docutils literal"><span class="pre">--fs-label</span></tt></p>
|
||||
</div>
|
||||
<div class="section" id="tar-file-creation">
|
||||
<h2>TAR File Creation<a class="headerlink" href="#tar-file-creation" title="Permalink to this headline">¶</a></h2>
|
||||
<p>The <tt class="docutils literal"><span class="pre">--make-tar</span></tt> command can be used to create a tar of the root filesystem. By
|
||||
default it is compressed using xz, but this can be changed using the
|
||||
<tt class="docutils literal"><span class="pre">--compression</span></tt> and <tt class="docutils literal"><span class="pre">--compress-arg</span></tt> options. This option works with both virt and
|
||||
no-virt install methods.</p>
|
||||
<p>As with <tt class="docutils literal"><span class="pre">--make-fsimage</span></tt> the kickstart should be limited to a single / partition.</p>
|
||||
<p>For example:</p>
|
||||
<div class="highlight-python"><pre>livemedia-creator --make-tar --iso=/path/to/boot.iso --ks=./docs/rhel7-minimal.ks \
|
||||
--image-name=rhel7-root.tar.xz</pre>
|
||||
</div>
|
||||
</div>
|
||||
<div class="section" id="live-image-for-pxe-boot">
|
||||
<h2>Live Image for PXE Boot<a class="headerlink" href="#live-image-for-pxe-boot" title="Permalink to this headline">¶</a></h2>
|
||||
<p>The <tt class="docutils literal"><span class="pre">--make-pxe-live</span></tt> command will produce squashfs image containing live root
|
||||
filesystem that can be used for pxe boot. Directory with results will contain
|
||||
the live image, kernel image, initrd image and template of pxe configuration
|
||||
for the images.</p>
|
||||
</div>
|
||||
<div class="section" id="atomic-live-image-for-pxe-boot">
|
||||
<h2>Atomic Live Image for PXE Boot<a class="headerlink" href="#atomic-live-image-for-pxe-boot" title="Permalink to this headline">¶</a></h2>
|
||||
<p>The <tt class="docutils literal"><span class="pre">--make-ostree-live</span></tt> command will produce the same result as <tt class="docutils literal"><span class="pre">--make-pxe-live</span></tt>
|
||||
for installations of Atomic Host. Example kickstart for such an installation
|
||||
using Atomic installer iso with local repo included in the image can be found
|
||||
in docs/rhel-atomic-pxe-live.ks.</p>
|
||||
<p>The PXE images can also be created with <tt class="docutils literal"><span class="pre">--no-virt</span></tt> by using the example
|
||||
kickstart in docs/rhel-atomic-pxe-live-novirt.ks. This also works inside the
|
||||
mock environment.</p>
|
||||
</div>
|
||||
<div class="section" id="debugging-problems">
|
||||
<h2>Debugging problems<a class="headerlink" href="#debugging-problems" title="Permalink to this headline">¶</a></h2>
|
||||
<p>Sometimes an installation will get stuck. When using virt-install the logs will
|
||||
be written to ./virt-install.log and most of the time any problems that happen
|
||||
will be near the end of the file. lmc tries to detect common errors and will
|
||||
cancel the installation when they happen. But not everything can be caught.
|
||||
When creating a new kickstart it is helpful to use vnc so that you can monitor
|
||||
the installation as it happens, and if it gets stuck without lmc detecting the
|
||||
problem you can switch to tty1 and examine the system directly.</p>
|
||||
<p>If it does get stuck the best way to cancel is to use kill -9 on the virt-install pid,
|
||||
lmc will detect that the process died and cleanup.</p>
|
||||
<p>If lmc didn’t handle the cleanup for some reason you can do this:
|
||||
1. <tt class="docutils literal"><span class="pre">sudo</span> <span class="pre">umount</span> <span class="pre">/tmp/lmc-XXXX</span></tt> to unmount the iso from its mountpoint.
|
||||
2. <tt class="docutils literal"><span class="pre">sudo</span> <span class="pre">rm</span> <span class="pre">-rf</span> <span class="pre">/tmp/lmc-XXXX</span></tt>
|
||||
3. <tt class="docutils literal"><span class="pre">sudo</span> <span class="pre">rm</span> <span class="pre">/var/tmp/lmc-disk-XXXXX</span></tt> to remove the disk image.</p>
|
||||
<p>Note that lmc uses the lmc- prefix for all of its temporary files and
|
||||
directories to make it easier to find and clean up leftovers.</p>
|
||||
<p>The logs from the virt-install run are stored in virt-install.log, logs from
|
||||
livemedia-creator are in livemedia.log and program.log</p>
|
||||
<p>You can add <tt class="docutils literal"><span class="pre">--image-only</span></tt> to skip the .iso creation and examine the resulting
|
||||
disk image. Or you can pass <tt class="docutils literal"><span class="pre">--keep-image</span></tt> to keep it around after the iso has
|
||||
been created.</p>
|
||||
<p>Cleaning up aborted <tt class="docutils literal"><span class="pre">--no-virt</span></tt> installs can sometimes be accomplished by
|
||||
running the <tt class="docutils literal"><span class="pre">anaconda-cleanup</span></tt> script. As of Fedora 18 anaconda is
|
||||
multi-threaded and it can sometimes become stuck and refuse to exit. When this
|
||||
happens you can usually clean up by first killing the anaconda process then
|
||||
running <tt class="docutils literal"><span class="pre">anaconda-cleanup</span></tt>.</p>
|
||||
</div>
|
||||
<div class="section" id="hacking">
|
||||
<h2>Hacking<a class="headerlink" href="#hacking" title="Permalink to this headline">¶</a></h2>
|
||||
<p>Development on this will take place as part of the lorax project, and on the
|
||||
anaconda-devel-list mailing list, and <a class="reference external" href="https://github.com/rhinstaller/lorax">on github</a></p>
|
||||
<p>Feedback, enhancements and bugs are welcome. You can use <a class="reference external" href="https://bugzilla.redhat.com/enter_bug.cgi?product=Fedora&component=lorax">bugzilla</a> to
|
||||
report bugs against the lorax component.</p>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="sphinxsidebar">
|
||||
<div class="sphinxsidebarwrapper">
|
||||
<h3><a href="index.html">Table Of Contents</a></h3>
|
||||
<ul>
|
||||
<li><a class="reference internal" href="#">livemedia-creator</a><ul>
|
||||
<li><a class="reference internal" href="#livemedia-creator-cmdline-arguments">livemedia-creator cmdline arguments</a></li>
|
||||
<li><a class="reference internal" href="#quickstart">Quickstart</a></li>
|
||||
<li><a class="reference internal" href="#how-iso-creation-works">How ISO creation works</a></li>
|
||||
<li><a class="reference internal" href="#kickstarts">Kickstarts</a></li>
|
||||
<li><a class="reference internal" href="#anaconda-image-install-no-virt">Anaconda image install (no-virt)</a></li>
|
||||
<li><a class="reference internal" href="#ami-images">AMI Images</a></li>
|
||||
<li><a class="reference internal" href="#appliance-creation">Appliance Creation</a></li>
|
||||
<li><a class="reference internal" href="#filesystem-image-creation">Filesystem Image Creation</a></li>
|
||||
<li><a class="reference internal" href="#tar-file-creation">TAR File Creation</a></li>
|
||||
<li><a class="reference internal" href="#live-image-for-pxe-boot">Live Image for PXE Boot</a></li>
|
||||
<li><a class="reference internal" href="#atomic-live-image-for-pxe-boot">Atomic Live Image for PXE Boot</a></li>
|
||||
<li><a class="reference internal" href="#debugging-problems">Debugging problems</a></li>
|
||||
<li><a class="reference internal" href="#hacking">Hacking</a></li>
|
||||
</ul>
|
||||
</li>
|
||||
</ul>
|
||||
|
||||
<h4>Previous topic</h4>
|
||||
<p class="topless"><a href="lorax.html"
|
||||
title="previous chapter">Lorax</a></p>
|
||||
<h4>Next topic</h4>
|
||||
<p class="topless"><a href="lorax-composer.html"
|
||||
title="next chapter">lorax-composer</a></p>
|
||||
<h3>This Page</h3>
|
||||
<ul class="this-page-menu">
|
||||
<li><a href="_sources/livemedia-creator.txt"
|
||||
rel="nofollow">Show Source</a></li>
|
||||
</ul>
|
||||
<div id="searchbox" style="display: none">
|
||||
<h3>Quick search</h3>
|
||||
<form class="search" action="search.html" method="get">
|
||||
<input type="text" name="q" />
|
||||
<input type="submit" value="Go" />
|
||||
<input type="hidden" name="check_keywords" value="yes" />
|
||||
<input type="hidden" name="area" value="default" />
|
||||
</form>
|
||||
<p class="searchtip" style="font-size: 90%">
|
||||
Enter search terms or a module, class or function name.
|
||||
</p>
|
||||
</div>
|
||||
<script type="text/javascript">$('#searchbox').show(0);</script>
|
||||
</div>
|
||||
</div>
|
||||
<div class="clearer"></div>
|
||||
</div>
|
||||
<div class="related">
|
||||
<h3>Navigation</h3>
|
||||
<ul>
|
||||
<li class="right" style="margin-right: 10px">
|
||||
<a href="genindex.html" title="General Index"
|
||||
>index</a></li>
|
||||
<li class="right" >
|
||||
<a href="py-modindex.html" title="Python Module Index"
|
||||
>modules</a> |</li>
|
||||
<li class="right" >
|
||||
<a href="lorax-composer.html" title="lorax-composer"
|
||||
>next</a> |</li>
|
||||
<li class="right" >
|
||||
<a href="lorax.html" title="Lorax"
|
||||
>previous</a> |</li>
|
||||
<li><a href="index.html">Lorax 19.7.11 documentation</a> »</li>
|
||||
</ul>
|
||||
</div>
|
||||
<div class="footer">
|
||||
© Copyright 2018, Red Hat, Inc..
|
||||
Created using <a href="http://sphinx.pocoo.org/">Sphinx</a> 1.1.3.
|
||||
</div>
|
||||
</body>
|
||||
</html>
|
@ -8,7 +8,7 @@
|
||||
<head>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
|
||||
|
||||
<title>lorax-composer — Lorax 19.7.10 documentation</title>
|
||||
<title>lorax-composer — Lorax 19.7.11 documentation</title>
|
||||
|
||||
<link rel="stylesheet" href="_static/default.css" type="text/css" />
|
||||
<link rel="stylesheet" href="_static/pygments.css" type="text/css" />
|
||||
@ -16,7 +16,7 @@
|
||||
<script type="text/javascript">
|
||||
var DOCUMENTATION_OPTIONS = {
|
||||
URL_ROOT: '',
|
||||
VERSION: '19.7.10',
|
||||
VERSION: '19.7.11',
|
||||
COLLAPSE_INDEX: false,
|
||||
FILE_SUFFIX: '.html',
|
||||
HAS_SOURCE: true
|
||||
@ -25,9 +25,9 @@
|
||||
<script type="text/javascript" src="_static/jquery.js"></script>
|
||||
<script type="text/javascript" src="_static/underscore.js"></script>
|
||||
<script type="text/javascript" src="_static/doctools.js"></script>
|
||||
<link rel="top" title="Lorax 19.7.10 documentation" href="index.html" />
|
||||
<link rel="next" title="pylorax" href="modules.html" />
|
||||
<link rel="prev" title="Introduction to Lorax" href="intro.html" />
|
||||
<link rel="top" title="Lorax 19.7.11 documentation" href="index.html" />
|
||||
<link rel="next" title="Product and Updates Images" href="product-images.html" />
|
||||
<link rel="prev" title="livemedia-creator" href="livemedia-creator.html" />
|
||||
</head>
|
||||
<body>
|
||||
<div class="related">
|
||||
@ -40,12 +40,12 @@
|
||||
<a href="py-modindex.html" title="Python Module Index"
|
||||
>modules</a> |</li>
|
||||
<li class="right" >
|
||||
<a href="modules.html" title="pylorax"
|
||||
<a href="product-images.html" title="Product and Updates Images"
|
||||
accesskey="N">next</a> |</li>
|
||||
<li class="right" >
|
||||
<a href="intro.html" title="Introduction to Lorax"
|
||||
<a href="livemedia-creator.html" title="livemedia-creator"
|
||||
accesskey="P">previous</a> |</li>
|
||||
<li><a href="index.html">Lorax 19.7.10 documentation</a> »</li>
|
||||
<li><a href="index.html">Lorax 19.7.11 documentation</a> »</li>
|
||||
</ul>
|
||||
</div>
|
||||
|
||||
@ -173,11 +173,11 @@ the contents of the iso as well as the boot.iso itself.</p>
|
||||
</ul>
|
||||
|
||||
<h4>Previous topic</h4>
|
||||
<p class="topless"><a href="intro.html"
|
||||
title="previous chapter">Introduction to Lorax</a></p>
|
||||
<p class="topless"><a href="livemedia-creator.html"
|
||||
title="previous chapter">livemedia-creator</a></p>
|
||||
<h4>Next topic</h4>
|
||||
<p class="topless"><a href="modules.html"
|
||||
title="next chapter">pylorax</a></p>
|
||||
<p class="topless"><a href="product-images.html"
|
||||
title="next chapter">Product and Updates Images</a></p>
|
||||
<h3>This Page</h3>
|
||||
<ul class="this-page-menu">
|
||||
<li><a href="_sources/lorax-composer.txt"
|
||||
@ -210,16 +210,16 @@ the contents of the iso as well as the boot.iso itself.</p>
|
||||
<a href="py-modindex.html" title="Python Module Index"
|
||||
>modules</a> |</li>
|
||||
<li class="right" >
|
||||
<a href="modules.html" title="pylorax"
|
||||
<a href="product-images.html" title="Product and Updates Images"
|
||||
>next</a> |</li>
|
||||
<li class="right" >
|
||||
<a href="intro.html" title="Introduction to Lorax"
|
||||
<a href="livemedia-creator.html" title="livemedia-creator"
|
||||
>previous</a> |</li>
|
||||
<li><a href="index.html">Lorax 19.7.10 documentation</a> »</li>
|
||||
<li><a href="index.html">Lorax 19.7.11 documentation</a> »</li>
|
||||
</ul>
|
||||
</div>
|
||||
<div class="footer">
|
||||
© Copyright 2017, Red Hat, Inc..
|
||||
© Copyright 2018, Red Hat, Inc..
|
||||
Created using <a href="http://sphinx.pocoo.org/">Sphinx</a> 1.1.3.
|
||||
</div>
|
||||
</body>
|
||||
|
265
lorax-composer/lorax.html
Normal file
265
lorax-composer/lorax.html
Normal file
@ -0,0 +1,265 @@
|
||||
|
||||
|
||||
<!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>Lorax — Lorax 19.7.11 documentation</title>
|
||||
|
||||
<link rel="stylesheet" href="_static/default.css" type="text/css" />
|
||||
<link rel="stylesheet" href="_static/pygments.css" type="text/css" />
|
||||
|
||||
<script type="text/javascript">
|
||||
var DOCUMENTATION_OPTIONS = {
|
||||
URL_ROOT: '',
|
||||
VERSION: '19.7.11',
|
||||
COLLAPSE_INDEX: false,
|
||||
FILE_SUFFIX: '.html',
|
||||
HAS_SOURCE: true
|
||||
};
|
||||
</script>
|
||||
<script type="text/javascript" src="_static/jquery.js"></script>
|
||||
<script type="text/javascript" src="_static/underscore.js"></script>
|
||||
<script type="text/javascript" src="_static/doctools.js"></script>
|
||||
<link rel="top" title="Lorax 19.7.11 documentation" href="index.html" />
|
||||
<link rel="next" title="livemedia-creator" href="livemedia-creator.html" />
|
||||
<link rel="prev" title="Introduction to Lorax" href="intro.html" />
|
||||
</head>
|
||||
<body>
|
||||
<div class="related">
|
||||
<h3>Navigation</h3>
|
||||
<ul>
|
||||
<li class="right" style="margin-right: 10px">
|
||||
<a href="genindex.html" title="General Index"
|
||||
accesskey="I">index</a></li>
|
||||
<li class="right" >
|
||||
<a href="py-modindex.html" title="Python Module Index"
|
||||
>modules</a> |</li>
|
||||
<li class="right" >
|
||||
<a href="livemedia-creator.html" title="livemedia-creator"
|
||||
accesskey="N">next</a> |</li>
|
||||
<li class="right" >
|
||||
<a href="intro.html" title="Introduction to Lorax"
|
||||
accesskey="P">previous</a> |</li>
|
||||
<li><a href="index.html">Lorax 19.7.11 documentation</a> »</li>
|
||||
</ul>
|
||||
</div>
|
||||
|
||||
<div class="document">
|
||||
<div class="documentwrapper">
|
||||
<div class="bodywrapper">
|
||||
<div class="body">
|
||||
|
||||
<div class="section" id="lorax">
|
||||
<h1>Lorax<a class="headerlink" href="#lorax" title="Permalink to this headline">¶</a></h1>
|
||||
<table class="docutils field-list" frame="void" rules="none">
|
||||
<col class="field-name" />
|
||||
<col class="field-body" />
|
||||
<tbody valign="top">
|
||||
<tr class="field-odd field"><th class="field-name">Authors:</th><td class="field-body">Brian C. Lane <<a class="reference external" href="mailto:bcl%40redhat.com">bcl<span>@</span>redhat<span>.</span>com</a>></td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
<p>“I am the Lorax. I speak for the trees [and images].”</p>
|
||||
<p>The <a class="reference external" href="https://github.com/rhinstaller/lorax">lorax</a> tool is used to create the
|
||||
<a class="reference external" href="https://github.com/rhinstaller/anaconda">Anaconda</a> installer boot.iso as
|
||||
well as the basic release tree, and .treeinfo metadata file. Its dependencies
|
||||
are fairly light-weight because it needs to be able to run in a mock chroot
|
||||
environment. It is best to run lorax from the same release as is being targeted
|
||||
because the templates may have release specific logic in them. eg. Use the
|
||||
rawhide version to build the boot.iso for rawhide, along with the rawhide
|
||||
repositories.</p>
|
||||
<div class="section" id="lorax-cmdline-arguments">
|
||||
<h2>lorax cmdline arguments<a class="headerlink" href="#lorax-cmdline-arguments" title="Permalink to this headline">¶</a></h2>
|
||||
<p>See the output from <tt class="docutils literal"><span class="pre">lorax</span> <span class="pre">--help</span></tt> for the commandline arguments.</p>
|
||||
</div>
|
||||
<div class="section" id="quickstart">
|
||||
<h2>Quickstart<a class="headerlink" href="#quickstart" title="Permalink to this headline">¶</a></h2>
|
||||
<p>Run this as root to create a boot.iso in <tt class="docutils literal"><span class="pre">./results/</span></tt>:</p>
|
||||
<div class="highlight-python"><pre>yum install lorax
|
||||
setenforce 0
|
||||
lorax -p RHEL -v 7 -r 7 \
|
||||
-s http://mirror.centos.org/centos-7/7/os/x86_64/ \
|
||||
-s http://mirror.centos.org/centos-7/7/updates/x86_64/ \
|
||||
./results/
|
||||
setenforce 1</pre>
|
||||
</div>
|
||||
<p>You can add your own repos with <tt class="docutils literal"><span class="pre">-s</span></tt> and packages with higher NVRs will
|
||||
override the ones in the distribution repositories.</p>
|
||||
<p>Under <tt class="docutils literal"><span class="pre">./results/</span></tt> will be the release tree files: .discinfo, .treeinfo, everything that
|
||||
goes onto the boot.iso, the pxeboot directory, and the boot.iso under <tt class="docutils literal"><span class="pre">./images/</span></tt>.</p>
|
||||
</div>
|
||||
<div class="section" id="running-inside-of-mock">
|
||||
<h2>Running inside of mock<a class="headerlink" href="#running-inside-of-mock" title="Permalink to this headline">¶</a></h2>
|
||||
<p>If you are using lorax with mock v1.3.4 or later you will need to pass
|
||||
<tt class="docutils literal"><span class="pre">--old-chroot</span></tt> to mock. Mock now defaults to using systemd-nspawn which cannot
|
||||
create the needed loop device nodes. Passing <tt class="docutils literal"><span class="pre">--old-chroot</span></tt> will use the old
|
||||
system where <tt class="docutils literal"><span class="pre">/dev/loop*</span></tt> is setup for you.</p>
|
||||
</div>
|
||||
<div class="section" id="how-it-works">
|
||||
<h2>How it works<a class="headerlink" href="#how-it-works" title="Permalink to this headline">¶</a></h2>
|
||||
<p>Lorax uses <a class="reference external" href="https://github.com/rpm-software-management/yum">yum</a> to install
|
||||
packages into a temporary directory, sets up configuration files, it then
|
||||
removes unneeded files to save space, and creates a squashfs filesystem of the
|
||||
files. The iso is then built using a generic initramfs and the kernel from the
|
||||
selected repositories.</p>
|
||||
<p>To drive these processes Lorax uses a custom template system, based on <a class="reference external" href="http://www.makotemplates.org/">Mako
|
||||
templates</a> with the addition of custom
|
||||
commands (documented in <a class="reference internal" href="pylorax.html#pylorax.ltmpl.LoraxTemplateRunner" title="pylorax.ltmpl.LoraxTemplateRunner"><tt class="xref py py-class docutils literal"><span class="pre">pylorax.ltmpl.LoraxTemplateRunner</span></tt></a>). Mako
|
||||
supports <tt class="docutils literal"><span class="pre">%if/%endif</span></tt> blocks as well as free-form python code inside <tt class="docutils literal"><span class="pre"><%</span>
|
||||
<span class="pre">%></span></tt> tags and variable substitution with <tt class="docutils literal"><span class="pre">${}</span></tt>. The default templates are
|
||||
shipped with lorax in <tt class="docutils literal"><span class="pre">/usr/share/lorax/</span></tt> and use the
|
||||
<tt class="docutils literal"><span class="pre">.tmpl</span></tt> extension.</p>
|
||||
<div class="section" id="runtime-install-tmpl">
|
||||
<h3>runtime-install.tmpl<a class="headerlink" href="#runtime-install-tmpl" title="Permalink to this headline">¶</a></h3>
|
||||
<p>The <tt class="docutils literal"><span class="pre">runtime-install.tmpl</span></tt> template lists packages to be installed using the
|
||||
<tt class="docutils literal"><span class="pre">installpkg</span></tt> command. This template is fairly simple, installing common packages and
|
||||
architecture specific packages. It must end with the <tt class="docutils literal"><span class="pre">run_pkg_transaction</span></tt>
|
||||
command which tells dnf to download and install the packages.</p>
|
||||
</div>
|
||||
<div class="section" id="runtime-postinstall-tmpl">
|
||||
<h3>runtime-postinstall.tmpl<a class="headerlink" href="#runtime-postinstall-tmpl" title="Permalink to this headline">¶</a></h3>
|
||||
<p>The <tt class="docutils literal"><span class="pre">runtime-postinstall.tmpl</span></tt> template is where the system configuration
|
||||
happens. The installer environment is similar to a normal running system, but
|
||||
needs some special handling. Configuration files are setup, systemd is told to
|
||||
start the anaconda.target instead of a default system target, and a number of
|
||||
unneeded services are disabled, some of which can interfere with the
|
||||
installation. A number of template commands are used here:</p>
|
||||
<ul class="simple">
|
||||
<li><a class="reference internal" href="pylorax.html#pylorax.ltmpl.LoraxTemplateRunner.append" title="pylorax.ltmpl.LoraxTemplateRunner.append"><tt class="xref py py-func docutils literal"><span class="pre">append</span></tt></a> to add text to a file.</li>
|
||||
<li><a class="reference internal" href="pylorax.html#pylorax.ltmpl.LoraxTemplateRunner.chmod" title="pylorax.ltmpl.LoraxTemplateRunner.chmod"><tt class="xref py py-func docutils literal"><span class="pre">chmod</span></tt></a> changes the file’s mode.</li>
|
||||
<li><a class="reference internal" href="pylorax.html#pylorax.ltmpl.LoraxTemplateRunner.gconfset" title="pylorax.ltmpl.LoraxTemplateRunner.gconfset"><tt class="xref py py-func docutils literal"><span class="pre">gconfset</span></tt></a> runs gconfset.</li>
|
||||
<li><a class="reference internal" href="pylorax.html#pylorax.ltmpl.LoraxTemplateRunner.install" title="pylorax.ltmpl.LoraxTemplateRunner.install"><tt class="xref py py-func docutils literal"><span class="pre">install</span></tt></a> to install a file into the installroot.</li>
|
||||
<li><a class="reference internal" href="pylorax.html#pylorax.ltmpl.LoraxTemplateRunner.mkdir" title="pylorax.ltmpl.LoraxTemplateRunner.mkdir"><tt class="xref py py-func docutils literal"><span class="pre">mkdir</span></tt></a> makes a new directory.</li>
|
||||
<li><a class="reference internal" href="pylorax.html#pylorax.ltmpl.LoraxTemplateRunner.move" title="pylorax.ltmpl.LoraxTemplateRunner.move"><tt class="xref py py-func docutils literal"><span class="pre">move</span></tt></a> to move a file into the installroot</li>
|
||||
<li><a class="reference internal" href="pylorax.html#pylorax.ltmpl.LoraxTemplateRunner.replace" title="pylorax.ltmpl.LoraxTemplateRunner.replace"><tt class="xref py py-func docutils literal"><span class="pre">replace</span></tt></a> does text substitution in a file</li>
|
||||
<li><a class="reference internal" href="pylorax.html#pylorax.ltmpl.LoraxTemplateRunner.remove" title="pylorax.ltmpl.LoraxTemplateRunner.remove"><tt class="xref py py-func docutils literal"><span class="pre">remove</span></tt></a> deletes a file</li>
|
||||
<li><a class="reference internal" href="pylorax.html#pylorax.ltmpl.LoraxTemplateRunner.runcmd" title="pylorax.ltmpl.LoraxTemplateRunner.runcmd"><tt class="xref py py-func docutils literal"><span class="pre">runcmd</span></tt></a> run arbitrary commands.</li>
|
||||
<li><a class="reference internal" href="pylorax.html#pylorax.ltmpl.LoraxTemplateRunner.symlink" title="pylorax.ltmpl.LoraxTemplateRunner.symlink"><tt class="xref py py-func docutils literal"><span class="pre">symlink</span></tt></a> creates a symlink</li>
|
||||
<li><a class="reference internal" href="pylorax.html#pylorax.ltmpl.LoraxTemplateRunner.systemctl" title="pylorax.ltmpl.LoraxTemplateRunner.systemctl"><tt class="xref py py-func docutils literal"><span class="pre">systemctl</span></tt></a> runs systemctl in the installroot</li>
|
||||
</ul>
|
||||
</div>
|
||||
<div class="section" id="runtime-cleanup-tmpl">
|
||||
<h3>runtime-cleanup.tmpl<a class="headerlink" href="#runtime-cleanup-tmpl" title="Permalink to this headline">¶</a></h3>
|
||||
<p>The <tt class="docutils literal"><span class="pre">runtime-cleanup.tmpl</span></tt> template is used to remove files that aren’t strictly needed
|
||||
by the installation environment. In addition to the <tt class="docutils literal"><span class="pre">remove</span></tt> template command it uses:</p>
|
||||
<ul class="simple">
|
||||
<li><a class="reference internal" href="pylorax.html#pylorax.ltmpl.LoraxTemplateRunner.removepkg" title="pylorax.ltmpl.LoraxTemplateRunner.removepkg"><tt class="xref py py-func docutils literal"><span class="pre">removepkg</span></tt></a>
|
||||
remove all of a specific package’s contents. A package may be pulled in as a dependency, but
|
||||
not really used. eg. sound support.</li>
|
||||
<li><a class="reference internal" href="pylorax.html#pylorax.ltmpl.LoraxTemplateRunner.removefrom" title="pylorax.ltmpl.LoraxTemplateRunner.removefrom"><tt class="xref py py-func docutils literal"><span class="pre">removefrom</span></tt></a>
|
||||
Removes some files from a package. A file glob can be used, or the –allbut option to
|
||||
remove everything except a select few.</li>
|
||||
<li><a class="reference internal" href="pylorax.html#pylorax.ltmpl.LoraxTemplateRunner.removekmod" title="pylorax.ltmpl.LoraxTemplateRunner.removekmod"><tt class="xref py py-func docutils literal"><span class="pre">removekmod</span></tt></a>
|
||||
Removes kernel modules</li>
|
||||
</ul>
|
||||
</div>
|
||||
<div class="section" id="the-squashfs-filesystem">
|
||||
<h3>The squashfs filesystem<a class="headerlink" href="#the-squashfs-filesystem" title="Permalink to this headline">¶</a></h3>
|
||||
<p>After <tt class="docutils literal"><span class="pre">runtime-*.tmpl</span></tt> templates have finished their work lorax creates an
|
||||
empty ext4 filesystem, copies the remaining files to it, and makes a squashfs
|
||||
filesystem of it. This file is the / of the boot.iso’s installer environment
|
||||
and is what is in the LiveOS/squashfs.img file on the iso.</p>
|
||||
</div>
|
||||
<div class="section" id="iso-creation">
|
||||
<h3>iso creation<a class="headerlink" href="#iso-creation" title="Permalink to this headline">¶</a></h3>
|
||||
<p>The iso creation is handled by another set of templates. The one used depends
|
||||
on the architecture that the iso is being created for. They are also stored in
|
||||
<tt class="docutils literal"><span class="pre">/usr/share/lorax/</span></tt> and are named after the arch, like
|
||||
<tt class="docutils literal"><span class="pre">x86.tmpl</span></tt> and <tt class="docutils literal"><span class="pre">aarch64.tmpl</span></tt>. They handle creation of the tree, copying
|
||||
configuration template files, configuration variable substitution, treeinfo
|
||||
metadata (via the <a class="reference internal" href="pylorax.html#pylorax.ltmpl.LoraxTemplateRunner.treeinfo" title="pylorax.ltmpl.LoraxTemplateRunner.treeinfo"><tt class="xref py py-func docutils literal"><span class="pre">treeinfo</span></tt></a>
|
||||
template command). Kernel and initrd are copied from the installroot to their
|
||||
final locations and then mkisofs is run to create the boot.iso</p>
|
||||
</div>
|
||||
</div>
|
||||
<div class="section" id="custom-templates">
|
||||
<h2>Custom Templates<a class="headerlink" href="#custom-templates" title="Permalink to this headline">¶</a></h2>
|
||||
<p>The default set of templates and configuration files are shipped in the
|
||||
<tt class="docutils literal"><span class="pre">/usr/share/lorax/</span></tt> directory. You can make a copy of them and place them
|
||||
into another directory and then select the new template directory by passing
|
||||
<tt class="docutils literal"><span class="pre">--sharedir</span></tt> to lorax.</p>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="sphinxsidebar">
|
||||
<div class="sphinxsidebarwrapper">
|
||||
<h3><a href="index.html">Table Of Contents</a></h3>
|
||||
<ul>
|
||||
<li><a class="reference internal" href="#">Lorax</a><ul>
|
||||
<li><a class="reference internal" href="#lorax-cmdline-arguments">lorax cmdline arguments</a></li>
|
||||
<li><a class="reference internal" href="#quickstart">Quickstart</a></li>
|
||||
<li><a class="reference internal" href="#running-inside-of-mock">Running inside of mock</a></li>
|
||||
<li><a class="reference internal" href="#how-it-works">How it works</a><ul>
|
||||
<li><a class="reference internal" href="#runtime-install-tmpl">runtime-install.tmpl</a></li>
|
||||
<li><a class="reference internal" href="#runtime-postinstall-tmpl">runtime-postinstall.tmpl</a></li>
|
||||
<li><a class="reference internal" href="#runtime-cleanup-tmpl">runtime-cleanup.tmpl</a></li>
|
||||
<li><a class="reference internal" href="#the-squashfs-filesystem">The squashfs filesystem</a></li>
|
||||
<li><a class="reference internal" href="#iso-creation">iso creation</a></li>
|
||||
</ul>
|
||||
</li>
|
||||
<li><a class="reference internal" href="#custom-templates">Custom Templates</a></li>
|
||||
</ul>
|
||||
</li>
|
||||
</ul>
|
||||
|
||||
<h4>Previous topic</h4>
|
||||
<p class="topless"><a href="intro.html"
|
||||
title="previous chapter">Introduction to Lorax</a></p>
|
||||
<h4>Next topic</h4>
|
||||
<p class="topless"><a href="livemedia-creator.html"
|
||||
title="next chapter">livemedia-creator</a></p>
|
||||
<h3>This Page</h3>
|
||||
<ul class="this-page-menu">
|
||||
<li><a href="_sources/lorax.txt"
|
||||
rel="nofollow">Show Source</a></li>
|
||||
</ul>
|
||||
<div id="searchbox" style="display: none">
|
||||
<h3>Quick search</h3>
|
||||
<form class="search" action="search.html" method="get">
|
||||
<input type="text" name="q" />
|
||||
<input type="submit" value="Go" />
|
||||
<input type="hidden" name="check_keywords" value="yes" />
|
||||
<input type="hidden" name="area" value="default" />
|
||||
</form>
|
||||
<p class="searchtip" style="font-size: 90%">
|
||||
Enter search terms or a module, class or function name.
|
||||
</p>
|
||||
</div>
|
||||
<script type="text/javascript">$('#searchbox').show(0);</script>
|
||||
</div>
|
||||
</div>
|
||||
<div class="clearer"></div>
|
||||
</div>
|
||||
<div class="related">
|
||||
<h3>Navigation</h3>
|
||||
<ul>
|
||||
<li class="right" style="margin-right: 10px">
|
||||
<a href="genindex.html" title="General Index"
|
||||
>index</a></li>
|
||||
<li class="right" >
|
||||
<a href="py-modindex.html" title="Python Module Index"
|
||||
>modules</a> |</li>
|
||||
<li class="right" >
|
||||
<a href="livemedia-creator.html" title="livemedia-creator"
|
||||
>next</a> |</li>
|
||||
<li class="right" >
|
||||
<a href="intro.html" title="Introduction to Lorax"
|
||||
>previous</a> |</li>
|
||||
<li><a href="index.html">Lorax 19.7.11 documentation</a> »</li>
|
||||
</ul>
|
||||
</div>
|
||||
<div class="footer">
|
||||
© Copyright 2018, Red Hat, Inc..
|
||||
Created using <a href="http://sphinx.pocoo.org/">Sphinx</a> 1.1.3.
|
||||
</div>
|
||||
</body>
|
||||
</html>
|
@ -8,7 +8,7 @@
|
||||
<head>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
|
||||
|
||||
<title>pylorax — Lorax 19.7.10 documentation</title>
|
||||
<title>src — Lorax 19.7.11 documentation</title>
|
||||
|
||||
<link rel="stylesheet" href="_static/default.css" type="text/css" />
|
||||
<link rel="stylesheet" href="_static/pygments.css" type="text/css" />
|
||||
@ -16,7 +16,7 @@
|
||||
<script type="text/javascript">
|
||||
var DOCUMENTATION_OPTIONS = {
|
||||
URL_ROOT: '',
|
||||
VERSION: '19.7.10',
|
||||
VERSION: '19.7.11',
|
||||
COLLAPSE_INDEX: false,
|
||||
FILE_SUFFIX: '.html',
|
||||
HAS_SOURCE: true
|
||||
@ -25,9 +25,9 @@
|
||||
<script type="text/javascript" src="_static/jquery.js"></script>
|
||||
<script type="text/javascript" src="_static/underscore.js"></script>
|
||||
<script type="text/javascript" src="_static/doctools.js"></script>
|
||||
<link rel="top" title="Lorax 19.7.10 documentation" href="index.html" />
|
||||
<link rel="next" title="pylorax Package" href="pylorax.html" />
|
||||
<link rel="prev" title="lorax-composer" href="lorax-composer.html" />
|
||||
<link rel="top" title="Lorax 19.7.11 documentation" href="index.html" />
|
||||
<link rel="next" title="composer Package" href="composer.html" />
|
||||
<link rel="prev" title="Product and Updates Images" href="product-images.html" />
|
||||
</head>
|
||||
<body>
|
||||
<div class="related">
|
||||
@ -40,12 +40,12 @@
|
||||
<a href="py-modindex.html" title="Python Module Index"
|
||||
>modules</a> |</li>
|
||||
<li class="right" >
|
||||
<a href="pylorax.html" title="pylorax Package"
|
||||
<a href="composer.html" title="composer Package"
|
||||
accesskey="N">next</a> |</li>
|
||||
<li class="right" >
|
||||
<a href="lorax-composer.html" title="lorax-composer"
|
||||
<a href="product-images.html" title="Product and Updates Images"
|
||||
accesskey="P">previous</a> |</li>
|
||||
<li><a href="index.html">Lorax 19.7.10 documentation</a> »</li>
|
||||
<li><a href="index.html">Lorax 19.7.11 documentation</a> »</li>
|
||||
</ul>
|
||||
</div>
|
||||
|
||||
@ -54,10 +54,28 @@
|
||||
<div class="bodywrapper">
|
||||
<div class="body">
|
||||
|
||||
<div class="section" id="pylorax">
|
||||
<h1>pylorax<a class="headerlink" href="#pylorax" title="Permalink to this headline">¶</a></h1>
|
||||
<div class="section" id="src">
|
||||
<h1>src<a class="headerlink" href="#src" title="Permalink to this headline">¶</a></h1>
|
||||
<div class="toctree-wrapper compound">
|
||||
<ul>
|
||||
<li class="toctree-l1"><a class="reference internal" href="composer.html">composer Package</a><ul>
|
||||
<li class="toctree-l2"><a class="reference internal" href="composer.html#id1"><tt class="docutils literal"><span class="pre">composer</span></tt> Package</a></li>
|
||||
<li class="toctree-l2"><a class="reference internal" href="composer.html#module-composer.http_client"><tt class="docutils literal"><span class="pre">http_client</span></tt> Module</a></li>
|
||||
<li class="toctree-l2"><a class="reference internal" href="composer.html#module-composer.unix_socket"><tt class="docutils literal"><span class="pre">unix_socket</span></tt> Module</a></li>
|
||||
<li class="toctree-l2"><a class="reference internal" href="composer.html#subpackages">Subpackages</a><ul>
|
||||
<li class="toctree-l3"><a class="reference internal" href="composer.cli.html">cli Package</a><ul>
|
||||
<li class="toctree-l4"><a class="reference internal" href="composer.cli.html#id1"><tt class="docutils literal"><span class="pre">cli</span></tt> Package</a></li>
|
||||
<li class="toctree-l4"><a class="reference internal" href="composer.cli.html#module-composer.cli.compose"><tt class="docutils literal"><span class="pre">compose</span></tt> Module</a></li>
|
||||
<li class="toctree-l4"><a class="reference internal" href="composer.cli.html#module-composer.cli.modules"><tt class="docutils literal"><span class="pre">modules</span></tt> Module</a></li>
|
||||
<li class="toctree-l4"><a class="reference internal" href="composer.cli.html#module-composer.cli.projects"><tt class="docutils literal"><span class="pre">projects</span></tt> Module</a></li>
|
||||
<li class="toctree-l4"><a class="reference internal" href="composer.cli.html#module-composer.cli.recipes"><tt class="docutils literal"><span class="pre">recipes</span></tt> Module</a></li>
|
||||
<li class="toctree-l4"><a class="reference internal" href="composer.cli.html#module-composer.cli.utilities"><tt class="docutils literal"><span class="pre">utilities</span></tt> Module</a></li>
|
||||
</ul>
|
||||
</li>
|
||||
</ul>
|
||||
</li>
|
||||
</ul>
|
||||
</li>
|
||||
<li class="toctree-l1"><a class="reference internal" href="pylorax.html">pylorax Package</a><ul>
|
||||
<li class="toctree-l2"><a class="reference internal" href="pylorax.html#id1"><tt class="docutils literal"><span class="pre">pylorax</span></tt> Package</a></li>
|
||||
<li class="toctree-l2"><a class="reference internal" href="pylorax.html#module-pylorax.base"><tt class="docutils literal"><span class="pre">base</span></tt> Module</a></li>
|
||||
@ -105,11 +123,11 @@
|
||||
<div class="sphinxsidebar">
|
||||
<div class="sphinxsidebarwrapper">
|
||||
<h4>Previous topic</h4>
|
||||
<p class="topless"><a href="lorax-composer.html"
|
||||
title="previous chapter">lorax-composer</a></p>
|
||||
<p class="topless"><a href="product-images.html"
|
||||
title="previous chapter">Product and Updates Images</a></p>
|
||||
<h4>Next topic</h4>
|
||||
<p class="topless"><a href="pylorax.html"
|
||||
title="next chapter">pylorax Package</a></p>
|
||||
<p class="topless"><a href="composer.html"
|
||||
title="next chapter">composer Package</a></p>
|
||||
<h3>This Page</h3>
|
||||
<ul class="this-page-menu">
|
||||
<li><a href="_sources/modules.txt"
|
||||
@ -142,16 +160,16 @@
|
||||
<a href="py-modindex.html" title="Python Module Index"
|
||||
>modules</a> |</li>
|
||||
<li class="right" >
|
||||
<a href="pylorax.html" title="pylorax Package"
|
||||
<a href="composer.html" title="composer Package"
|
||||
>next</a> |</li>
|
||||
<li class="right" >
|
||||
<a href="lorax-composer.html" title="lorax-composer"
|
||||
<a href="product-images.html" title="Product and Updates Images"
|
||||
>previous</a> |</li>
|
||||
<li><a href="index.html">Lorax 19.7.10 documentation</a> »</li>
|
||||
<li><a href="index.html">Lorax 19.7.11 documentation</a> »</li>
|
||||
</ul>
|
||||
</div>
|
||||
<div class="footer">
|
||||
© Copyright 2017, Red Hat, Inc..
|
||||
© Copyright 2018, Red Hat, Inc..
|
||||
Created using <a href="http://sphinx.pocoo.org/">Sphinx</a> 1.1.3.
|
||||
</div>
|
||||
</body>
|
||||
|
Binary file not shown.
138
lorax-composer/product-images.html
Normal file
138
lorax-composer/product-images.html
Normal file
@ -0,0 +1,138 @@
|
||||
|
||||
|
||||
<!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>Product and Updates Images — Lorax 19.7.11 documentation</title>
|
||||
|
||||
<link rel="stylesheet" href="_static/default.css" type="text/css" />
|
||||
<link rel="stylesheet" href="_static/pygments.css" type="text/css" />
|
||||
|
||||
<script type="text/javascript">
|
||||
var DOCUMENTATION_OPTIONS = {
|
||||
URL_ROOT: '',
|
||||
VERSION: '19.7.11',
|
||||
COLLAPSE_INDEX: false,
|
||||
FILE_SUFFIX: '.html',
|
||||
HAS_SOURCE: true
|
||||
};
|
||||
</script>
|
||||
<script type="text/javascript" src="_static/jquery.js"></script>
|
||||
<script type="text/javascript" src="_static/underscore.js"></script>
|
||||
<script type="text/javascript" src="_static/doctools.js"></script>
|
||||
<link rel="top" title="Lorax 19.7.11 documentation" href="index.html" />
|
||||
<link rel="next" title="src" href="modules.html" />
|
||||
<link rel="prev" title="lorax-composer" href="lorax-composer.html" />
|
||||
</head>
|
||||
<body>
|
||||
<div class="related">
|
||||
<h3>Navigation</h3>
|
||||
<ul>
|
||||
<li class="right" style="margin-right: 10px">
|
||||
<a href="genindex.html" title="General Index"
|
||||
accesskey="I">index</a></li>
|
||||
<li class="right" >
|
||||
<a href="py-modindex.html" title="Python Module Index"
|
||||
>modules</a> |</li>
|
||||
<li class="right" >
|
||||
<a href="modules.html" title="src"
|
||||
accesskey="N">next</a> |</li>
|
||||
<li class="right" >
|
||||
<a href="lorax-composer.html" title="lorax-composer"
|
||||
accesskey="P">previous</a> |</li>
|
||||
<li><a href="index.html">Lorax 19.7.11 documentation</a> »</li>
|
||||
</ul>
|
||||
</div>
|
||||
|
||||
<div class="document">
|
||||
<div class="documentwrapper">
|
||||
<div class="bodywrapper">
|
||||
<div class="body">
|
||||
|
||||
<div class="section" id="product-and-updates-images">
|
||||
<h1>Product and Updates Images<a class="headerlink" href="#product-and-updates-images" title="Permalink to this headline">¶</a></h1>
|
||||
<p>Lorax now supports creation of product.img and updates.img as part of the build
|
||||
process. This is implemented using the installimg template command which will
|
||||
take the contents of a directory and create a compressed archive from it. The
|
||||
directory must be created by one of the packages installed by
|
||||
runtime-install.tmpl or by passing <tt class="docutils literal"><span class="pre">--installpkgs</span> <span class="pre"><pkgname></span></tt> to lorax at
|
||||
runtime. The x86, ppc, ppc64le and aarch64 templates all look for
|
||||
/usr/share/lorax/product/ and /usr/share/lorax/updates/ directories in the
|
||||
install chroot while creating the final install tree. If there are files in
|
||||
those directories lorax will create images/product.img and/or
|
||||
images/updates.img</p>
|
||||
<p>These archives are just like an anaconda updates image – their contents are
|
||||
copied over the top of the filesystem at boot time so that you can drop in
|
||||
files to add to or replace anything on the filesystem.</p>
|
||||
<p>Anaconda has several places that it looks for updates, the one for product.img
|
||||
is in /run/install/product. So for example, to add an installclass to Anaconda
|
||||
you would put your custom class here:</p>
|
||||
<p><tt class="docutils literal"><span class="pre">/usr/share/lorax/product/run/install/product/pyanaconda/installclasses/custom.py</span></tt></p>
|
||||
<p>If the packages containing the product/updates files are not included as part
|
||||
of normal dependencies you can add specific packages with the <tt class="docutils literal"><span class="pre">--installpkgs</span></tt>
|
||||
command or the installpkgs paramater of <a class="reference internal" href="pylorax.html#pylorax.treebuilder.RuntimeBuilder" title="pylorax.treebuilder.RuntimeBuilder"><tt class="xref py py-class docutils literal"><span class="pre">pylorax.treebuilder.RuntimeBuilder</span></tt></a></p>
|
||||
</div>
|
||||
|
||||
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="sphinxsidebar">
|
||||
<div class="sphinxsidebarwrapper">
|
||||
<h4>Previous topic</h4>
|
||||
<p class="topless"><a href="lorax-composer.html"
|
||||
title="previous chapter">lorax-composer</a></p>
|
||||
<h4>Next topic</h4>
|
||||
<p class="topless"><a href="modules.html"
|
||||
title="next chapter">src</a></p>
|
||||
<h3>This Page</h3>
|
||||
<ul class="this-page-menu">
|
||||
<li><a href="_sources/product-images.txt"
|
||||
rel="nofollow">Show Source</a></li>
|
||||
</ul>
|
||||
<div id="searchbox" style="display: none">
|
||||
<h3>Quick search</h3>
|
||||
<form class="search" action="search.html" method="get">
|
||||
<input type="text" name="q" />
|
||||
<input type="submit" value="Go" />
|
||||
<input type="hidden" name="check_keywords" value="yes" />
|
||||
<input type="hidden" name="area" value="default" />
|
||||
</form>
|
||||
<p class="searchtip" style="font-size: 90%">
|
||||
Enter search terms or a module, class or function name.
|
||||
</p>
|
||||
</div>
|
||||
<script type="text/javascript">$('#searchbox').show(0);</script>
|
||||
</div>
|
||||
</div>
|
||||
<div class="clearer"></div>
|
||||
</div>
|
||||
<div class="related">
|
||||
<h3>Navigation</h3>
|
||||
<ul>
|
||||
<li class="right" style="margin-right: 10px">
|
||||
<a href="genindex.html" title="General Index"
|
||||
>index</a></li>
|
||||
<li class="right" >
|
||||
<a href="py-modindex.html" title="Python Module Index"
|
||||
>modules</a> |</li>
|
||||
<li class="right" >
|
||||
<a href="modules.html" title="src"
|
||||
>next</a> |</li>
|
||||
<li class="right" >
|
||||
<a href="lorax-composer.html" title="lorax-composer"
|
||||
>previous</a> |</li>
|
||||
<li><a href="index.html">Lorax 19.7.11 documentation</a> »</li>
|
||||
</ul>
|
||||
</div>
|
||||
<div class="footer">
|
||||
© Copyright 2018, Red Hat, Inc..
|
||||
Created using <a href="http://sphinx.pocoo.org/">Sphinx</a> 1.1.3.
|
||||
</div>
|
||||
</body>
|
||||
</html>
|
@ -8,7 +8,7 @@
|
||||
<head>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
|
||||
|
||||
<title>Python Module Index — Lorax 19.7.10 documentation</title>
|
||||
<title>Python Module Index — Lorax 19.7.11 documentation</title>
|
||||
|
||||
<link rel="stylesheet" href="_static/default.css" type="text/css" />
|
||||
<link rel="stylesheet" href="_static/pygments.css" type="text/css" />
|
||||
@ -16,7 +16,7 @@
|
||||
<script type="text/javascript">
|
||||
var DOCUMENTATION_OPTIONS = {
|
||||
URL_ROOT: '',
|
||||
VERSION: '19.7.10',
|
||||
VERSION: '19.7.11',
|
||||
COLLAPSE_INDEX: false,
|
||||
FILE_SUFFIX: '.html',
|
||||
HAS_SOURCE: true
|
||||
@ -25,7 +25,7 @@
|
||||
<script type="text/javascript" src="_static/jquery.js"></script>
|
||||
<script type="text/javascript" src="_static/underscore.js"></script>
|
||||
<script type="text/javascript" src="_static/doctools.js"></script>
|
||||
<link rel="top" title="Lorax 19.7.10 documentation" href="index.html" />
|
||||
<link rel="top" title="Lorax 19.7.11 documentation" href="index.html" />
|
||||
|
||||
|
||||
|
||||
@ -40,7 +40,7 @@
|
||||
<li class="right" >
|
||||
<a href="#" title="Python Module Index"
|
||||
>modules</a> |</li>
|
||||
<li><a href="index.html">Lorax 19.7.10 documentation</a> »</li>
|
||||
<li><a href="index.html">Lorax 19.7.11 documentation</a> »</li>
|
||||
</ul>
|
||||
</div>
|
||||
|
||||
@ -53,150 +53,195 @@
|
||||
<h1>Python Module Index</h1>
|
||||
|
||||
<div class="modindex-jumpbox">
|
||||
<a href="#cap-c"><strong>c</strong></a> |
|
||||
<a href="#cap-p"><strong>p</strong></a>
|
||||
</div>
|
||||
|
||||
<table class="indextable modindextable" cellspacing="0" cellpadding="2">
|
||||
<tr class="pcap"><td></td><td> </td><td></td></tr>
|
||||
<tr class="cap" id="cap-p"><td></td><td>
|
||||
<strong>p</strong></td><td></td></tr>
|
||||
<tr class="cap" id="cap-c"><td></td><td>
|
||||
<strong>c</strong></td><td></td></tr>
|
||||
<tr>
|
||||
<td><img src="_static/minus.png" class="toggler"
|
||||
id="toggle-1" style="display: none" alt="-" /></td>
|
||||
<td>
|
||||
<tt class="xref">pylorax</tt></td><td>
|
||||
<a href="composer.html#module-composer"><tt class="xref">composer</tt></a></td><td>
|
||||
<em></em></td></tr>
|
||||
<tr class="cg-1">
|
||||
<td></td>
|
||||
<td>
|
||||
<a href="pylorax.html#module-pylorax.__init__"><tt class="xref">pylorax.__init__</tt></a></td><td>
|
||||
<a href="composer.cli.html#module-composer.cli"><tt class="xref">composer.cli</tt></a></td><td>
|
||||
<em></em></td></tr>
|
||||
<tr class="cg-1">
|
||||
<td></td>
|
||||
<td>
|
||||
<a href="composer.cli.html#module-composer.cli.compose"><tt class="xref">composer.cli.compose</tt></a></td><td>
|
||||
<em></em></td></tr>
|
||||
<tr class="cg-1">
|
||||
<td></td>
|
||||
<td>
|
||||
<a href="composer.cli.html#module-composer.cli.modules"><tt class="xref">composer.cli.modules</tt></a></td><td>
|
||||
<em></em></td></tr>
|
||||
<tr class="cg-1">
|
||||
<td></td>
|
||||
<td>
|
||||
<a href="composer.cli.html#module-composer.cli.projects"><tt class="xref">composer.cli.projects</tt></a></td><td>
|
||||
<em></em></td></tr>
|
||||
<tr class="cg-1">
|
||||
<td></td>
|
||||
<td>
|
||||
<a href="composer.cli.html#module-composer.cli.recipes"><tt class="xref">composer.cli.recipes</tt></a></td><td>
|
||||
<em></em></td></tr>
|
||||
<tr class="cg-1">
|
||||
<td></td>
|
||||
<td>
|
||||
<a href="composer.cli.html#module-composer.cli.utilities"><tt class="xref">composer.cli.utilities</tt></a></td><td>
|
||||
<em></em></td></tr>
|
||||
<tr class="cg-1">
|
||||
<td></td>
|
||||
<td>
|
||||
<a href="composer.html#module-composer.http_client"><tt class="xref">composer.http_client</tt></a></td><td>
|
||||
<em></em></td></tr>
|
||||
<tr class="cg-1">
|
||||
<td></td>
|
||||
<td>
|
||||
<a href="composer.html#module-composer.unix_socket"><tt class="xref">composer.unix_socket</tt></a></td><td>
|
||||
<em></em></td></tr>
|
||||
<tr class="pcap"><td></td><td> </td><td></td></tr>
|
||||
<tr class="cap" id="cap-p"><td></td><td>
|
||||
<strong>p</strong></td><td></td></tr>
|
||||
<tr>
|
||||
<td><img src="_static/minus.png" class="toggler"
|
||||
id="toggle-2" style="display: none" alt="-" /></td>
|
||||
<td>
|
||||
<a href="pylorax.html#module-pylorax"><tt class="xref">pylorax</tt></a></td><td>
|
||||
<em></em></td></tr>
|
||||
<tr class="cg-2">
|
||||
<td></td>
|
||||
<td>
|
||||
<a href="pylorax.api.html#module-pylorax.api"><tt class="xref">pylorax.api</tt></a></td><td>
|
||||
<em></em></td></tr>
|
||||
<tr class="cg-1">
|
||||
<tr class="cg-2">
|
||||
<td></td>
|
||||
<td>
|
||||
<a href="pylorax.api.html#module-pylorax.api.compose"><tt class="xref">pylorax.api.compose</tt></a></td><td>
|
||||
<em></em></td></tr>
|
||||
<tr class="cg-1">
|
||||
<tr class="cg-2">
|
||||
<td></td>
|
||||
<td>
|
||||
<a href="pylorax.api.html#module-pylorax.api.config"><tt class="xref">pylorax.api.config</tt></a></td><td>
|
||||
<em></em></td></tr>
|
||||
<tr class="cg-1">
|
||||
<tr class="cg-2">
|
||||
<td></td>
|
||||
<td>
|
||||
<a href="pylorax.api.html#module-pylorax.api.crossdomain"><tt class="xref">pylorax.api.crossdomain</tt></a></td><td>
|
||||
<em></em></td></tr>
|
||||
<tr class="cg-1">
|
||||
<tr class="cg-2">
|
||||
<td></td>
|
||||
<td>
|
||||
<a href="pylorax.api.html#module-pylorax.api.projects"><tt class="xref">pylorax.api.projects</tt></a></td><td>
|
||||
<em></em></td></tr>
|
||||
<tr class="cg-1">
|
||||
<tr class="cg-2">
|
||||
<td></td>
|
||||
<td>
|
||||
<a href="pylorax.api.html#module-pylorax.api.queue"><tt class="xref">pylorax.api.queue</tt></a></td><td>
|
||||
<em></em></td></tr>
|
||||
<tr class="cg-1">
|
||||
<tr class="cg-2">
|
||||
<td></td>
|
||||
<td>
|
||||
<a href="pylorax.api.html#module-pylorax.api.recipes"><tt class="xref">pylorax.api.recipes</tt></a></td><td>
|
||||
<em></em></td></tr>
|
||||
<tr class="cg-1">
|
||||
<tr class="cg-2">
|
||||
<td></td>
|
||||
<td>
|
||||
<a href="pylorax.api.html#module-pylorax.api.server"><tt class="xref">pylorax.api.server</tt></a></td><td>
|
||||
<em></em></td></tr>
|
||||
<tr class="cg-1">
|
||||
<tr class="cg-2">
|
||||
<td></td>
|
||||
<td>
|
||||
<a href="pylorax.api.html#module-pylorax.api.v0"><tt class="xref">pylorax.api.v0</tt></a></td><td>
|
||||
<em></em></td></tr>
|
||||
<tr class="cg-1">
|
||||
<tr class="cg-2">
|
||||
<td></td>
|
||||
<td>
|
||||
<a href="pylorax.api.html#module-pylorax.api.workspace"><tt class="xref">pylorax.api.workspace</tt></a></td><td>
|
||||
<em></em></td></tr>
|
||||
<tr class="cg-1">
|
||||
<tr class="cg-2">
|
||||
<td></td>
|
||||
<td>
|
||||
<a href="pylorax.api.html#module-pylorax.api.yumbase"><tt class="xref">pylorax.api.yumbase</tt></a></td><td>
|
||||
<em></em></td></tr>
|
||||
<tr class="cg-1">
|
||||
<tr class="cg-2">
|
||||
<td></td>
|
||||
<td>
|
||||
<a href="pylorax.html#module-pylorax.base"><tt class="xref">pylorax.base</tt></a></td><td>
|
||||
<em></em></td></tr>
|
||||
<tr class="cg-1">
|
||||
<tr class="cg-2">
|
||||
<td></td>
|
||||
<td>
|
||||
<a href="pylorax.html#module-pylorax.buildstamp"><tt class="xref">pylorax.buildstamp</tt></a></td><td>
|
||||
<em></em></td></tr>
|
||||
<tr class="cg-1">
|
||||
<tr class="cg-2">
|
||||
<td></td>
|
||||
<td>
|
||||
<a href="pylorax.html#module-pylorax.creator"><tt class="xref">pylorax.creator</tt></a></td><td>
|
||||
<em></em></td></tr>
|
||||
<tr class="cg-1">
|
||||
<tr class="cg-2">
|
||||
<td></td>
|
||||
<td>
|
||||
<a href="pylorax.html#module-pylorax.decorators"><tt class="xref">pylorax.decorators</tt></a></td><td>
|
||||
<em></em></td></tr>
|
||||
<tr class="cg-1">
|
||||
<tr class="cg-2">
|
||||
<td></td>
|
||||
<td>
|
||||
<a href="pylorax.html#module-pylorax.discinfo"><tt class="xref">pylorax.discinfo</tt></a></td><td>
|
||||
<em></em></td></tr>
|
||||
<tr class="cg-1">
|
||||
<tr class="cg-2">
|
||||
<td></td>
|
||||
<td>
|
||||
<a href="pylorax.html#module-pylorax.executils"><tt class="xref">pylorax.executils</tt></a></td><td>
|
||||
<em></em></td></tr>
|
||||
<tr class="cg-1">
|
||||
<tr class="cg-2">
|
||||
<td></td>
|
||||
<td>
|
||||
<a href="pylorax.html#module-pylorax.imgutils"><tt class="xref">pylorax.imgutils</tt></a></td><td>
|
||||
<em></em></td></tr>
|
||||
<tr class="cg-1">
|
||||
<tr class="cg-2">
|
||||
<td></td>
|
||||
<td>
|
||||
<a href="pylorax.html#module-pylorax.installer"><tt class="xref">pylorax.installer</tt></a></td><td>
|
||||
<em></em></td></tr>
|
||||
<tr class="cg-1">
|
||||
<tr class="cg-2">
|
||||
<td></td>
|
||||
<td>
|
||||
<a href="pylorax.html#module-pylorax.logmonitor"><tt class="xref">pylorax.logmonitor</tt></a></td><td>
|
||||
<em></em></td></tr>
|
||||
<tr class="cg-1">
|
||||
<tr class="cg-2">
|
||||
<td></td>
|
||||
<td>
|
||||
<a href="pylorax.html#module-pylorax.ltmpl"><tt class="xref">pylorax.ltmpl</tt></a></td><td>
|
||||
<em></em></td></tr>
|
||||
<tr class="cg-1">
|
||||
<tr class="cg-2">
|
||||
<td></td>
|
||||
<td>
|
||||
<a href="pylorax.html#module-pylorax.output"><tt class="xref">pylorax.output</tt></a></td><td>
|
||||
<em></em></td></tr>
|
||||
<tr class="cg-1">
|
||||
<tr class="cg-2">
|
||||
<td></td>
|
||||
<td>
|
||||
<a href="pylorax.html#module-pylorax.sysutils"><tt class="xref">pylorax.sysutils</tt></a></td><td>
|
||||
<em></em></td></tr>
|
||||
<tr class="cg-1">
|
||||
<tr class="cg-2">
|
||||
<td></td>
|
||||
<td>
|
||||
<a href="pylorax.html#module-pylorax.treebuilder"><tt class="xref">pylorax.treebuilder</tt></a></td><td>
|
||||
<em></em></td></tr>
|
||||
<tr class="cg-1">
|
||||
<tr class="cg-2">
|
||||
<td></td>
|
||||
<td>
|
||||
<a href="pylorax.html#module-pylorax.treeinfo"><tt class="xref">pylorax.treeinfo</tt></a></td><td>
|
||||
<em></em></td></tr>
|
||||
<tr class="cg-1">
|
||||
<tr class="cg-2">
|
||||
<td></td>
|
||||
<td>
|
||||
<a href="pylorax.html#module-pylorax.yumhelper"><tt class="xref">pylorax.yumhelper</tt></a></td><td>
|
||||
@ -235,11 +280,11 @@
|
||||
<li class="right" >
|
||||
<a href="#" title="Python Module Index"
|
||||
>modules</a> |</li>
|
||||
<li><a href="index.html">Lorax 19.7.10 documentation</a> »</li>
|
||||
<li><a href="index.html">Lorax 19.7.11 documentation</a> »</li>
|
||||
</ul>
|
||||
</div>
|
||||
<div class="footer">
|
||||
© Copyright 2017, Red Hat, Inc..
|
||||
© Copyright 2018, Red Hat, Inc..
|
||||
Created using <a href="http://sphinx.pocoo.org/">Sphinx</a> 1.1.3.
|
||||
</div>
|
||||
</body>
|
||||
|
@ -8,7 +8,7 @@
|
||||
<head>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
|
||||
|
||||
<title>api Package — Lorax 19.7.10 documentation</title>
|
||||
<title>api Package — Lorax 19.7.11 documentation</title>
|
||||
|
||||
<link rel="stylesheet" href="_static/default.css" type="text/css" />
|
||||
<link rel="stylesheet" href="_static/pygments.css" type="text/css" />
|
||||
@ -16,7 +16,7 @@
|
||||
<script type="text/javascript">
|
||||
var DOCUMENTATION_OPTIONS = {
|
||||
URL_ROOT: '',
|
||||
VERSION: '19.7.10',
|
||||
VERSION: '19.7.11',
|
||||
COLLAPSE_INDEX: false,
|
||||
FILE_SUFFIX: '.html',
|
||||
HAS_SOURCE: true
|
||||
@ -25,7 +25,7 @@
|
||||
<script type="text/javascript" src="_static/jquery.js"></script>
|
||||
<script type="text/javascript" src="_static/underscore.js"></script>
|
||||
<script type="text/javascript" src="_static/doctools.js"></script>
|
||||
<link rel="top" title="Lorax 19.7.10 documentation" href="index.html" />
|
||||
<link rel="top" title="Lorax 19.7.11 documentation" href="index.html" />
|
||||
<link rel="up" title="pylorax Package" href="pylorax.html" />
|
||||
<link rel="prev" title="pylorax Package" href="pylorax.html" />
|
||||
</head>
|
||||
@ -42,8 +42,8 @@
|
||||
<li class="right" >
|
||||
<a href="pylorax.html" title="pylorax Package"
|
||||
accesskey="P">previous</a> |</li>
|
||||
<li><a href="index.html">Lorax 19.7.10 documentation</a> »</li>
|
||||
<li><a href="modules.html" >pylorax</a> »</li>
|
||||
<li><a href="index.html">Lorax 19.7.11 documentation</a> »</li>
|
||||
<li><a href="modules.html" >src</a> »</li>
|
||||
<li><a href="pylorax.html" accesskey="U">pylorax Package</a> »</li>
|
||||
</ul>
|
||||
</div>
|
||||
@ -97,7 +97,7 @@ Other options will be filled in by <cite>make_compose()</cite></p>
|
||||
<dt id="pylorax.api.compose.compose_types">
|
||||
<tt class="descclassname">pylorax.api.compose.</tt><tt class="descname">compose_types</tt><big>(</big><em>share_dir</em><big>)</big><a class="reference internal" href="_modules/pylorax/api/compose.html#compose_types"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#pylorax.api.compose.compose_types" title="Permalink to this definition">¶</a></dt>
|
||||
<dd><p>Returns a list of the supported output types</p>
|
||||
<p>The output types come from the kickstart names in /usr/share/lorax/composer/<a href="#id2"><span class="problematic" id="id3">*</span></a>ks</p>
|
||||
<p>The output types come from the kickstart names in /usr/share/lorax/composer/*ks</p>
|
||||
</dd></dl>
|
||||
|
||||
<dl class="function">
|
||||
@ -1020,7 +1020,7 @@ If they are different, check and return the new version</p>
|
||||
<dl class="function">
|
||||
<dt id="pylorax.api.recipes.commit_recipe_directory">
|
||||
<tt class="descclassname">pylorax.api.recipes.</tt><tt class="descname">commit_recipe_directory</tt><big>(</big><em>repo</em>, <em>branch</em>, <em>directory</em><big>)</big><a class="reference internal" href="_modules/pylorax/api/recipes.html#commit_recipe_directory"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#pylorax.api.recipes.commit_recipe_directory" title="Permalink to this definition">¶</a></dt>
|
||||
<dd><p>Commit all <a href="#id4"><span class="problematic" id="id5">*</span></a>.toml files from a directory, if they aren’t already in git.</p>
|
||||
<dd><p>Commit all *.toml files from a directory, if they aren’t already in git.</p>
|
||||
<table class="docutils field-list" frame="void" rules="none">
|
||||
<col class="field-name" />
|
||||
<col class="field-body" />
|
||||
@ -1028,7 +1028,7 @@ If they are different, check and return the new version</p>
|
||||
<tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><ul class="first simple">
|
||||
<li><strong>repo</strong> (<em>Git.Repository</em>) – Open repository</li>
|
||||
<li><strong>branch</strong> (<a class="reference external" href="https://docs.python.org/2/library/functions.html#str" title="(in Python v2.7)"><em>str</em></a>) – Branch name</li>
|
||||
<li><strong>directory</strong> (<a class="reference external" href="https://docs.python.org/2/library/functions.html#str" title="(in Python v2.7)"><em>str</em></a>) – The directory of <a href="#id6"><span class="problematic" id="id7">*</span></a>.toml recipes to commit</li>
|
||||
<li><strong>directory</strong> (<a class="reference external" href="https://docs.python.org/2/library/functions.html#str" title="(in Python v2.7)"><em>str</em></a>) – The directory of *.toml recipes to commit</li>
|
||||
</ul>
|
||||
</td>
|
||||
</tr>
|
||||
@ -2737,7 +2737,7 @@ UUID-logs.tar</p>
|
||||
<h4><cite>/api/v0/compose/image/<uuid></cite><a class="headerlink" href="#api-v0-compose-image-uuid" title="Permalink to this headline">¶</a></h4>
|
||||
<blockquote>
|
||||
<div>Returns the output image from the build. The filename is set to the filename
|
||||
from the build. eg. root.tar.xz or boot.iso.</div></blockquote>
|
||||
from the build with the UUID as a prefix. eg. UUID-root.tar.xz or UUID-boot.iso.</div></blockquote>
|
||||
</div>
|
||||
<div class="section" id="api-v0-compose-log-uuid-size-kbytes">
|
||||
<h4><cite>/api/v0/compose/log/<uuid>[?size=kbytes]</cite><a class="headerlink" href="#api-v0-compose-log-uuid-size-kbytes" title="Permalink to this headline">¶</a></h4>
|
||||
@ -3025,13 +3025,13 @@ a line boundry.</p>
|
||||
<li class="right" >
|
||||
<a href="pylorax.html" title="pylorax Package"
|
||||
>previous</a> |</li>
|
||||
<li><a href="index.html">Lorax 19.7.10 documentation</a> »</li>
|
||||
<li><a href="modules.html" >pylorax</a> »</li>
|
||||
<li><a href="index.html">Lorax 19.7.11 documentation</a> »</li>
|
||||
<li><a href="modules.html" >src</a> »</li>
|
||||
<li><a href="pylorax.html" >pylorax Package</a> »</li>
|
||||
</ul>
|
||||
</div>
|
||||
<div class="footer">
|
||||
© Copyright 2017, Red Hat, Inc..
|
||||
© Copyright 2018, Red Hat, Inc..
|
||||
Created using <a href="http://sphinx.pocoo.org/">Sphinx</a> 1.1.3.
|
||||
</div>
|
||||
</body>
|
||||
|
@ -8,7 +8,7 @@
|
||||
<head>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
|
||||
|
||||
<title>pylorax Package — Lorax 19.7.10 documentation</title>
|
||||
<title>pylorax Package — Lorax 19.7.11 documentation</title>
|
||||
|
||||
<link rel="stylesheet" href="_static/default.css" type="text/css" />
|
||||
<link rel="stylesheet" href="_static/pygments.css" type="text/css" />
|
||||
@ -16,7 +16,7 @@
|
||||
<script type="text/javascript">
|
||||
var DOCUMENTATION_OPTIONS = {
|
||||
URL_ROOT: '',
|
||||
VERSION: '19.7.10',
|
||||
VERSION: '19.7.11',
|
||||
COLLAPSE_INDEX: false,
|
||||
FILE_SUFFIX: '.html',
|
||||
HAS_SOURCE: true
|
||||
@ -25,10 +25,10 @@
|
||||
<script type="text/javascript" src="_static/jquery.js"></script>
|
||||
<script type="text/javascript" src="_static/underscore.js"></script>
|
||||
<script type="text/javascript" src="_static/doctools.js"></script>
|
||||
<link rel="top" title="Lorax 19.7.10 documentation" href="index.html" />
|
||||
<link rel="up" title="pylorax" href="modules.html" />
|
||||
<link rel="top" title="Lorax 19.7.11 documentation" href="index.html" />
|
||||
<link rel="up" title="src" href="modules.html" />
|
||||
<link rel="next" title="api Package" href="pylorax.api.html" />
|
||||
<link rel="prev" title="pylorax" href="modules.html" />
|
||||
<link rel="prev" title="cli Package" href="composer.cli.html" />
|
||||
</head>
|
||||
<body>
|
||||
<div class="related">
|
||||
@ -44,10 +44,10 @@
|
||||
<a href="pylorax.api.html" title="api Package"
|
||||
accesskey="N">next</a> |</li>
|
||||
<li class="right" >
|
||||
<a href="modules.html" title="pylorax"
|
||||
<a href="composer.cli.html" title="cli Package"
|
||||
accesskey="P">previous</a> |</li>
|
||||
<li><a href="index.html">Lorax 19.7.10 documentation</a> »</li>
|
||||
<li><a href="modules.html" accesskey="U">pylorax</a> »</li>
|
||||
<li><a href="index.html">Lorax 19.7.11 documentation</a> »</li>
|
||||
<li><a href="modules.html" accesskey="U">src</a> »</li>
|
||||
</ul>
|
||||
</div>
|
||||
|
||||
@ -59,52 +59,52 @@
|
||||
<div class="section" id="pylorax-package">
|
||||
<h1>pylorax Package<a class="headerlink" href="#pylorax-package" title="Permalink to this headline">¶</a></h1>
|
||||
<div class="section" id="id1">
|
||||
<h2><tt class="xref py py-mod docutils literal"><span class="pre">pylorax</span></tt> Package<a class="headerlink" href="#id1" title="Permalink to this headline">¶</a></h2>
|
||||
<span class="target" id="module-pylorax.__init__"></span><dl class="class">
|
||||
<dt id="pylorax.__init__.ArchData">
|
||||
<em class="property">class </em><tt class="descclassname">pylorax.__init__.</tt><tt class="descname">ArchData</tt><big>(</big><em>buildarch</em><big>)</big><a class="reference internal" href="_modules/pylorax/__init__.html#ArchData"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#pylorax.__init__.ArchData" title="Permalink to this definition">¶</a></dt>
|
||||
<h2><a class="reference internal" href="#module-pylorax" title="pylorax"><tt class="xref py py-mod docutils literal"><span class="pre">pylorax</span></tt></a> Package<a class="headerlink" href="#id1" title="Permalink to this headline">¶</a></h2>
|
||||
<span class="target" id="module-pylorax"></span><dl class="class">
|
||||
<dt id="pylorax.ArchData">
|
||||
<em class="property">class </em><tt class="descclassname">pylorax.</tt><tt class="descname">ArchData</tt><big>(</big><em>buildarch</em><big>)</big><a class="reference internal" href="_modules/pylorax.html#ArchData"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#pylorax.ArchData" title="Permalink to this definition">¶</a></dt>
|
||||
<dd><p>Bases: <a class="reference internal" href="#pylorax.base.DataHolder" title="pylorax.base.DataHolder"><tt class="xref py py-class docutils literal"><span class="pre">pylorax.base.DataHolder</span></tt></a></p>
|
||||
<dl class="attribute">
|
||||
<dt id="pylorax.__init__.ArchData.bcj_arch">
|
||||
<tt class="descname">bcj_arch</tt><em class="property"> = {'ppc': 'powerpc', 'x86_64': 'x86', 'i386': 'x86', 'armhfp': 'arm', 'ppc64le': 'powerpc', 'ppc64': 'powerpc', 'arm': 'arm'}</em><a class="headerlink" href="#pylorax.__init__.ArchData.bcj_arch" title="Permalink to this definition">¶</a></dt>
|
||||
<dt id="pylorax.ArchData.bcj_arch">
|
||||
<tt class="descname">bcj_arch</tt><em class="property"> = {'ppc': 'powerpc', 'x86_64': 'x86', 'i386': 'x86', 'armhfp': 'arm', 'ppc64le': 'powerpc', 'ppc64': 'powerpc', 'arm': 'arm'}</em><a class="headerlink" href="#pylorax.ArchData.bcj_arch" title="Permalink to this definition">¶</a></dt>
|
||||
<dd></dd></dl>
|
||||
|
||||
<dl class="attribute">
|
||||
<dt id="pylorax.__init__.ArchData.lib64_arches">
|
||||
<tt class="descname">lib64_arches</tt><em class="property"> = ('x86_64', 'ppc64', 'ppc64le', 's390x', 'ia64', 'aarch64')</em><a class="headerlink" href="#pylorax.__init__.ArchData.lib64_arches" title="Permalink to this definition">¶</a></dt>
|
||||
<dt id="pylorax.ArchData.lib64_arches">
|
||||
<tt class="descname">lib64_arches</tt><em class="property"> = ('x86_64', 'ppc64', 'ppc64le', 's390x', 'ia64', 'aarch64')</em><a class="headerlink" href="#pylorax.ArchData.lib64_arches" title="Permalink to this definition">¶</a></dt>
|
||||
<dd></dd></dl>
|
||||
|
||||
</dd></dl>
|
||||
|
||||
<dl class="class">
|
||||
<dt id="pylorax.__init__.Lorax">
|
||||
<em class="property">class </em><tt class="descclassname">pylorax.__init__.</tt><tt class="descname">Lorax</tt><a class="reference internal" href="_modules/pylorax/__init__.html#Lorax"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#pylorax.__init__.Lorax" title="Permalink to this definition">¶</a></dt>
|
||||
<dt id="pylorax.Lorax">
|
||||
<em class="property">class </em><tt class="descclassname">pylorax.</tt><tt class="descname">Lorax</tt><a class="reference internal" href="_modules/pylorax.html#Lorax"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#pylorax.Lorax" title="Permalink to this definition">¶</a></dt>
|
||||
<dd><p>Bases: <a class="reference internal" href="#pylorax.base.BaseLoraxClass" title="pylorax.base.BaseLoraxClass"><tt class="xref py py-class docutils literal"><span class="pre">pylorax.base.BaseLoraxClass</span></tt></a></p>
|
||||
<dl class="method">
|
||||
<dt id="pylorax.__init__.Lorax.configure">
|
||||
<tt class="descname">configure</tt><big>(</big><em>conf_file='/etc/lorax/lorax.conf'</em><big>)</big><a class="reference internal" href="_modules/pylorax/__init__.html#Lorax.configure"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#pylorax.__init__.Lorax.configure" title="Permalink to this definition">¶</a></dt>
|
||||
<dt id="pylorax.Lorax.configure">
|
||||
<tt class="descname">configure</tt><big>(</big><em>conf_file='/etc/lorax/lorax.conf'</em><big>)</big><a class="reference internal" href="_modules/pylorax.html#Lorax.configure"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#pylorax.Lorax.configure" title="Permalink to this definition">¶</a></dt>
|
||||
<dd></dd></dl>
|
||||
|
||||
<dl class="method">
|
||||
<dt id="pylorax.__init__.Lorax.init_file_logging">
|
||||
<tt class="descname">init_file_logging</tt><big>(</big><em>logdir</em>, <em>logname='pylorax.log'</em><big>)</big><a class="reference internal" href="_modules/pylorax/__init__.html#Lorax.init_file_logging"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#pylorax.__init__.Lorax.init_file_logging" title="Permalink to this definition">¶</a></dt>
|
||||
<dt id="pylorax.Lorax.init_file_logging">
|
||||
<tt class="descname">init_file_logging</tt><big>(</big><em>logdir</em>, <em>logname='pylorax.log'</em><big>)</big><a class="reference internal" href="_modules/pylorax.html#Lorax.init_file_logging"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#pylorax.Lorax.init_file_logging" title="Permalink to this definition">¶</a></dt>
|
||||
<dd></dd></dl>
|
||||
|
||||
<dl class="method">
|
||||
<dt id="pylorax.__init__.Lorax.init_stream_logging">
|
||||
<tt class="descname">init_stream_logging</tt><big>(</big><big>)</big><a class="reference internal" href="_modules/pylorax/__init__.html#Lorax.init_stream_logging"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#pylorax.__init__.Lorax.init_stream_logging" title="Permalink to this definition">¶</a></dt>
|
||||
<dt id="pylorax.Lorax.init_stream_logging">
|
||||
<tt class="descname">init_stream_logging</tt><big>(</big><big>)</big><a class="reference internal" href="_modules/pylorax.html#Lorax.init_stream_logging"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#pylorax.Lorax.init_stream_logging" title="Permalink to this definition">¶</a></dt>
|
||||
<dd></dd></dl>
|
||||
|
||||
<dl class="method">
|
||||
<dt id="pylorax.__init__.Lorax.run">
|
||||
<tt class="descname">run</tt><big>(</big><em>ybo</em>, <em>product</em>, <em>version</em>, <em>release</em>, <em>variant=''</em>, <em>bugurl=''</em>, <em>isfinal=False</em>, <em>workdir=None</em>, <em>outputdir=None</em>, <em>buildarch=None</em>, <em>volid=None</em>, <em>domacboot=False</em>, <em>doupgrade=True</em>, <em>remove_temp=False</em>, <em>installpkgs=None</em>, <em>size=2</em>, <em>add_templates=None</em>, <em>add_template_vars=None</em>, <em>add_arch_templates=None</em>, <em>add_arch_template_vars=None</em>, <em>template_tempdir=None</em><big>)</big><a class="reference internal" href="_modules/pylorax/__init__.html#Lorax.run"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#pylorax.__init__.Lorax.run" title="Permalink to this definition">¶</a></dt>
|
||||
<dt id="pylorax.Lorax.run">
|
||||
<tt class="descname">run</tt><big>(</big><em>ybo</em>, <em>product</em>, <em>version</em>, <em>release</em>, <em>variant=''</em>, <em>bugurl=''</em>, <em>isfinal=False</em>, <em>workdir=None</em>, <em>outputdir=None</em>, <em>buildarch=None</em>, <em>volid=None</em>, <em>domacboot=False</em>, <em>doupgrade=True</em>, <em>remove_temp=False</em>, <em>installpkgs=None</em>, <em>size=2</em>, <em>add_templates=None</em>, <em>add_template_vars=None</em>, <em>add_arch_templates=None</em>, <em>add_arch_template_vars=None</em>, <em>template_tempdir=None</em><big>)</big><a class="reference internal" href="_modules/pylorax.html#Lorax.run"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#pylorax.Lorax.run" title="Permalink to this definition">¶</a></dt>
|
||||
<dd></dd></dl>
|
||||
|
||||
</dd></dl>
|
||||
|
||||
<dl class="function">
|
||||
<dt id="pylorax.__init__.get_buildarch">
|
||||
<tt class="descclassname">pylorax.__init__.</tt><tt class="descname">get_buildarch</tt><big>(</big><em>ybo</em><big>)</big><a class="reference internal" href="_modules/pylorax/__init__.html#get_buildarch"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#pylorax.__init__.get_buildarch" title="Permalink to this definition">¶</a></dt>
|
||||
<dt id="pylorax.get_buildarch">
|
||||
<tt class="descclassname">pylorax.</tt><tt class="descname">get_buildarch</tt><big>(</big><em>ybo</em><big>)</big><a class="reference internal" href="_modules/pylorax.html#get_buildarch"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#pylorax.get_buildarch" title="Permalink to this definition">¶</a></dt>
|
||||
<dd></dd></dl>
|
||||
|
||||
</div>
|
||||
@ -116,27 +116,27 @@
|
||||
<dd><p>Bases: <a class="reference external" href="https://docs.python.org/2/library/functions.html#object" title="(in Python v2.7)"><tt class="xref py py-class docutils literal"><span class="pre">object</span></tt></a></p>
|
||||
<dl class="method">
|
||||
<dt id="pylorax.base.BaseLoraxClass.pcritical">
|
||||
<tt class="descname">pcritical</tt><big>(</big><em>msg</em>, <em>fobj=<open file '<stdout>'</em>, <em>mode 'w' at 0x7ff04f808150></em><big>)</big><a class="reference internal" href="_modules/pylorax/base.html#BaseLoraxClass.pcritical"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#pylorax.base.BaseLoraxClass.pcritical" title="Permalink to this definition">¶</a></dt>
|
||||
<tt class="descname">pcritical</tt><big>(</big><em>msg</em>, <em>fobj=<open file '<stdout>'</em>, <em>mode 'w' at 0x7f4f7f21e150></em><big>)</big><a class="reference internal" href="_modules/pylorax/base.html#BaseLoraxClass.pcritical"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#pylorax.base.BaseLoraxClass.pcritical" title="Permalink to this definition">¶</a></dt>
|
||||
<dd></dd></dl>
|
||||
|
||||
<dl class="method">
|
||||
<dt id="pylorax.base.BaseLoraxClass.pdebug">
|
||||
<tt class="descname">pdebug</tt><big>(</big><em>msg</em>, <em>fobj=<open file '<stdout>'</em>, <em>mode 'w' at 0x7ff04f808150></em><big>)</big><a class="reference internal" href="_modules/pylorax/base.html#BaseLoraxClass.pdebug"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#pylorax.base.BaseLoraxClass.pdebug" title="Permalink to this definition">¶</a></dt>
|
||||
<tt class="descname">pdebug</tt><big>(</big><em>msg</em>, <em>fobj=<open file '<stdout>'</em>, <em>mode 'w' at 0x7f4f7f21e150></em><big>)</big><a class="reference internal" href="_modules/pylorax/base.html#BaseLoraxClass.pdebug"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#pylorax.base.BaseLoraxClass.pdebug" title="Permalink to this definition">¶</a></dt>
|
||||
<dd></dd></dl>
|
||||
|
||||
<dl class="method">
|
||||
<dt id="pylorax.base.BaseLoraxClass.perror">
|
||||
<tt class="descname">perror</tt><big>(</big><em>msg</em>, <em>fobj=<open file '<stdout>'</em>, <em>mode 'w' at 0x7ff04f808150></em><big>)</big><a class="reference internal" href="_modules/pylorax/base.html#BaseLoraxClass.perror"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#pylorax.base.BaseLoraxClass.perror" title="Permalink to this definition">¶</a></dt>
|
||||
<tt class="descname">perror</tt><big>(</big><em>msg</em>, <em>fobj=<open file '<stdout>'</em>, <em>mode 'w' at 0x7f4f7f21e150></em><big>)</big><a class="reference internal" href="_modules/pylorax/base.html#BaseLoraxClass.perror"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#pylorax.base.BaseLoraxClass.perror" title="Permalink to this definition">¶</a></dt>
|
||||
<dd></dd></dl>
|
||||
|
||||
<dl class="method">
|
||||
<dt id="pylorax.base.BaseLoraxClass.pinfo">
|
||||
<tt class="descname">pinfo</tt><big>(</big><em>msg</em>, <em>fobj=<open file '<stdout>'</em>, <em>mode 'w' at 0x7ff04f808150></em><big>)</big><a class="reference internal" href="_modules/pylorax/base.html#BaseLoraxClass.pinfo"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#pylorax.base.BaseLoraxClass.pinfo" title="Permalink to this definition">¶</a></dt>
|
||||
<tt class="descname">pinfo</tt><big>(</big><em>msg</em>, <em>fobj=<open file '<stdout>'</em>, <em>mode 'w' at 0x7f4f7f21e150></em><big>)</big><a class="reference internal" href="_modules/pylorax/base.html#BaseLoraxClass.pinfo"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#pylorax.base.BaseLoraxClass.pinfo" title="Permalink to this definition">¶</a></dt>
|
||||
<dd></dd></dl>
|
||||
|
||||
<dl class="method">
|
||||
<dt id="pylorax.base.BaseLoraxClass.pwarning">
|
||||
<tt class="descname">pwarning</tt><big>(</big><em>msg</em>, <em>fobj=<open file '<stdout>'</em>, <em>mode 'w' at 0x7ff04f808150></em><big>)</big><a class="reference internal" href="_modules/pylorax/base.html#BaseLoraxClass.pwarning"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#pylorax.base.BaseLoraxClass.pwarning" title="Permalink to this definition">¶</a></dt>
|
||||
<tt class="descname">pwarning</tt><big>(</big><em>msg</em>, <em>fobj=<open file '<stdout>'</em>, <em>mode 'w' at 0x7f4f7f21e150></em><big>)</big><a class="reference internal" href="_modules/pylorax/base.html#BaseLoraxClass.pwarning"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#pylorax.base.BaseLoraxClass.pwarning" title="Permalink to this definition">¶</a></dt>
|
||||
<dd></dd></dl>
|
||||
|
||||
</dd></dl>
|
||||
@ -1557,8 +1557,8 @@ image is built with the filename “${prefix}-${kernel.version}.img”</
|
||||
</ul>
|
||||
|
||||
<h4>Previous topic</h4>
|
||||
<p class="topless"><a href="modules.html"
|
||||
title="previous chapter">pylorax</a></p>
|
||||
<p class="topless"><a href="composer.cli.html"
|
||||
title="previous chapter">cli Package</a></p>
|
||||
<h4>Next topic</h4>
|
||||
<p class="topless"><a href="pylorax.api.html"
|
||||
title="next chapter">api Package</a></p>
|
||||
@ -1597,14 +1597,14 @@ image is built with the filename “${prefix}-${kernel.version}.img”</
|
||||
<a href="pylorax.api.html" title="api Package"
|
||||
>next</a> |</li>
|
||||
<li class="right" >
|
||||
<a href="modules.html" title="pylorax"
|
||||
<a href="composer.cli.html" title="cli Package"
|
||||
>previous</a> |</li>
|
||||
<li><a href="index.html">Lorax 19.7.10 documentation</a> »</li>
|
||||
<li><a href="modules.html" >pylorax</a> »</li>
|
||||
<li><a href="index.html">Lorax 19.7.11 documentation</a> »</li>
|
||||
<li><a href="modules.html" >src</a> »</li>
|
||||
</ul>
|
||||
</div>
|
||||
<div class="footer">
|
||||
© Copyright 2017, Red Hat, Inc..
|
||||
© Copyright 2018, Red Hat, Inc..
|
||||
Created using <a href="http://sphinx.pocoo.org/">Sphinx</a> 1.1.3.
|
||||
</div>
|
||||
</body>
|
||||
|
@ -8,7 +8,7 @@
|
||||
<head>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
|
||||
|
||||
<title>Search — Lorax 19.7.10 documentation</title>
|
||||
<title>Search — Lorax 19.7.11 documentation</title>
|
||||
|
||||
<link rel="stylesheet" href="_static/default.css" type="text/css" />
|
||||
<link rel="stylesheet" href="_static/pygments.css" type="text/css" />
|
||||
@ -16,7 +16,7 @@
|
||||
<script type="text/javascript">
|
||||
var DOCUMENTATION_OPTIONS = {
|
||||
URL_ROOT: '',
|
||||
VERSION: '19.7.10',
|
||||
VERSION: '19.7.11',
|
||||
COLLAPSE_INDEX: false,
|
||||
FILE_SUFFIX: '.html',
|
||||
HAS_SOURCE: true
|
||||
@ -26,7 +26,7 @@
|
||||
<script type="text/javascript" src="_static/underscore.js"></script>
|
||||
<script type="text/javascript" src="_static/doctools.js"></script>
|
||||
<script type="text/javascript" src="_static/searchtools.js"></script>
|
||||
<link rel="top" title="Lorax 19.7.10 documentation" href="index.html" />
|
||||
<link rel="top" title="Lorax 19.7.11 documentation" href="index.html" />
|
||||
<script type="text/javascript">
|
||||
jQuery(function() { Search.loadIndex("searchindex.js"); });
|
||||
</script>
|
||||
@ -43,7 +43,7 @@
|
||||
<li class="right" >
|
||||
<a href="py-modindex.html" title="Python Module Index"
|
||||
>modules</a> |</li>
|
||||
<li><a href="index.html">Lorax 19.7.10 documentation</a> »</li>
|
||||
<li><a href="index.html">Lorax 19.7.11 documentation</a> »</li>
|
||||
</ul>
|
||||
</div>
|
||||
|
||||
@ -94,11 +94,11 @@
|
||||
<li class="right" >
|
||||
<a href="py-modindex.html" title="Python Module Index"
|
||||
>modules</a> |</li>
|
||||
<li><a href="index.html">Lorax 19.7.10 documentation</a> »</li>
|
||||
<li><a href="index.html">Lorax 19.7.11 documentation</a> »</li>
|
||||
</ul>
|
||||
</div>
|
||||
<div class="footer">
|
||||
© Copyright 2017, Red Hat, Inc..
|
||||
© Copyright 2018, Red Hat, Inc..
|
||||
Created using <a href="http://sphinx.pocoo.org/">Sphinx</a> 1.1.3.
|
||||
</div>
|
||||
</body>
|
||||
|
File diff suppressed because one or more lines are too long
Loading…
Reference in New Issue
Block a user