Class: Ansible::Ruby::Modules::Nxos_command
- Inherits:
-
Base
- Object
- Ansible::Ruby::Models::Base
- Base
- Ansible::Ruby::Modules::Nxos_command
- Defined in:
- lib/ansible/ruby/modules/generated/network/nxos/nxos_command.rb
Overview
Sends an arbitrary command to an NXOS node and returns the results read from the device. This module includes an argument that will cause the module to wait for a specific condition before returning or timing out if the condition is not met.
Instance Method Summary collapse
-
#commands ⇒ Array<String>, String
The commands to send to the remote NXOS device.
-
#interval ⇒ Integer?
Configures the interval in seconds to wait between retries of the command.
-
#match ⇒ String?
The I(match) argument is used in conjunction with the I(wait_for) argument to specify the match policy.
-
#retries ⇒ Integer?
Specifies the number of retries a command should by tried before it is considered failed.
-
#wait_for ⇒ Array<String>, ...
Specifies what to evaluate from the output of the command and what conditionals to apply.
Methods inherited from Base
Methods inherited from Ansible::Ruby::Models::Base
attr_option, attr_options, attribute, #initialize, remove_existing_validations, #to_h, validates
Constructor Details
This class inherits a constructor from Ansible::Ruby::Models::Base
Instance Method Details
#commands ⇒ Array<String>, String
Returns The commands to send to the remote NXOS device. The resulting output from the command is returned. If the I(wait_for) argument is provided, the module is not returned until the condition is satisfied or the number of retires as expired.,The I(commands) argument also accepts an alternative form that allows for complex values that specify the command to run and the output format to return. This can be done on a command by command basis. The complex argument supports the keywords C(command) and C(output) where C(command) is the command to run and C(output) is one of ‘text’ or ‘json’.
12 |
# File 'lib/ansible/ruby/modules/generated/network/nxos/nxos_command.rb', line 12 attribute :commands |
#interval ⇒ Integer?
Returns Configures the interval in seconds to wait between retries of the command. If the command does not pass the specified conditional, the interval indicates how to long to wait before trying the command again.
28 |
# File 'lib/ansible/ruby/modules/generated/network/nxos/nxos_command.rb', line 28 attribute :interval |
#match ⇒ String?
Returns The I(match) argument is used in conjunction with the I(wait_for) argument to specify the match policy. Valid values are C(all) or C(any). If the value is set to C(all) then all conditionals in the I(wait_for) must be satisfied. If the value is set to C(any) then only one of the values must be satisfied.
20 |
# File 'lib/ansible/ruby/modules/generated/network/nxos/nxos_command.rb', line 20 attribute :match |
#retries ⇒ Integer?
Returns Specifies the number of retries a command should by tried before it is considered failed. The command is run on the target device every retry and evaluated against the I(wait_for) conditionals.
24 |
# File 'lib/ansible/ruby/modules/generated/network/nxos/nxos_command.rb', line 24 attribute :retries |
#wait_for ⇒ Array<String>, ...
Returns Specifies what to evaluate from the output of the command and what conditionals to apply. This argument will cause the task to wait for a particular conditional to be true before moving forward. If the conditional is not true by the configured retries, the task fails. See examples.
16 |
# File 'lib/ansible/ruby/modules/generated/network/nxos/nxos_command.rb', line 16 attribute :wait_for |