arista / arista.cvp / 3.10.1 / module / cv_task
Removed in 4.0.0
Reason:Updated modules released with increased functionality | Alternative:Use M(arista.cvp.cv_task_v3) instead.
Execute or Cancel CVP Tasks.
| "added in version" 1.0.0 of arista.cvp"
Authors: Ansible Arista Team (@aristanetworks)
Install with ansible-galaxy collection install arista.cvp:==3.10.1
collections: - name: arista.cvp version: 3.10.1
CloudVision Portal Task module
--- - name: Execute all tasks registered in cvp_configlets variable arista.cvp.cv_task: tasks: "{{ cvp_configlets.data.tasks }}"
- name: Cancel a list of pending tasks arista.cvp.cv_task: tasks: "{{ cvp_configlets.data.tasks }}" state: cancelled
# Execute all pending tasks and wait for completion for 60 seconds # In order to get a list of all pending tasks, execute cv_facts first - name: Update cvp facts arista.cvp.cv_facts:
- name: Execute all pending tasks and wait for completion for 60 seconds arista.cvp.cv_task: port: '{{cvp_port}}' tasks: "{{ tasks }}" wait: 60
wait: default: 0 description: Time to wait for tasks to transition to 'Completed.' required: false type: int state: choices: - executed - cancelled default: executed description: Action to carry out on the task. required: false type: str tasks: description: CVP taskIDs to act on. elements: dict required: true type: list options: description: Implements the ability to create a sub-argument_spec, where the sub options of the top level argument are also validated using the attributes discussed in this section. required: false type: dict