arista / arista.cvp / 1.1.0 / module / cv_task Execute or Cancel CVP Tasks. | "added in version" 2.9 of arista.cvp" Authors: EMEA AS Team (@aristanetworks) preview | supported by communityarista.cvp.cv_task (1.1.0) — module
Install with ansible-galaxy collection install arista.cvp:==1.1.0
collections: - name: arista.cvp version: 1.1.0
CloudVison 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 executed - execute tasks cancelled - cancel tasks required: false type: str tasks: description: CVP taskIDs to act on required: true type: list