mirror of
https://github.com/ansible-collections/community.general.git
synced 2025-05-08 02:01:31 -07:00
Add info about sudo.
This commit is contained in:
parent
2850b8d921
commit
adbf3590c5
15 changed files with 49 additions and 21 deletions
|
@ -181,8 +181,9 @@ ssh-add ~/.ssh/id_rsa.pub</pre>
|
|||
<div class="highlight-python"><pre>ansible atlanta -a "/usr/bin/foo" -u yourname</pre>
|
||||
</div>
|
||||
<p>If you want to run commands through sudo:</p>
|
||||
<div class="highlight-python"><pre>ansible atlanta -a "/usr/bin/foo" -u yourname --sudo</pre>
|
||||
</div>
|
||||
<blockquote>
|
||||
<div>ansible atlanta -a “/usr/bin/foo” -u yourname –sudo [–ask-sudo-pass]</div></blockquote>
|
||||
<p>Use –ask-sudo-pass (-K) if you are not using passwordless sudo.</p>
|
||||
<p>If you need to access SSH on a different port:</p>
|
||||
<div class="highlight-python"><pre>ansible atlanta -a "/usr/bin/foo" -p 2112</pre>
|
||||
</div>
|
||||
|
@ -340,7 +341,7 @@ a simplified syntax for this.</p>
|
|||
<p class="pull-right"><a href="#">Back to top</a></p>
|
||||
<p>
|
||||
© Copyright 2012 Michael DeHaan.<br/>
|
||||
Last updated on Apr 12, 2012.<br/>
|
||||
Last updated on Apr 14, 2012.<br/>
|
||||
Created using <a href="http://sphinx.pocoo.org/">Sphinx</a> 1.0.8.<br/>
|
||||
</p>
|
||||
</div>
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue