Class: Ansible::Ruby::Modules::Shell
- Inherits:
-
Base
- Object
- Ansible::Ruby::Models::Base
- Base
- Ansible::Ruby::Modules::Shell
- Includes:
- FreeForm
- Defined in:
- lib/ansible/ruby/modules/generated/commands/shell.rb,
lib/ansible/ruby/modules/custom/commands/shell.rb
Overview
The C(shell) module takes the command name followed by a list of space-delimited arguments. It is almost exactly like the M(command) module but runs the command through a shell (C(/bin/sh)) on the remote node. For Windows targets, use the M(win_shell) module instead.
Instance Method Summary collapse
-
#chdir ⇒ String?
Cd into this directory before running the command.
-
#creates ⇒ String?
A filename, when it already exists, this step will B(not) be run.
-
#executable ⇒ String?
Change the shell used to execute the command.
-
#free_form ⇒ Object
The shell module takes a free form command to run, as a string.
-
#removes ⇒ Object?
A filename, when it does not exist, this step will B(not) be run.
-
#stdin ⇒ Object?
Set the stdin of the command directly to the specified value.
-
#warn ⇒ :yes, ...
If command warnings are on in ansible.cfg, do not warn about this particular line if set to no/false.
Methods included from FreeForm
Methods inherited from Base
Methods inherited from Ansible::Ruby::Models::Base
attr_option, attr_options, attribute, fix_inclusion, #initialize, remove_existing_validations, #to_h, validates
Constructor Details
This class inherits a constructor from Ansible::Ruby::Models::Base
Instance Method Details
#chdir ⇒ String?
Returns cd into this directory before running the command.
24 |
# File 'lib/ansible/ruby/modules/generated/commands/shell.rb', line 24 attribute :chdir |
#creates ⇒ String?
Returns a filename, when it already exists, this step will B(not) be run.
17 |
# File 'lib/ansible/ruby/modules/generated/commands/shell.rb', line 17 attribute :creates |
#executable ⇒ String?
Returns change the shell used to execute the command. Should be an absolute path to the executable.
28 |
# File 'lib/ansible/ruby/modules/generated/commands/shell.rb', line 28 attribute :executable |
#free_form ⇒ Object
Returns The shell module takes a free form command to run, as a string. There’s not an actual option named “free form”. See the examples!.
13 |
# File 'lib/ansible/ruby/modules/generated/commands/shell.rb', line 13 attribute :free_form |
#removes ⇒ Object?
Returns a filename, when it does not exist, this step will B(not) be run.
21 |
# File 'lib/ansible/ruby/modules/generated/commands/shell.rb', line 21 attribute :removes |
#stdin ⇒ Object?
Returns Set the stdin of the command directly to the specified value.
36 |
# File 'lib/ansible/ruby/modules/generated/commands/shell.rb', line 36 attribute :stdin |
#warn ⇒ :yes, ...
Returns if command warnings are on in ansible.cfg, do not warn about this particular line if set to no/false.
32 |
# File 'lib/ansible/ruby/modules/generated/commands/shell.rb', line 32 attribute :warn |