文件操作 - application_sets.yml
返回文件管理
返回主菜单
删除本文件
文件: /usr/lib/python3.12/site-packages/ansible_collections/cisco/dnac/playbooks/application_sets.yml
编辑文件内容
--- - hosts: dnac_servers vars_files: - credentials.yml gather_facts: false tasks: - name: Create an application set cisco.dnac.application_sets: dnac_host: "{{ dnac_host }}" dnac_username: "{{ dnac_username }}" dnac_password: "{{ dnac_password }}" dnac_verify: "{{ dnac_verify }}" dnac_debug: "{{ dnac_debug }}" state: present payload: - name: AppSet1 register: application_set_result - name: Get task info cisco.dnac.task_info: dnac_host: "{{ dnac_host }}" dnac_username: "{{ dnac_username }}" dnac_password: "{{ dnac_password }}" dnac_verify: "{{ dnac_verify }}" taskId: "{{ application_set_result.dnac_response.response.taskId }}" when: - application_set_result.dnac_response is defined - application_set_result.dnac_response.response is defined - application_set_result.dnac_response.response.taskId is defined register: task_result - name: Show new application_set ansible.builtin.debug: msg: "{{ application_set_result }}" when: - application_set_result is defined - name: Show retrieved task ansible.builtin.debug: msg: "{{ task_result.dnac_response.response }}" when: - task_result is defined - task_result.dnac_response is defined
修改文件时间
将文件时间修改为当前时间的前一年
删除文件