diff options
Diffstat (limited to 'distro/common/html/knife_xargs.html')
-rw-r--r-- | distro/common/html/knife_xargs.html | 122 |
1 files changed, 0 insertions, 122 deletions
diff --git a/distro/common/html/knife_xargs.html b/distro/common/html/knife_xargs.html deleted file mode 100644 index a81478770c..0000000000 --- a/distro/common/html/knife_xargs.html +++ /dev/null @@ -1,122 +0,0 @@ -<!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>knife xargs — chef-client Man Pages</title> - - <link rel="stylesheet" href="_static/guide.css" type="text/css" /> - <link rel="stylesheet" href="_static/pygments.css" type="text/css" /> - - <script type="text/javascript"> - var DOCUMENTATION_OPTIONS = { - URL_ROOT: './', - VERSION: '', - 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> - - - </head> - <body> -<div style="background-color: #212c35; text-align: left; padding: 0px 0px 0px 0px"> -<a href="http://docs.getchef.com/"><img src="_static/chef_html_logo.png" border="0" alt="Chef"/></a> -</div> - - - - - <div class="document"> - <div class="documentwrapper"> - - <div class="body"> - - <div class="section" id="knife-xargs"> -<h1>knife xargs<a class="headerlink" href="#knife-xargs" title="Permalink to this headline">¶</a></h1> -<p>The <strong>knife xargs</strong> subcommand is used to take patterns from standard input, download as JSON, run a command against the downloaded JSON, and then upload any changes.</p> -<div class="section" id="syntax"> -<h2>Syntax<a class="headerlink" href="#syntax" title="Permalink to this headline">¶</a></h2> -<p>This subcommand has the following syntax:</p> -<div class="highlight-bash"><div class="highlight"><pre><span class="nv">$ </span>knife xargs <span class="o">[</span>PATTERN...<span class="o">]</span> <span class="o">(</span>options<span class="o">)</span> -</pre></div> -</div> -</div> -<div class="section" id="options"> -<h2>Options<a class="headerlink" href="#options" title="Permalink to this headline">¶</a></h2> -<div class="admonition note"> -<p class="first admonition-title">Note</p> -<p class="last">Review the list of <a class="reference internal" href="knife_common_options.html"><em>common options</em></a> available to this (and all) knife subcommands and plugins.</p> -</div> -<p>This subcommand has the following options:</p> -<dl class="docutils"> -<dt><tt class="docutils literal"><span class="pre">-0</span></tt></dt> -<dd>Use to show a <tt class="docutils literal"><span class="pre">NULL</span></tt> character (<tt class="docutils literal"><span class="pre">\0</span></tt>) instead of white space as the separator. Default: <tt class="docutils literal"><span class="pre">false</span></tt>.</dd> -<dt><tt class="docutils literal"><span class="pre">--chef-repo-path</span> <span class="pre">PATH</span></tt></dt> -<dd>The path to the chef-repo. This setting will override the default path to the chef-repo. Default: same value as specified by <tt class="docutils literal"><span class="pre">chef_repo_path</span></tt> in client.rb.</dd> -<dt><tt class="docutils literal"><span class="pre">--concurrency</span></tt></dt> -<dd>The number of allowed concurrent connections. Default: <tt class="docutils literal"><span class="pre">10</span></tt>.</dd> -<dt><tt class="docutils literal"><span class="pre">--[no-]diff</span></tt></dt> -<dd>Use to show a diff when a file changes. Default: <tt class="docutils literal"><span class="pre">--diff</span></tt>.</dd> -<dt><tt class="docutils literal"><span class="pre">--dry-run</span></tt></dt> -<dd>Use to prevent changes from being uploaded to the Chef server. Default: <tt class="docutils literal"><span class="pre">false</span></tt>.</dd> -<dt><tt class="docutils literal"><span class="pre">--[no-]force</span></tt></dt> -<dd>Use to force the upload of files even if they haven’t been changed. Default: <tt class="docutils literal"><span class="pre">--no-force</span></tt>.</dd> -<dt><tt class="docutils literal"><span class="pre">-I</span> <span class="pre">REPLACE_STRING</span></tt>, <tt class="docutils literal"><span class="pre">--replace</span> <span class="pre">REPLACE_STRING</span></tt></dt> -<dd>Use to define a string that will be used to replace all occurrences of a file name. Default: <tt class="docutils literal"><span class="pre">nil</span></tt>.</dd> -<dt><tt class="docutils literal"><span class="pre">-J</span> <span class="pre">REPLACE_STRING</span></tt>, <tt class="docutils literal"><span class="pre">--replace-first</span> <span class="pre">REPLACE_STRING</span></tt></dt> -<dd>Use to define a string that will be used to replace the first occurrence of a file name. Default: <tt class="docutils literal"><span class="pre">nil</span></tt>.</dd> -<dt><tt class="docutils literal"><span class="pre">--local</span></tt></dt> -<dd>Use to build or execute a command line against a local file. Set to <tt class="docutils literal"><span class="pre">false</span></tt> to build or execute against a remote file. Default: <tt class="docutils literal"><span class="pre">false</span></tt>.</dd> -<dt><tt class="docutils literal"><span class="pre">-n</span> <span class="pre">MAX_ARGS</span></tt>, <tt class="docutils literal"><span class="pre">--max-args</span> <span class="pre">MAX_ARGS</span></tt></dt> -<dd>The maximum number of arguments per command line. Default: <tt class="docutils literal"><span class="pre">nil</span></tt>.</dd> -<dt><tt class="docutils literal"><span class="pre">-p</span> <span class="pre">[PATTERN...]</span></tt>, <tt class="docutils literal"><span class="pre">--pattern</span> <span class="pre">[PATTERN...]</span></tt></dt> -<dd>One (or more) patterns for a command line. If this option is not specified, a list of patterns may be expected on standard input. Default: <tt class="docutils literal"><span class="pre">nil</span></tt>.</dd> -<dt><tt class="docutils literal"><span class="pre">--repo-mode</span> <span class="pre">MODE</span></tt></dt> -<dd>The layout of the local chef-repo. Possible values: <tt class="docutils literal"><span class="pre">static</span></tt>, <tt class="docutils literal"><span class="pre">everything</span></tt>, or <tt class="docutils literal"><span class="pre">hosted_everything</span></tt>. Use <tt class="docutils literal"><span class="pre">static</span></tt> for just roles, environments, cookbooks, and data bags. By default, <tt class="docutils literal"><span class="pre">everything</span></tt> and <tt class="docutils literal"><span class="pre">hosted_everything</span></tt> are dynamically selected depending on the server type. Default value: <tt class="docutils literal"><span class="pre">default</span></tt>.</dd> -<dt><tt class="docutils literal"><span class="pre">-s</span> <span class="pre">LENGTH</span></tt>, <tt class="docutils literal"><span class="pre">--max-chars</span> <span class="pre">LENGTH</span></tt></dt> -<dd>The maximum size (in characters) for a command line. Default: <tt class="docutils literal"><span class="pre">nil</span></tt>.</dd> -<dt><tt class="docutils literal"><span class="pre">-t</span></tt></dt> -<dd>Use to run the print command on the command line. Default: <tt class="docutils literal"><span class="pre">nil</span></tt>.</dd> -</dl> -</div> -<div class="section" id="examples"> -<h2>Examples<a class="headerlink" href="#examples" title="Permalink to this headline">¶</a></h2> -<p>The following examples show how to use this knife subcommand:</p> -<p><strong>Use output of knife deps to pass command to knife xargs</strong></p> -<p>The following examples show various ways of listing all nodes on the server, and then using Perl to replace <tt class="docutils literal"><span class="pre">grantmc</span></tt> with <tt class="docutils literal"><span class="pre">gmc</span></tt>:</p> -<div class="highlight-bash"><div class="highlight"><pre><span class="nv">$ </span>knife list <span class="s1">'nodes/*'</span> | knife xargs <span class="s2">"perl -i -pe 's/grantmc/gmc'"</span> -</pre></div> -</div> -<p>or without quotes and the backslash escaped:</p> -<div class="highlight-bash"><div class="highlight"><pre><span class="nv">$ </span>knife list /nodes/<span class="se">\*</span> | knife xargs <span class="s2">"perl -i -pe 's/grantmc/gmc'"</span> -</pre></div> -</div> -<p>or by using the <tt class="docutils literal"><span class="pre">--pattern</span></tt> option:</p> -<div class="highlight-bash"><div class="highlight"><pre><span class="nv">$ </span>knife xargs --pattern <span class="s1">'/nodes.*'</span> <span class="s2">"perl -i -pe 's/grantmc/gmc'"</span> -</pre></div> -</div> -</div> -</div> - - - </div> - - </div> - - - <div class="clearer"></div> - </div> - - - - - </body> -</html>
\ No newline at end of file |